[v8-users] Re: View assembly code for built in functions

2017-09-18 Thread Rong Jie
You need to build V8 with v8_enable_disassembler enabled (disabled by 
default in release build). See 
https://cs.chromium.org/chromium/src/v8/BUILD.gn?type=cs=v8_enable_disassembler

On Monday, September 18, 2017 at 5:23:09 PM UTC+8, Marija wrote:
>
> Hi,
>
> Is it possible to see generated assembly code for built-in functions? If I 
> use just print_code with a simple program, like [].push(1), nothing is 
> generated.
> Is --print_builtin_code flag the right thing to use? For array push the 
> output looks like:
>
> kind = BUILTIN
> name = ArrayPush
> compiler = unknown
> Instructions (size = 10)
> 0x246f7340 0  bb20c45908 mov ebx,0x859c420   ;; external 
> reference (Builtin_ArrayPush)
> 0x246f7345 5  e9f682feff jmp 0x246df640 
>  (AdaptorWithBuiltinExitFrame);; code: BUILTIN
>
>
> RelocInfo (size = 3)
> 0x246f7341  external reference (Builtin_ArrayPush)  (0x859c420)
> 0x246f7346  code target (BUILTIN)  (0x246df640)
>
> There is another code for FastArrayPush. 
>
> Can you also help me to understand the output if the flag 
> --print_builtin_code is the right thing to use?
>
> Thanks!
>

-- 
-- 
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.


[v8-users] Re: Building V8 on windows

2017-04-24 Thread Rong Jie
You should set DEPOT_TOOLS_WIN_TOOLCHAIN=0 before running gn and ninja so 
that goma is not used (only available for Googler)

-- 
-- 
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.


[v8-users] Re: Why for loop will become faster if divided in two loop?

2017-04-12 Thread Rong Jie
I think this might be due to loop fission optimization 
(https://en.wikipedia.org/wiki/Loop_fission), even GCC (C++ compiler) 
sometimes does that when appropriate.

-- 
-- 
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.