Hi Meir,

You are correct about the purpose of the CHECK that I introduced in CL 
5173257 <https://chromium-review.googlesource.com/c/v8/v8/+/5173257>.

The documentation 
<https://source.chromium.org/chromium/chromium/src/+/main:v8/include/v8-locker.h;drc=65034fdf545d2f937dd05f1aa535c39ba21ccac5;l=45>
 
of the Locker/Unlocker API specifies that a thread has to exit the isolate 
before using v8::Unlocker and enter it again afterwards.

Without seeing your code, I cannot be sure that this is the issue but from 
what you write I suspect that it is. It should also be very easy to fix.

See here for a similar fix that had to be made in chromium: CL 5168625 
<https://chromium-review.googlesource.com/c/chromium/src/+/5168625>.

Best regards,
Nikos.

On Tuesday, January 16, 2024 at 12:18:22 PM UTC+1 [email protected] wrote:

Hey,

We recently encounter an issue in which our code, when run on V8 main 
branch, crashes with this fatal error:
#
# Fatal error in ../../src/execution/isolate.cc, line 4996
# Check failed: current_thread_id_ == thread_id (<unprintable> vs. 
<unprintable>).
#
#
#

I saw that this check was added recently on this PR: 
https://chromium-review.googlesource.com/c/v8/v8/+/5173257

Its purpose is to verify a correct use of entering and existing an isolate. 
But I do not see it is taking into consideration the Locker/Unlocker API. 
In case the current thread uses Unlocker and then another thread tries to 
enter the isolate it will failed.

Is my analysis correct or am I missing something?
Thanks,
Meir

-- 
-- 
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- 
You received this message because you are subscribed to the Google Groups 
"v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/v8-dev/63d5e3cf-e6e1-468e-9de4-4e5ee51474ffn%40googlegroups.com.

Reply via email to