Closed Bug 1566824 Opened 6 years ago Closed 6 years ago

Intermittent GECKO(1732) | Assertion failure: aSize.width >= 0.0 && aSize.height >= 0.0, at /builds/worker/workspace/build/src/layout/base/nsLayoutUtils.cpp:8965

Categories

(Core :: Layout, defect, P5)

defect

Tracking

()

RESOLVED DUPLICATE of bug 1555457

People

(Reporter: intermittent-bug-filer, Unassigned)

References

Details

(Keywords: intermittent-failure, regression)

Filed by: dvarga [at] mozilla.com
Parsed log: https://treeherder.mozilla.org/logviewer.html#?job_id=256908935&repo=mozilla-inbound
Full log: https://queue.taskcluster.net/v1/task/EGk_3VxqQeC91IZaJfTR4g/runs/0/artifacts/public/logs/live_backing.log


11:56:10     INFO - TEST-PASS | devtools/client/responsive.html/test/browser/browser_viewport_resizing_fixed_width.js | Meta Viewport ON return to initial size should have expected layout height. - 
11:56:10     INFO - Closing responsive design mode
11:56:10     INFO - GECKO(1732) | [Parent 1732, Main Thread] WARNING: '!CanHandleWith(sPresContext)', file /builds/worker/workspace/build/src/dom/events/IMEStateManager.cpp, line 1152
11:56:10     INFO - GECKO(1732) | --DOMWINDOW == 14 (0x11ac46980) [pid = 1734] [serial = 179] [outer = 0x0] [url = about:blank]
11:56:10     INFO - GECKO(1732) | --DOMWINDOW == 13 (0x11ac46b60) [pid = 1734] [serial = 181] [outer = 0x0] [url = about:blank]
11:56:10     INFO - GECKO(1732) | Assertion failure: aSize.width >= 0.0 && aSize.height >= 0.0, at /builds/worker/workspace/build/src/layout/base/nsLayoutUtils.cpp:8965
11:56:10     INFO - GECKO(1732) | #01: MobileViewportManager::UpdateResolution(nsViewportInfo const&, mozilla::gfx::IntSizeTyped<mozilla::ScreenPixel> const&, mozilla::gfx::SizeTyped<mozilla::CSSPixel, float> const&, mozilla::Maybe<float> const&, MobileViewportManager::UpdateType) [layout/base/MobileViewportManager.cpp:0]
11:56:10     INFO - 
11:56:10     INFO - GECKO(1732) | #02: MobileViewportManager::RefreshViewportSize(bool) [layout/base/MobileViewportManager.cpp:539]
11:56:10     INFO - 
11:56:10     INFO - GECKO(1732) | #03: mozilla::PresShell::UpdateViewportOverridden(bool) [layout/base/PresShell.cpp:10595]
11:56:10     INFO - 
11:56:10     INFO - GECKO(1732) | #04: non-virtual thunk to nsDocShell::SetMetaViewportOverride(nsIDocShell::MetaViewportOverride) [docshell/base/nsDocShell.cpp:0]
11:56:10     INFO - 
11:56:10     INFO - GECKO(1732) | --DOMWINDOW == 106 (0x136733800) [pid = 1732] [serial = 400] [outer = 0x0] [url = about:blank]
11:56:10     INFO - GECKO(1732) | --DOMWINDOW == 105 (0x1144cfc00) [pid = 1732] [serial = 391] [outer = 0x0] [url = about:blank]
11:56:10     INFO - GECKO(1732) | --DOMWINDOW == 104 (0x12ffa2c00) [pid = 1732] [serial = 376] [outer = 0x0] [url = about:blank]
11:56:10     INFO - GECKO(1732) | --DOMWINDOW == 103 (0x11443e400) [pid = 1732] [serial = 387] [outer = 0x0] [url = about:blank]
11:56:10     INFO - GECKO(1732) | --DOMWINDOW == 102 (0x1201dbc00) [pid = 1732] [serial = 342] [outer = 0x0] [url = about:blank]
11:56:10     INFO - GECKO(1732) | --DOMWINDOW == 101 (0x130956000) [pid = 1732] [serial = 364] [outer = 0x0] [url = about:blank]
11:56:10     INFO - GECKO(1732) | --DOMWINDOW == 100 (0x1294ee400) [pid = 1732] [serial = 359] [outer = 0x0] [url = about:blank]
11:56:10     INFO - GECKO(1732) | --DOMWINDOW == 99 (0x129e7c400) [pid = 1732] [serial = 385] [outer = 0x0] [url = about:blank]
11:56:10     INFO - GECKO(1732) | --DOCSHELL 0x11457c000 == 31 [pid = 1732] [id = {a663d3f5-4c60-1f46-8f64-407617b15393}] [url = about:blank]
11:56:10     INFO - GECKO(1732) | --DOCSHELL 0x1201b5000 == 30 [pid = 1732] [id = {1f308fec-9283-e94e-9eef-26ca82bb0c8f}] [url = chrome://devtools/content/responsive.html/index.xhtml]
11:56:10     INFO - GECKO(1732) | --DOCSHELL 0x1201b9800 == 29 [pid = 1732] [id = {d127f4b6-c38b-6545-8d79-50ad8189d9a9}] [url = about:blank]
11:56:11     INFO - GECKO(1732) | [Parent 1732, Main Thread] WARNING: IPC message discarded: actor cannot send: file /builds/worker/workspace/build/src/ipc/glue/ProtocolUtils.cpp, line 568
11:56:11     INFO - GECKO(1732) | [Parent 1732, Main Thread] WARNING: IPC message discarded: actor cannot send: file /builds/worker/workspace/build/src/ipc/glue/ProtocolUtils.cpp, line 568
11:56:11     INFO - GECKO(1732) | JavaScript error: resource://gre/modules/BrowserElementParent.jsm, line 214: NS_ERROR_ILLEGAL_VALUE: Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIXPCComponents_Utils.isDeadWrapper]
11:56:11     INFO - GECKO(1732) | JavaScript error: resource://gre/modules/BrowserElementParent.jsm, line 214: NS_ERROR_ILLEGAL_VALUE: Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIXPCComponents_Utils.isDeadWrapper]
11:56:11     INFO - GECKO(1732) | JavaScript error: resource://gre/modules/BrowserElementParent.jsm, line 214: NS_ERROR_ILLEGAL_VALUE: Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIXPCComponents_Utils.isDeadWrapper]
11:56:11     INFO - GECKO(1732) | JavaScript error: resource://gre/modules/BrowserElementParent.jsm, line 214: NS_ERROR_ILLEGAL_VALUE: Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIXPCComponents_Utils.isDeadWrapper]
11:56:11     INFO - GECKO(1732) | JavaScript error: resource://gre/modules/BrowserElementParent.jsm, line 214: NS_ERROR_ILLEGAL_VALUE: Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIXPCComponents_Utils.isDeadWrapper]
11:56:11     INFO - GECKO(1732) | JavaScript error: resource://gre/modules/BrowserElementParent.jsm, line 214: NS_ERROR_ILLEGAL_VALUE: Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIXPCComponents_Utils.isDeadWrapper]
11:56:11     INFO - GECKO(1732) | JavaScript error: resource://gre/modules/BrowserElementParent.jsm, line 214: NS_ERROR_ILLEGAL_VALUE: Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIXPCComponents_Utils.isDeadWrapper]
11:56:11     INFO - GECKO(1732) | JavaScript error: resource://gre/modules/BrowserElementParent.jsm, line 214: NS_ERROR_ILLEGAL_VALUE: Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIXPCComponents_Utils.isDeadWrapper]
11:56:11     INFO - GECKO(1732) | JavaScript error: resource://gre/modules/BrowserElementParent.jsm, line 214: NS_ERROR_ILLEGAL_VALUE: Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIXPCComponents_Utils.isDeadWrapper]
11:56:11     INFO - GECKO(1732) | JavaScript error: resource://gre/modules/BrowserElementParent.jsm, line 214: NS_ERROR_ILLEGAL_VALUE: Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIXPCComponents_Utils.isDeadWrapper]
11:56:11     INFO - GECKO(1732) | JavaScript error: resource://gre/modules/BrowserElementParent.jsm, line 214: NS_ERROR_ILLEGAL_VALUE: Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIXPCComponents_Utils.isDeadWrapper]
11:56:11     INFO - GECKO(1732) | JavaScript error: resource://gre/modules/BrowserElementParent.jsm, line 214: NS_ERROR_ILLEGAL_VALUE: Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIXPCComponents_Utils.isDeadWrapper]
11:56:11     INFO - TEST-INFO | started process screencapture
11:56:11     INFO - TEST-INFO | screencapture: exit 0
11:56:11     INFO - TEST-UNEXPECTED-FAIL | devtools/client/responsive.html/test/browser/browser_viewport_resizing_fixed_width.js | uncaught exception - TypeError: aBrowser.webProgress is undefined at updateBrowserRemoteness@chrome://browser/content/tabbrowser.js:1867:7

The assertion in question is here:
https://searchfox.org/mozilla-central/rev/4fbcfe6fecf75d7b828fbebda79a31385f7eab5f/layout/base/nsLayoutUtils.cpp#8965

And the passed-in value comes from this expression (along with a zoom factor):

 ScreenSize compositionSize = ScreenSize(GetCompositionSize(aDisplaySize));

https://searchfox.org/mozilla-central/rev/4fbcfe6fecf75d7b828fbebda79a31385f7eab5f/layout/base/MobileViewportManager.cpp#435-439

GetCompositionSize subtracts out scrollbars and clamps to 0, so it's not immediately obvious to me how we're ending up with something negative in this codepath.

Larger snippet:

  ScreenSize compositionSize = ScreenSize(GetCompositionSize(aDisplaySize));

  CSSSize compSize = compositionSize / aZoom;
  MVM_LOG("%p: Setting VVPS %s\n", this, Stringify(compSize).c_str());
  mContext->SetVisualViewportSize(compSize);
}
  • The assertion failure means one or both components of compSize are negative.
  • The GetCompositionSize clamps its return value to be nonnegative, so compositionSize should be nonnegative.
  • Therefore, I suspect aZoom must be negative, and it's the / aZoom operation that's producing a negative size here.

Also notable: this assertion failure is happening right after a log message that says Closing responsive design mode.

Oh, I suppose it's also conceivable that aZoom is 0 and so the aZoom division is actually doing 0/0 = NaN or something, too. That would make this assertion fail.

I don't immediately see constraints on aZoom in the calling functions - we probably need to enforce somewhere that it's greater than zero.

Depends on: 1566991

Daniel isn't this a duplicate of Bug 1555457?

Flags: needinfo?(dholbert)

Yeah, looks like it. The failing assertion has just moved slightly due to changes elsewhere in the file.

Status: NEW → RESOLVED
Closed: 6 years ago
Flags: needinfo?(dholbert)
Resolution: --- → DUPLICATE
Depends on: 1568673
You need to log in before you can comment on or make changes to this bug.