Improve error handling in symbolication worker
Categories
(DevTools :: Performance Tools (Profiler/Timeline), task)
Tracking
(firefox96 fixed)
Tracking | Status | |
---|---|---|
firefox96 | --- | fixed |
People
(Reporter: mstange, Assigned: mstange)
Details
Attachments
(2 files)
The profiler-get-symbols wasm code currently has a case where it panics when it tries to obtain symbols for system libraries on macOS 12. This code is only run on macOS Beta versions, because for macOS release versions we have symbols on the symbol server.
When this panic occurs, the following happens:
- The promise which symbolication-worker.js
await
s is not rejected; the error isn't caught. - The worker stays around forever, and holds on to the bytes it read from files, forever.
- The symbolication status overlay in the Firefox profiler never disappears.
I'm going to address this hanging-forever in two pieces on this bug:
- I'm going to add an
unhandledrejection
handler which reports the error. - I've fixed the cause of the panic in profiler-get-symbols and will update the wasm blob.
With these changes, we still won't be able to obtain system library symbols on macOS 12 Beta versions, but at least we won't hang indefinitely any more. The macOS 12 issue is tracked in https://github.com/mstange/profiler-get-symbols/issues/22 .
Assignee | ||
Comment 1•2 years ago
|
||
Assignee | ||
Comment 2•2 years ago
|
||
This version aligns the FileHandle API with the new IOUtils SyncReadFile API, which saves a few lines of code.
It also fixes a panic which could occur if symbolication tried to do a large out-of-bounds file read.
This bad read range was computed due to incorrect parsing of the macOS 12 dyld shared cache format.
Depends on D132076
Pushed by mstange@themasta.com: https://hg.mozilla.org/integration/autoland/rev/14f5e60f8bcc Report errors from the symbolication worker even if they don't propagate to the main await call. r=canaltinova https://hg.mozilla.org/integration/autoland/rev/b41bce1fbd32 WIP: Bug 1742855 - Update profiler-get-symbols wasm to d1500c1e935db352eeb97170459d16a20bcddf08. r=canaltinova
Comment 4•2 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/14f5e60f8bcc
https://hg.mozilla.org/mozilla-central/rev/b41bce1fbd32
Description
•