On Thu, Sep 24, 2015 at 1:58 PM, dmonji <monikadhok...@gmail.com> wrote:

> 1) In v8, ic.cc, i see functions like
> *RUNTIME_FUNCTION(Runtime_KeyedLoadIC_Miss)*.
>     I don't understand how are they invoked. Is there some connection
> with  * __ TailCallRuntime(Runtime::kKeyedLoadIC_Miss, arg_count, 1);*
>     from ic-<arch>.cc?
>

Yes, that's precisely how they're invoked.


> 2) what is the difference between *Runtime_KeyedLoadIC_Miss* and 
> *Runtime_LoadIC_Miss
> *?
>

Essentially, foo.bar is a load and foo[bar] is a keyed load.


> 3)  Can I profile these runtime functions using some c++ profiler? I want
> to see how much time is spent on subset of these runtime functions.
>

Sure, C++ profilers can profile C++ functions.
However, profiling short-running functions is notoriously hard because of
the overhead that profiling introduces.
For example, V8's timeline plotter
<https://code.google.com/p/v8-wiki/wiki/V8Profiler#Timeline_plot> reports
time spent handling IC misses; however getting the required timestamps is
so expensive compared to what the functions actually do that it tends to
over-report them by about 2x.
The sampling profiler
<https://code.google.com/p/v8-wiki/wiki/V8Profiler#Command_Line>'s
output has a section with "C++ entry points", which include IC miss
handlers among other things. It has less (but still non-zero) overhead, and
can be rather flaky due to the inherent randomness of sampling.

-- 
-- 
v8-users mailing list
v8-users@googlegroups.com
http://groups.google.com/group/v8-users
--- 
You received this message because you are subscribed to the Google Groups 
"v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to