natives_blob.bin contains the minified source code of JS natives shipped with V8, while snapshot_blob.bin contains the startup and context snapshots. We are working on removing natives_blob.bin, hopefully this will happen sometime this year.
Given "v8_use_snapshot=true v8_use_external_startup_data=false", the serialized data is compiled into the binary. Given "v8_use_snapshot=true v8_use_external_startup_data=true", serialized data is shipped as the external .bin files you mentioned. I hope that helps a bit. I'm not sure I understand your remaining questions, could you clarify if things are still unclear? On Thu, Jul 12, 2018 at 10:52 AM, <[email protected]> wrote: > when v8 is compiled with options "v8_use_snapshot=true > v8_use_external_startup_data=true", two files which are natives_blob.bin > and snapshot_blob.bin will be generated. when we use v8 in our embedder > progroam, *V8::InitializeExternalStartupData *need be called to load the > two files. After that, we need to new a isolate by calling *Isolate::New* > that will call > *isolate->set_snapshot_blob(i::Snapshot::DefaultSnapshotBlob());* if we > don't supply a custom snapshot data by specifing *CreateParams*'s > snapshot_blob. > > But if v8 is complied with options "v8_use_snapshot=true > v8_use_external_startup_data=false", natives_blob.bin and > snapshot_blob.bin will not be generated. *V8::InitializeExternalStartupData > *need not be called. Can I call *Isolate::New *with a custom snapshot > data that was generated by *SnapshotCreator *Api. Notice in this case no > natives_blob.bin is supplied. So is natives_blob.bin necessary ? Is > natives_blob.bin complied into v8 binary? > > we can still supply a custom snapshot to *CreateParams even i*f v8 is > complied with options "v8_use_snapshot=false", is that right? > > what is the relationship between natives_blob.bin and snapshot_blob.bin? > why not just generate one snapshot file? > > > -- -- 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/d/optout.
