Closed Bug 1363956 Opened 8 years ago Closed 8 years ago

Check the flag before calling expensive IsWindowProxy() in CheckedUnwrap()

Categories

(Core :: XPConnect, defect, P2)

All
Unspecified
defect

Tracking

()

RESOLVED FIXED
mozilla55
Performance Impact ?
Tracking Status
firefox55 --- fixed

People

(Reporter: ting, Assigned: ting)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

From the profile of test case attachment 8848224 [details], I see IsWindowProxy() under CheckedUnwrap() which is form GenericBindingGetter(), it can be avoid by checking |stopAtWindowProxy| at first.
Priority: -- → P2
Whiteboard: [qf]
Comment on attachment 8866615 [details] Bug 1363956 - Check the flag before calling relatively expensive IsWindowProxy(). https://reviewboard.mozilla.org/r/138220/#review141884 ::: commit-message-0b255:1 (Diff revision 1) > +Bug 1363956 - Check the flag before calling expensive IsWindowProxy(). r?bz How about: Check the stopAtWindowProxy flag before checking IsWindowProxy(), since the flag check is cheaper and in performance-sensitive binding code the flag is false. for the commit message?
Attachment #8866615 - Flags: review?(bzbarsky) → review+
Comment on attachment 8866615 [details] Bug 1363956 - Check the flag before calling relatively expensive IsWindowProxy(). https://reviewboard.mozilla.org/r/138220/#review141884 > How about: > > Check the stopAtWindowProxy flag before checking IsWindowProxy(), since the flag check is cheaper and in performance-sensitive binding code the flag is false. > > for the commit message? Added. I was kind of nervous because of your nick, the patch is straitghtforward which I didn't know how to make a more decent message, I've learned and thanks about that.
Pushed by tchou@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/e1bb35dd44fc Check the flag before calling relatively expensive IsWindowProxy(). r=bz
Assignee: nobody → janus926
Status: NEW → ASSIGNED
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla55
Performance Impact: --- → ?
Whiteboard: [qf]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: