Crash in mksnapshot when building with Electron 4 #19374
Comments
Yeah, I get exit code 3221225477 reported through Node's child_process, and -1073741819 from cmd when trying to run mksnapshot. |
I ran
|
/cc @jkleinsc for info |
As discussed with @BinaryMuse, as painful as this is, perhaps our best bet is to bisect the files we include in |
@rafeca found that we're including Atom's |
This is the actual object that we're including: https://gist.github.com/rafeca/49379b5a0af04e542504b098b7ec3197 This object has a
Apart from this, in that huge object there's a Why does
|
I think this may have something to do with the work I recently did on Electron 3 (see electron/electron#18420). I suspect that modifying |
For what it's worth, I just tested running Electron 4's and Electron 5's That fix is something that we will need in Electron 3.1 as well, so it may be sufficient to update from master once that branch is merged (we are currently waiting on a hotfix after electron/electron#18426 goes green). |
This issue has been automatically locked since there has not been any recent activity after it was closed. If you can still reproduce this issue in Safe Mode then please open a new issue and fill out the entire issue template to ensure that we have enough information to address your issue. Thanks! |
When attempting to upgrade to Electron 4 in #19373, we fail the build with the following error when attempting to generate the startup snapshot. (I modified the build script slightly to pass
stdio: "inherit"
tomksnapshot
for better error output)After hacking some logging into
electron-mksnapshot
, it appears that themksnapshot
is crashing with a segmentation fault. In the Node wrapper script, the exit code on the child process isnull
and thesignal
isSEGV
.Running
mksnapshot
directly as follows also produces a segfault, althoughelectron-mksnaphsot
seems to do some special magic to move files to a single working directory, so it's unclear whether this is even a good way to runmksnapshot
.Trying the latest electron-mksnapshot
I tried to generate the startup snapshot with
electron-mksnapshot@6.0.0-beta.1
and got a bit further. I was able to generatesnapshot_blob.bin
, but the script failed when invokingv8_context_snapshot_generator
. The output in this failure mode is pretty bad... the script just prints out the entire child process object, so I'm eliding some of its details here for readability.I'm not sure where to go from here. To some degree, we're abusing V8 startup snapshots in Atom. They weren't designed for public consumption, and the snapshot that ships with Chrome is much smaller and probably way simpler than what we are attempting in Atom's
startup.js
script.cc @MarshallOfSound
The text was updated successfully, but these errors were encountered: