Closed Bug 558211 Opened 16 years ago Closed 16 years ago

Eliminate JS_SetObjectHook

Categories

(Core :: JavaScript Engine, defect)

Other Branch
defect
Not set
normal

Tracking

()

RESOLVED INVALID

People

(Reporter: jorendorff, Assigned: jorendorff)

Details

Attachments

(3 files)

I'm not sure we have any debuggers actually using this. It's a little hard to tell, because JSD enables the object hook by default, but disables it if the client asks for JSD_DISABLE_OBJECT_TRACE, aka jsdIDebuggerService.DISABLE_OBJECT_TRACE. ISTR Firebug uses that flag.
Also worth checking what venkman does.
(note: I put all the IDL changes in part 2, coming soon)
Assignee: general → jorendorff
Attachment #438880 - Flags: review?
Summary: Investigate eliminating JS_SetObjectHook → Eliminate JS_SetObjectHook
Attachment #438882 - Flags: review?(gal) → review+
Comment on attachment 438882 [details] [diff] [review] part 3, remove JS_SetObjectHook from the js engine - v1 Good bye new object hook. You won't be missed around here.
It looks like Venkman is using JS_SetObjectHook. This function is getting metadata about an object that's gathered via the hook: http://mxr.mozilla.org/mozilla/source/extensions/venkman/resources/content/venkman-commands.js#918 You can look at an object and see where it was allocated -- useful stuff. Off by default though. There's no measurable performance improvement (on V8 or SunSpider) deleting the object hook, I think because neither JIT code nor anything called from JIT code even tests to see that the hook is set (it is guaranteed not to be set if we're on trace). It might be harmless to just leave it.
Attachment #438880 - Flags: review?
Attachment #438881 - Flags: review?(timeless)
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: