On Mon, Dec 16, 2013 at 5:37 PM, Pawel Por <[email protected]> wrote:

> Hi
>
> I have a few questions about V8 virtual machine.
>
> - is there some kind of intermediate byte code or everything is always
> compiled into machine native code
>

No, there is no byte code.
The optimizing compiler does have an intermediate representation, but (1)
it's not bytecode, (2) it can't be extracted/dumped/stored/whatever, and
(3) in most real apps, only a few functions are optimized. The
non-optimizing compiler always generates machine code directly.

- can I set up V8 virtual machine in some kind of debugging mode where I
> can perform some action upon every JavaScript function executed by a V8
> virtual machine e.g. log it into a file.
>

No. If logging of function calls is specifically what you're interested in,
look at the --trace flag, as it does just this.
There's also --print-code which dumps the JS source as well as the
generated unoptimized machine code for every function when it's executed
for the first time.


>   If not is there a possiblity to write a loadable module that does it for
> me.
>

There's no existing loadable module infrastructure, but V8 being open
source means you can fork it and add one.


>
> thanks for help
>
> --
>
>

-- 
-- 
v8-users mailing list
[email protected]
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 [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to