emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Elisp native profiler


From: Tomohiro Matsuyama
Subject: Re: Elisp native profiler
Date: Wed, 26 Sep 2012 15:16:25 +0900

> > A lesser question: why does the profiler use SA_SIGINFO?
> 
> No idea.  Better ask the author (Tomohiro Matsuyama <address@hidden>).
The information given to the signal handler is not used for now, so I will get 
rid of SA_SIGINFO from the flags.  In the future, however, we will obtain 
C-level backtrace from the information so that we can profile C-level function 
calls as well.  It might help us to profile byte-compiled code interpretation 
too, but I'm not sure.

Let me explain here three methods for cpu profiling and their pros and cons.

1. setitimer
Pros: Easy to implement, Accuracy, C-level backtrace
Cons: Non-portable

2. threads
Pros: Almost portable
Cons: Multithread programming, Lack of C-level backtrace

3. atimers
Pros: Fully portable, Easy to implement
Cons: Stop the world, Lack of C-level backtrace, Inaccuracy

A reason why I've chose to use setitimer is just I have no ideas except 
setitimer at that time.

Ohter ideas are welcome.

    Tomohiro



reply via email to

[Prev in Thread] Current Thread [Next in Thread]