Closed
Bug 707822
Opened 14 years ago
Closed 10 months ago
SpiderMonkey needs a way for tests to trigger recompilations at given points, and similar things
Categories
(Core :: JavaScript Engine, defect)
Tracking
()
RESOLVED
INCOMPLETE
People
(Reporter: jimb, Unassigned)
Details
In implementing Debugger, several times I needed to change a js_InternalInterpret case, but had a very difficult time producing a test that would reliably reach that path. In general, recompilations have a big impact on what's actually going on inside the engine, but are hard to reliably trigger. There should be an easy way for tests to force recompilations to happen at specific points.
My specific case: The REJOIN_THIS_PROTOTYPE case in js_InternalInterpret calls ScriptDebugEpilogue, but it is impossible to trigger reliably: ic::GetPropNoCache must cause a recompilation, which it only does when ic::GetProp calls ValueToObject and that lazily initializes a primitive class. I ended up manually adding a call to JS_GC to ic::GetPropNoCache to test the code, and then removing it.
There should be a way for a test to say, "DebugProbes.GetPropNoCacheRecompilation = true;", and then for the C++ code to check something and force a recompilation at that point. In non-DEBUG code, we should let the compiler see that the condition is never true, so it can toss the code.
Assignee | ||
Updated•11 years ago
|
Assignee: general → nobody
Updated•3 years ago
|
Severity: normal → S3
Updated•10 months ago
|
Status: NEW → RESOLVED
Closed: 10 months ago
Resolution: --- → INCOMPLETE
You need to log in
before you can comment on or make changes to this bug.
Description
•