Crashes in debug builds around isolate.

38 views
Skip to first unread message

Ronald Fenner

unread,
Apr 25, 2024, 2:09:42 PM4/25/24
to v8-dev
I've been trying to figure out what's casuing a crash around an isolate being released.
On Mac OS X i was getting a bad exec in an atomic load related to EntryStackItem.

I moved over to windows to see if it would crash there and it does but with a different error.

Possibly because on widows i've updated to 12.3.219.15. I also saw the same thing in 11.8..173.
I elminated any of my code by copying over the hello world sample and build it under my project bazel build and it also crashes. However it doesn't crash when i added it as a build target for the project that builds the v8 libraries for me.

That process is use the args file to build the v8 then package all the .objs for a specified set of of v8 libraries into a .a since bazel doesn't like .lib in cc_library.

Oddly enough when i run all my tests using non debug builds it has no porblem running just the debug builds of v8.

Currently seeing these 2 crashes

This one occurs in one of my yests when calling HasCaught of a TryCatch
#
# Fatal error in C:\Users\dorml\github\v8Dist\v8\src/objects/slots.h, line 84
# Debug check failed: IsAligned(ptr, kSlotDataAlignment).
#
#
#
#FailureMessage Object: 000000FCC711DCA

If i comment that line out then It crashes in the HandleScope when it's leaving it's scope and being deleted. It crtashes on this line
  CHECK_EQ(scope_level_, i_isolate_->handle_scope_data()->level);

Since the level is 1 and not 0.
All the code was working prior to moving up to more recent releases of v8

I suspect it may be some difference in debug builds between v8 build process and bazel build process toolchains.

Ronald Fenner

unread,
Apr 26, 2024, 2:25:31 AM4/26/24
to v8-dev
So i found the issue since when the library was built this define was set when building v8 "V8_ENABLE_CHECKS
In my project I didn't have it defined so the variable scope_level_ wasn't getting defined since it's declared in the headers that get included from the v8 includes thus getting compiled out and was always 0. 
Defining "V8_ENABLE_CHECKS" fixed the problem on my side.

Ronald Fenner

unread,
Apr 26, 2024, 2:39:56 AM4/26/24
to v8-dev
Turns it was also the problem on the OS X Side as well.
Reply all
Reply to author
Forward
0 new messages