Closed Bug 640468 Opened 14 years ago Closed 13 years ago

JITs should be enabled on a per-compartment basis, not a per-context basis.

Categories

(Core :: JavaScript Engine, defect)

x86_64
Linux
defect
Not set
normal

Tracking

()

RESOLVED WONTFIX

People

(Reporter: jimb, Assigned: jimb)

References

(Blocks 1 open bug)

Details

At the moment, traceJitEnabled, methodJitEnabled, and profilingEnabled are flags in JSContext. However, it seems to me that they should be compartment flags, since those are the sorts of regions it makes sense to enable JITs for; a context can go all over the place. My motivation: this would make it more straightforward to make some debugging changes I'd like --- I'd like debugging hooks to be per-compartment, and debugging hooks affect whether JITs can be enabled, and to what degree. I haven't looked into the details yet; if this doesn't seem desirable, or if there are challenging details, please pipe up.
Easy to fix and great idea.
Splendid, splendid.
Assignee: general → jimb
(In reply to comment #0) > At the moment, traceJitEnabled, methodJitEnabled, and profilingEnabled are > flags in JSContext. However, it seems to me that they should be compartment > flags, since those are the sorts of regions it makes sense to enable JITs for; > a context can go all over the place. > > My motivation: this would make it more straightforward to make some debugging > changes I'd like --- I'd like debugging hooks to be per-compartment, and > debugging hooks affect whether JITs can be enabled, and to what degree. > > I haven't looked into the details yet; if this doesn't seem desirable, or if > there are challenging details, please pipe up. In general, it seems to me we should control jit activation at the granularity that makes sense for engine users. I'm not sure what that is, but compartment seems at least reasonable, since it does align with browser windows. If we did want to have a different granularity for users, it seems we could always override it for compartments as needed for debugging. Which is just to say that it seems fine to go ahead this way since it should not be hard to refine if we need to.
I don't think this bug accurately represents the change we need any more. Bug 716647 is a much better description.
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.