| Summary: | Add noDFG() to jsc to prevent DFG compilation of a specified function | ||||||
|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Mark Lam <mark.lam> | ||||
| Component: | JavaScriptCore | Assignee: | Mark Lam <mark.lam> | ||||
| Status: | RESOLVED FIXED | ||||||
| Severity: | Normal | CC: | benjamin, fpizlo, ggaren, keith_miller, msaboff, saam | ||||
| Priority: | P2 | ||||||
| Version: | WebKit Local Build | ||||||
| Hardware: | Unspecified | ||||||
| OS: | Unspecified | ||||||
| Attachments: |
|
||||||
|
Description
Mark Lam
2015-08-27 21:57:57 PDT
Created attachment 260120 [details]
the fix.
Comment on attachment 260120 [details] the fix. View in context: https://bugs.webkit.org/attachment.cgi?id=260120&action=review > Source/JavaScriptCore/jsc.cpp:635 > + addFunction(vm, "noOptimize", functionNeverOptimizeFunction, 1); Let's call this noDFG and functionNoDFG. "noOptimize" implies no baseline JIT, which is not the case. Comment on attachment 260120 [details]
the fix.
r=me
(In reply to comment #2) > Comment on attachment 260120 [details] > the fix. > > View in context: > https://bugs.webkit.org/attachment.cgi?id=260120&action=review > > > Source/JavaScriptCore/jsc.cpp:635 > > + addFunction(vm, "noOptimize", functionNeverOptimizeFunction, 1); > > Let's call this noDFG and functionNoDFG. "noOptimize" implies no baseline > JIT, which is not the case. I also like the name "dontDFGCompile" (In reply to comment #2) > Comment on attachment 260120 [details] > the fix. > > View in context: > https://bugs.webkit.org/attachment.cgi?id=260120&action=review > > > Source/JavaScriptCore/jsc.cpp:635 > > + addFunction(vm, "noOptimize", functionNeverOptimizeFunction, 1); > > Let's call this noDFG and functionNoDFG. "noOptimize" implies no baseline > JIT, which is not the case. I think fpizlo has always used the term “optimize” (in our code base) to mean DFG and higher, and precludes baseline. For example, in JITCode.h, he distinguished between isOptimizingJIT() and isBaselineCode(). And he suggested the term “noOptimize” when he asked me to implement this. But sure, I’ll change it to noDFG(). (In reply to comment #5) > But sure, I’ll change it to noDFG(). I just realized that you meant for me to only change the function in jsc.cpp and not elsewhere in the patch. Will do. Thanks for the reviews. I opted to go with noDFG() instead of dontDFGCompile() because noDFG() is shorter and adequately conveys the purpose. Landed in r189086: <http://trac.webkit.org/r189086>. |