Crash in [@ webrender::visibility::build_backdrop_capture_regions]
Categories
(Core :: Graphics: WebRender, defect)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox-esr153 | --- | unaffected |
| firefox158 | --- | unaffected |
| firefox159 | --- | unaffected |
| firefox160 | --- | fixed |
People
(Reporter: clouseau-bot, Assigned: gw)
References
(Blocks 1 open bug, Regression)
Details
(Keywords: crash, regression)
Crash Data
Attachments
(1 external file)
Crash report: https://crash-stats.mozilla.org/report/index/57ef6ee6-53c5-4adf-8f77-8daeb0261020
MOZ_CRASH Reason:
index out of bounds: the len is 292 but the index is 292
Top 10 frames:
0 xul.dll RustMozCrash(char const*, int, char const*) mozglue/static/rust/wrappers.cpp:17
1 xul.dll mozglue_static::panic_hook(std::panic::PanicHookInfo*) mozglue/static/rust/lib.rs:99
2 xul.dll core::ops::function::FnOnce::call_once<void (*)(ref$<std::panic::PanicHookInfo>)...
3 xul.dll std::panicking::panic_with_hook() library/std/src/panicking.rs:833
4 xul.dll std::panicking::panic_handler::closure$0() library/std/src/panicking.rs:698
5 xul.dll std::sys::backtrace::__rust_end_short_backtrace<std::panicking::panic_handler::c... library/std/src/sys/backtrace.rs:182
6 xul.dll std::panicking::panic_handler() library/std/src/panicking.rs:689
7 xul.dll core::panicking::panic_fmt() library/core/src/panicking.rs:80
8 xul.dll core::panicking::panic_bounds_check() library/core/src/panicking.rs:271
9 xul.dll webrender::frame_builder::FrameBuilder::build(webrender::scene::BuiltScene*, boo... gfx/wr/webrender/src/frame_builder.rs:726
There are 4 crashes (from 1 installation) in nightly 160 with buildid 20261019215902.
This signature is new: its first report anywhere is in build 20261019215902 (2026-10-19), the build above.
Hardware-error share of this signature: of its 4 reports on this channel over the last year, 100% come from the known-buggy Intel Raptor Lake (family 6 model 183 stepping 1, bug 1975808; Firefox-nightly population: 4%).
Clouseau analysis (automated, 72% worth investigating — a calibrated estimate that this is worth someone's time, not that the changeset below caused it). The mechanism below fits the evidence but is not proven end-to-end:
build_backdrop_capture_regions probably panics indexing this frame's surfaces with a surface index left in a picture's raster_config by an earlier frame (len 292, index 292).
FrameBuilder::buildclearsscene.surfaceseach frame, so aSurfaceIndexis only valid for the frame that assigned it.PictureInstance::raster_configis reset only inPictureInstance::assign_surface, which runs only for pictures that got an update pass this frame.assign_update_passsetsinfo.parentbeforePictureInstance::is_visible, so a backdrop chain picture hidden byFilter::Opacitynear 0 or by backface culling keeps a parent while it, and the children it never visits, keep last frame'sraster_config.ea745deba60caddedbuild_backdrop_capture_regions, which gates only onpicture_graph.parent(chain_pic_index)and the root'ssurface_index, accepts any non-Noneraster_configin the chain, and then indexessurfaces[raster_config.surface_index.0].- When an earlier frame had more surfaces, that stale index is at or past this frame's
surfaces.len(), and the bounds check panics.
The exact len==index panic, the frame (build_backdrop_capture_regions inlined into FrameBuilder::build) and the signature first appearing in the build that added this function all fit. Nothing in the report shows the hidden chain picture, the inlined frame has no line info to say which surfaces[...] read fired, and every report comes from a known-defective Raptor Lake CPU. Look first at the chain-walk gate (pic.raster_config.is_none()): requiring picture_graph.surface_index(pic_index).is_some() for each chain picture would skip chains not reached this frame.
The signature was first seen in build 20261019215902, the first build with the bug 2079474 series, which landed on 2026-10-18. Blame of visibility.rs lines 456-495 at the build rev is entirely ea745deba60c, which added the function and its call in FrameBuilder::build_layer_screen_rects_and_cull_layers. The crash frame is that inlined call at frame_builder.rs:726. The 4/4 Raptor Lake share is a real caveat, but the deterministic off-by-one bounds panic in brand-new code argues for a software cause.
Suspected regressor: ea745deba60c (gh) (bug 2079474) by :gw.
Code references:
- gfx/wr/webrender/src/visibility.rs:398
- gfx/wr/webrender/src/visibility.rs:416
- gfx/wr/webrender/src/visibility.rs:385
- webrender::picture::PictureInstance::assign_surface
- webrender::picture::PictureInstance::is_visible
- gfx/wr/webrender/src/frame_builder.rs:368
What the automated skeptic pass checked
In its own words (a pass means the check succeeded, which is not always support for the conclusion):
- unverifiable mechanism — No annotation shows a hidden chain picture. The inlined frame has no line info, so which
surfaces[...]site fired cannot be pinned. Other index sites are in range, debug-only, or would panic with a different message. - unverifiable hardware — 4/4 reports come from Raptor Lake CPUs, but 4 is too few to tell a defect from population bias. An exact len==index panic in a function new in the first-seen build points at software.
- unverifiable followups — Pt 2 (
fb3b55d32e19), Pt 4 (17b22abfced1) and Pt 5 (59fe71d7c538) of the same bug touch the area but do not introduce theraster_config.is_none()gate. They are part of the same series and not singled out. - pass step1 —
scene.surfaces.clear()runs every frame (frame_builder.rs:703, build rev).pic_infois rebuilt every frame, so onlyraster_configpersists across frames. - pass step2_step3 — The only resets of
raster_configarepicture.rs:1125and the constructor.info.parentis set before theis_visiblecheck, and invisible pictures and their children skipassign_surface. - pass hunk0 — The chain walk tests only
raster_config.is_none()and then indexessurfaceswith the stored index. Blame ofvisibility.rslines 456-495 at the build rev is entirelyea745deba60c.
:gw, can you have a look please?
Filed automatically by Clouseau, which analyses nightly crashes with an LLM. Nothing above was written or checked by a human. Please close it as INVALID if it is wrong — that is useful feedback, not a nuisance.
This is not an independent Mozilla discovery: the crash is known here only because somebody submitted the crash report linked at the top. If this duplicates an existing report, please resolve THIS bug as the duplicate and leave the credit with the earlier reporter.
Comment 1•1 month ago
|
||
Set release status flags based on info from the regressing bug 2079474
| Assignee | ||
Comment 2•1 month ago
|
||
A culled picture keeps the raster config of the last frame it was drawn in, whose surface index can be past the end of this frame's surfaces.
Updated•1 month ago
|
| Assignee | ||
Updated•1 month ago
|
Comment 4•1 month ago
|
||
| bugherder | ||
Description
•