Re: [v8-users] Can V8 save the result of compiling JS functions/files to a file?

2015-03-24 Thread Jiang Kelvin
*Code caching is another new technique that helps speed up page loading, specifically on repeated visits to the same page. Normally, the V8 engine compiles the page’s JavaScript on every visit, turning it into instructions that a processor understands. This compiled code is then discarded once a

Re: [v8-users] Execution slowdown issue

2015-03-24 Thread Danny Dorfman
Hi Jakob, Yes, you're right. It was because of the debug build. Switching to the release version sped things up considerably. Thanks! That was a quick fix :) Regards, Danny On Tuesday, March 24, 2015 at 11:09:27 AM UTC+2, Jakob Kummerow wrote: > > The profile for the "slow transaction" doesn't

Re: [v8-users] Execution slowdown issue

2015-03-24 Thread Jakob Kummerow
The profile for the "slow transaction" doesn't really say anything other than that the C++ compiler didn't do any inlining (probably due to oprofile, or was this a Debug build, or both?). On Tue, Mar 24, 2015 at 9:50 AM, Toon Verwaest wrote: > If your transactional scripts contain function decl

Re: [v8-users] Execution slowdown issue

2015-03-24 Thread Toon Verwaest
If your transactional scripts contain function declarations that you instantiate, even if they are global, you'll inadvertantly cause polymorphism on the second run. That will slow down significantly. You can avoid this by only rerunning scripts that call/instantiate existing functions. Alternative

[v8-users] Execution slowdown issue

2015-03-24 Thread Danny Dorfman
Hello there, I have an issue with some code running JavaScript under V8, The code runs in a *single* Isolate, that has *one* context. The context is created, populated with some scripts, the scripts are executed, and then the context is Exit()ed. The Isolate stays intact. The above sequence repe