Crash in [@ js::gc::ChunkBase::isNurseryChunk]
Categories
(Core :: JavaScript: GC, defect, P3)
Tracking
()
People
(Reporter: calixte, Unassigned)
References
(Blocks 2 open bugs)
Details
(Keywords: crash)
Crash Data
Crash report: https://crash-stats.mozilla.org/report/index/91710ff6-daae-4752-acb3-560710260810
Crash Reason:
EXCEPTION_ACCESS_VIOLATION_READ at 0x000031b78e200010
Top 10 frames:
0 xul.dll js::GCMarker::markCurrentColorInParallel(js::gc::ParallelMarkTask*, JS::SliceBud... js/src/gc/Marking.cpp:1534
1 xul.dll js::gc::ParallelMarkTask::run(js::AutoLockHelperThreadState&) js/src/gc/ParallelMarking.cpp:165
2 xul.dll js::GCParallelTask::runTask(JS::GCContext*, js::AutoLockHelperThreadState&) js/src/gc/GCParallelTask.cpp:219
3 xul.dll js::gc::ParallelMarker::markOneColor(js::gc::GCRuntime*, js::gc::MarkColor, JS::... js/src/gc/ParallelMarking.cpp:53
4 xul.dll js::gc::GCRuntime::markSynchronously(JS::SliceBudget&, js::gc::GCRuntime::Parall... js/src/gc/GC.cpp:3638
5 xul.dll js::gc::GCRuntime::gcCycle(bool, JS::SliceBudget const&, JS::GCReason) js/src/gc/GC.cpp:5100
6 xul.dll js::gc::GCRuntime::collect(bool, JS::SliceBudget const&, JS::GCReason) js/src/gc/GC.cpp:5290
7 xul.dll GarbageCollectImpl(JS::GCReason, nsJSContext::IsShrinking, JS::SliceBudget const... dom/base/nsJSEnvironment.cpp:902
8 xul.dll std::_Func_impl_no_alloc<`lambda at .\..\..\..\..\checkouts\gecko\dom\base\CCGCS...
9 xul.dll mozilla::IdleTaskRunner::Run() xpcom/threads/IdleTaskRunner.cpp:124
There are 2 crashes (from 2 installations) in nightly 155 with buildid 20260806095421.
Clouseau analysis (confidence probable): js::gc::BufferAllocator::TraceEdge loads a GCBuffer pointer atomically but then dereferences the pointed-to chunk's header (ChunkBase::kind, offset 0x10, matching the fault address 0x…200010) with no synchronization; js::BaseScript::traceChildren reaches this exact path for PrivateScriptData because 72aa2b26aa44 (bug 2042863) wired it through GCBuffer<PrivateScriptData*>/TraceEdgeAndBuffer.
The js/src/gc/BufferAllocator.cpp/ParallelMarking.cpp subsystem is new (introduced ~2026-05) and has a long, ongoing series of correctness fixes by the same author for concurrent-marking-vs-chunk-lifetime hazards (bug 2044578, 2051881, 2045637, 2049401, 2052490) through the exact build window, none of which are in the given seed list — this is an off-stack widening of the candidate set, not a seed-list hit.
Suspected regressor: 72aa2b26aa44 (gh) (bug 2042863) by Jon Coppeard.
Code references:
:jonco, can you have a look please?
| Reporter | ||
Updated•3 months ago
|
Comment 1•3 months ago
|
||
(In reply to Calixte Denizet (:calixte) from comment #0)
Clouseau analysis (confidence probable):
js::gc::BufferAllocator::TraceEdgeloads aGCBufferpointer atomically but then dereferences the pointed-to chunk's header (ChunkBase::kind, offset0x10, matching the fault address0x…200010) with no synchronization
No synchronization is necessary here because chunks are never freed until after marking has finished.
The
js/src/gc/BufferAllocator.cpp/ParallelMarking.cppsubsystem is new (introduced ~2026-05) and has a long, ongoing series of correctness fixes by the same author for concurrent-marking-vs-chunk-lifetime hazards
Concurrent marking is under development and is not present in any release builds so is not relevant to these crashes.
This is probably a random memory corruption bug.
Comment 2•3 months ago
|
||
:calixte, since this bug is a regression, could you fill (if possible) the regressed_by field?
For more information, please visit BugBot documentation.
Updated•3 months ago
|
Updated•3 months ago
|
Description
•