Re: [v8-users] Preliminary RFC: Stabilizing the V8 script compiler cached data format

2021-07-27 Thread Jace Mogill
Leszek, Thank you for turning me on to the possibility of using an interceptor of a predefined object. This may be the gateway to several other approaches for integrating parallelism to V8 that sidelined me. I'll admit the last time I wrote code using V8 headers was v0.9 and now my full-time

Re: [v8-users] Preliminary RFC: Stabilizing the V8 script compiler cached data format

2021-07-26 Thread Jakob Gruber
On Mon, Jul 26, 2021 at 11:19 AM Leszek Swirski wrote: > On Fri, Jul 23, 2021 at 1:18 AM Vitali Lovich wrote: > >> What's the best way to measure script parse time vs lazy function >> compilation time? It's been a few months since I last looked at this so my >> memory is a bit hazy on whether it

Re: [v8-users] Preliminary RFC: Stabilizing the V8 script compiler cached data format

2021-07-26 Thread Leszek Swirski
On Sat, Jul 24, 2021 at 2:02 AM Jace Mogill wrote: > Complementary data and task parallel JSON lexing implementations already > exists (https://github.com/simdjson/simdjson, > https://github.com/mogill/parallel-xml2json) but there's no way to store > the results in a way V8 can use, and thus an e

Re: [v8-users] Preliminary RFC: Stabilizing the V8 script compiler cached data format

2021-07-26 Thread Leszek Swirski
On Fri, Jul 23, 2021 at 1:18 AM Vitali Lovich wrote: > What's the best way to measure script parse time vs lazy function > compilation time? It's been a few months since I last looked at this so my > memory is a bit hazy on whether it was instantiating > v8::ScriptCompiler::Source, v8::ScriptComp

Re: [v8-users] Preliminary RFC: Stabilizing the V8 script compiler cached data format

2021-07-23 Thread Jace Mogill
All, Since this topic has already prompted so much work and discussion I'll chime in as an opinionated but passive community member whose project is also ultimately limited by being able to reason about the storage sequence of V8 objects. Startup time is often a driving consideration, but any

Re: [v8-users] Preliminary RFC: Stabilizing the V8 script compiler cached data format

2021-07-22 Thread Vitali Lovich
Hi Leszek, Apologies for the delayed reply - I've been a bit swamped at work the past couple of days. Thank you for the excellent details & we'll align our plans accordingly. Some replies inline. I've replied privately to Jacob's concern as I don't want to derail this conversation. On Tue, Jul 2

Re: [v8-users] Preliminary RFC: Stabilizing the V8 script compiler cached data format

2021-07-21 Thread Jakob Kummerow
In addition to the excellent technical points that Leszek explained, I just wanted to clarify additionally that we don't have a concept of "major releases 8 -> 9" etc. V8's version numbers are assigned by adding 0.1 every six weeks, rolling from x.9 to (x+1).0. There are *zero* technical or strateg

Re: [v8-users] Preliminary RFC: Stabilizing the V8 script compiler cached data format

2021-07-20 Thread Leszek Swirski
Hi Vitali, Stabilising the cached data format as-is is pretty challenging; the cache as written is pretty much a direct field-by-field serialisation of the internal data structures, so freezing the cache would mean freezing the shapes of those internal objects, effectively making the internal f

Re: [v8-users] Preliminary RFC: Stabilizing the V8 script compiler cached data format

2021-07-19 Thread joe lewis
Hi Vitali, I’m neither from the v8 team, nor an expert in this subject matter. Just wanted to drop an interesting project: Hermes - https://hermesengine.dev , a javascript engine by Facebook that is tailored for fast startup times. It does this by precompiling javascript into bytecode at build tim

[v8-users] Preliminary RFC: Stabilizing the V8 script compiler cached data format

2021-07-19 Thread Vitali Lovich
Hi, I wanted to kick off a discussion and solicit some thoughts on whether it would be operationally feasible to try to stabilize the cached data format of the compiler. The context is that I work on Cloudflare Workers. We'd like to increase the script size we allow our customers to upload, but w