Eliminate various unnecessary stack roots

RESOLVED FIXED in mozilla21

Status

()

Core
JavaScript Engine
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: bhackett, Unassigned)

Tracking

Other Branch
mozilla21
x86
Mac OS X
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

5 years ago
Created attachment 706525 [details] [diff] [review]
patch

The attached patch fixes various unnecessary roots in SS, reducing the number of constructed roots from 39% of the original total to 22%.  A fair amount of this is removing inference and compilation roots that with bug 772820 are now unnecessary, though there are various miscellaneous rooting refactorings as well.
Attachment #706525 - Flags: review?(terrence)
(Reporter)

Updated

5 years ago
Blocks: 831886
How big is the performance regression on SS now?
(Reporter)

Comment 2

5 years ago
I haven't measured, but will do so after this lands.  My target was to eliminate at least 80% of the roots so this is right about there.  There is still some more that can be done fwiw.
Comment on attachment 706525 [details] [diff] [review]
patch

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

::: js/src/jsobj.h
@@ +1134,2 @@
>  extern JSBool
> +HasOwnProperty(JSContext *cx, LookupGenericOp lookup,

Disregard my IRC request for a comment here. It did not occur to me that Has*Own*Property would need to throw exceptions.
Attachment #706525 - Flags: review?(terrence) → review+
(Reporter)

Comment 5

5 years ago
(In reply to Terrence Cole [:terrence] from comment #1)
> How big is the performance regression on SS now?

Testing on linux/x64 I get a difference of <1ms on SS, or .4%
https://hg.mozilla.org/mozilla-central/rev/052d2de29f8f
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla21
Depends on: 837418
You need to log in before you can comment on or make changes to this bug.