wasm code ranges are sent to the profiler tools before the name metadata is filled

RESOLVED FIXED in Firefox 65

Status

()

enhancement
RESOLVED FIXED
9 months ago
9 months ago

People

(Reporter: bbouvier, Assigned: bbouvier)

Tracking

unspecified
mozilla65
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(firefox65 fixed)

Details

Attachments

(1 attachment)

Reported by jesup on irc. The name section is decoded and filled at the same time as custom sections are, after we call finishMetadata(), which creates the perf maps and try to read from the function name vector. This was probably introduced by bug 1487475.
Posted patch fix.patchSplinter Review
The fix just consists in moving the custom section reading (and data vector bytes copy) before we finish the metadata. Also changed the finishMetadata() API so it's an invariant that metadata_ can't be touched after the call to finishMetadata().
Assignee: nobody → bbouvier
Status: NEW → ASSIGNED
Attachment #9019739 - Flags: review?(luke)
Comment on attachment 9019739 [details] [diff] [review]
fix.patch

Review of attachment 9019739 [details] [diff] [review]:
-----------------------------------------------------------------

Nice fix!
Attachment #9019739 - Flags: review?(luke) → review+
Pushed by bbouvier@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/ca965ec1bc91
Move the custom section read before finishing a wasm module's metadata; r=luke
https://hg.mozilla.org/mozilla-central/rev/ca965ec1bc91
Status: ASSIGNED → RESOLVED
Closed: 9 months ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla65
You need to log in before you can comment on or make changes to this bug.