From: Stefan Monnier <monnier@iro.umontreal.ca>
To: Eli Zaretskii <eliz@gnu.org>
Cc: Paul Eggert <eggert@cs.ucla.edu>, emacs-devel@gnu.org
Subject: Re: [Emacs-diffs] /srv/bzr/emacs/trunk r110342: Count overruns when profiling; change units to ns.
Date: Tue, 02 Oct 2012 22:05:34 -0400 [thread overview]
Message-ID: <jwvmx04fh8g.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <83wqz8ajra.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 02 Oct 2012 19:03:53 +0200")
> Which AFAIK is (was) a bug in profiler: it cannot assume that what it
> asked setitimer will actually be obeyed. To see what interval is
> actually being loaded into the timer, one needs to call getitimer
> after setitimer returns.
If enough systems are able to return a different value in getitimer than
set in setitimer, then it would be good to do that (and signal an error
or at least output a message if the return value is different).
> I believe on Posix systems this boils down to calling clock_gettime
> with the correct timer ID (and there are equivalent APIs on
> MS-Windows).
That would be a nice approach, indeed, when CLOCK_PROCESS/THREAD_CPUTIME_ID
is supported. We still need to worry about wraparound: counting ms
gives us a wraparound after 512M ms = 512ks =~ 5 days, which seems
acceptable, but anything finer would not fly without a good solution to
the wraparound.
> Then we could satisfy Stefan's design goal of having
> compatible profiles with different sampling period.
It's not terribly important, but it is desirable.
Stefan
next prev parent reply other threads:[~2012-10-03 2:05 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <E1TIwjJ-0005wv-J8@vcs.savannah.gnu.org>
2012-10-02 13:20 ` [Emacs-diffs] /srv/bzr/emacs/trunk r110342: Count overruns when profiling; change units to ns Stefan Monnier
2012-10-02 16:37 ` Paul Eggert
2012-10-02 17:03 ` Eli Zaretskii
2012-10-02 20:52 ` Paul Eggert
2012-10-02 21:17 ` Eli Zaretskii
2012-10-03 5:00 ` Paul Eggert
2012-10-03 17:18 ` Eli Zaretskii
2012-10-03 17:29 ` Paul Eggert
2012-10-03 17:55 ` Eli Zaretskii
2012-10-03 2:05 ` Stefan Monnier [this message]
2012-10-03 5:03 ` Paul Eggert
2012-10-03 12:48 ` Stefan Monnier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=jwvmx04fh8g.fsf-monnier+emacs@gnu.org \
--to=monnier@iro.umontreal.ca \
--cc=eggert@cs.ucla.edu \
--cc=eliz@gnu.org \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).