Closed Bug 479624 Opened 14 years ago Closed 14 years ago

Consider using JSAutoTempValueRooter instead of nsAutoGCRoot in nsJSContext::CallEventHandler

Categories

(Core :: DOM: Core & HTML, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla1.9.2a1

People

(Reporter: bent.mozilla, Assigned: bent.mozilla)

Details

(Keywords: fixed1.9.1, perf)

Attachments

(1 file)

Attached patch Patch, v1Splinter Review
Found this while sharking a worker/video demo, CallEventHandler uses the runtime to root its target value unnecessarily. We can get away with sticking the target on the context's temporary root chain I think. This removes a bunch of locking as the runtime rooting grabs the runtime lock.
Attachment #363496 - Flags: superreview?(jst)
Attachment #363496 - Flags: review?(mrbkap)
Assignee: nobody → bent.mozilla
Status: NEW → ASSIGNED
Attachment #363496 - Flags: review?(mrbkap) → review+
Attachment #363496 - Flags: superreview?(jst)
Attachment #363496 - Flags: superreview+
Attachment #363496 - Flags: approval1.9.1+
Comment on attachment 363496 [details] [diff] [review]
Patch, v1

Trivial, and gives a perf boost (by avoiding locking when rooting). a=jst
Keywords: checkin-needed
Whiteboard: [needs 1.9.1 landing after trunk]
http://hg.mozilla.org/mozilla-central/rev/bba6f7ba14d2
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Whiteboard: [needs 1.9.1 landing after trunk] → [needs 1.9.1 landing]
Target Milestone: --- → mozilla1.9.2a1
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.