[v8-users] Cached data or startup snapshot?

2018-02-14 Thread Alexandru Dima
Hi, Which one would you recommend we (VSCode) use? Today, we are using cached data, but I wanted to find out if a startup snapshot would help us more. I've crammed all of VSCode's source code (except third party node modules) in a file and I've created a startup snapshot using `mksnapshot`. I

[v8-users] Re: Cached data or startup snapshot?

2018-02-16 Thread Alexandru Dima
Maybe I've complicated my question needlessly. To rephrase, when using custom startup snapshots, via `mksnapshot`, will the snapshotted code run slower than the same code loaded from sources at runtime? Thanks, Alex On Wednesday, February 14, 2018 at 6:57:38 PM UTC+2, Alexandru Dima

[v8-users] Re: Cached data or startup snapshot?

2018-02-16 Thread Alexandru Dima
Hi Yang, Thanks for answering! I only snapshot pure JS code (written in AMD form), and when the JS code needs node modules (built-in, native, JS only, etc), I feed it proxy objects (`new Proxy`). Here is how the code I snapshot looks like - https://gist.github.com/alexandrudima/bda598fbed179a5

[v8-users] Re: Cached data or startup snapshot?

2018-02-23 Thread Alexandru Dima
Hi Yang, I have spent quite some time to create a repro that executes the exact same code in the exact same state, once with the code loaded from cached data, and once with the code running from a startup snapshot. In this standalone repro, the total time is indeed better for starting from a