Improve poor man's Maybe<AutoCompartment> in JSAutoEnterCompartment.

RESOLVED FIXED in mozilla10

Status

()

defect
RESOLVED FIXED
8 years ago
8 years ago

People

(Reporter: justin.lebar+bug, Unassigned)

Tracking

unspecified
mozilla10
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [iOS])

Attachments

(1 attachment)

We currently size the storage inside JSAutoEnterCompartment based on a platform-specific guess.  This broke ted's iOS port, and it's ugly.

We may be able to rely on the fact (?) that 32-bit systems with alignof(uint64) == 4 have 13-word AutoCompartments, while 32-bit systems with alignof(uint64) == 8 have 16-word AutoCompartments.
Posted patch Patch v1Splinter Review
Comment on attachment 565995 [details] [diff] [review]
Patch v1

I think this works.
Attachment #565995 - Flags: review?(luke)
Attachment #565995 - Flags: review?(luke) → review+
Depends on: 691192
https://hg.mozilla.org/mozilla-central/rev/962683b9d15a
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla10
Whiteboard: [inbound] → [inbound][iOS]
Whiteboard: [inbound][iOS] → [iOS]
Duplicate of this bug: 693585
Just for interest in case this dings other arches, on PPC this turned out to be 15 bytes, for some reason.
s/bytes/words/
You need to log in before you can comment on or make changes to this bug.