RESOLVED FIXED 132437
Add a DFG function whitelist
https://bugs.webkit.org/show_bug.cgi?id=132437
Summary Add a DFG function whitelist
Mark Hahnenberg
Reported 2014-05-01 13:03:15 PDT
Often times when debugging using bytecode ranges isn't enough to narrow down to the particular DFG block that's causing issues. We should add the ability to whitelist specific functions specified in a file to enable further filtering without having to recompile.
Attachments
Patch (19.25 KB, patch)
2014-05-01 13:05 PDT, Mark Hahnenberg
no flags
Patch (23.03 KB, patch)
2014-05-01 15:07 PDT, Mark Hahnenberg
no flags
Patch (23.39 KB, patch)
2014-05-01 17:31 PDT, Mark Hahnenberg
no flags
Patch (23.42 KB, patch)
2014-05-01 17:39 PDT, Mark Hahnenberg
ggaren: review+
Mark Hahnenberg
Comment 1 2014-05-01 13:05:19 PDT
WebKit Commit Bot
Comment 2 2014-05-01 13:06:56 PDT
Attachment 230605 [details] did not pass style-queue: ERROR: Source/JavaScriptCore/runtime/Options.h:313: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] Total errors found: 1 in 10 files If any of these errors are false positives, please file a bug against check-webkit-style.
Mark Hahnenberg
Comment 3 2014-05-01 13:20:19 PDT
Boo, apparently strnstr and fgetln are BSD-only. So lame.
Geoffrey Garen
Comment 4 2014-05-01 14:17:06 PDT
Comment on attachment 230605 [details] Patch Plz fix.
Mark Hahnenberg
Comment 5 2014-05-01 15:07:22 PDT
WebKit Commit Bot
Comment 6 2014-05-01 15:09:13 PDT
Attachment 230615 [details] did not pass style-queue: ERROR: Source/JavaScriptCore/runtime/Options.h:313: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] Total errors found: 1 in 13 files If any of these errors are false positives, please file a bug against check-webkit-style.
Mark Hahnenberg
Comment 7 2014-05-01 15:09:39 PDT
Comment on attachment 230615 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=230615&action=review > Source/JavaScriptCore/bytecode/CodeBlock.cpp:3596 > + if (!profile) > + dataLog("Got null profile for bytecode ", bytecodeOffset, " in code block ", *this, "\n"); Remove.
Mark Hahnenberg
Comment 8 2014-05-01 15:11:20 PDT
Comment on attachment 230615 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=230615&action=review > Source/JavaScriptCore/dfg/DFGCapabilities.h:88 > + if (mightCompileFunctionForCall(codeBlock)) > + return capabilityLevel(codeBlock); > + if (mightInlineFunctionForCall(codeBlock)) > + return leastUpperBound(CanInline, capabilityLevel(codeBlock)); > + return CannotCompile; We should rearrange this to check both mightCompile/mightInline, then do the CodeBlock capability check accordingly.
Mark Hahnenberg
Comment 9 2014-05-01 17:31:33 PDT
WebKit Commit Bot
Comment 10 2014-05-01 17:33:02 PDT
Attachment 230633 [details] did not pass style-queue: ERROR: Source/JavaScriptCore/runtime/Options.h:313: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] Total errors found: 1 in 13 files If any of these errors are false positives, please file a bug against check-webkit-style.
Mark Hahnenberg
Comment 11 2014-05-01 17:39:56 PDT
WebKit Commit Bot
Comment 12 2014-05-01 17:42:04 PDT
Attachment 230634 [details] did not pass style-queue: ERROR: Source/JavaScriptCore/runtime/Options.h:313: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] Total errors found: 1 in 13 files If any of these errors are false positives, please file a bug against check-webkit-style.
Geoffrey Garen
Comment 13 2014-05-01 19:09:03 PDT
Comment on attachment 230634 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=230634&action=review r=me > Source/JavaScriptCore/dfg/DFGFunctionWhitelist.cpp:70 > + // Get rid of newlines at the end of the strings. "ends" > Source/JavaScriptCore/dfg/DFGFunctionWhitelist.cpp:73 > + if (line[length-1] == '\n') { > + line[length-1] = '\0'; spacing > Source/JavaScriptCore/dfg/DFGFunctionWhitelist.h:48 > + HashSet<String> m_functionNames; You should call this "entries" or something. It's not just names -- it's whitelist entries, which can be names or hashes or both concatenated.
Mark Hahnenberg
Comment 14 2014-05-02 11:52:41 PDT
Andreas Kling
Comment 15 2014-05-02 12:07:06 PDT
(In reply to comment #14) > Committed r168178: <http://trac.webkit.org/changeset/168178> This broke the cloop build.
Mark Hahnenberg
Comment 16 2014-05-02 14:16:36 PDT
(In reply to comment #15) > (In reply to comment #14) > > Committed r168178: <http://trac.webkit.org/changeset/168178> > > This broke the cloop build. Fix on the way!
Mark Lam
Comment 17 2014-05-22 15:42:26 PDT
*** Bug 131004 has been marked as a duplicate of this bug. ***
Note You need to log in before you can comment on or make changes to this bug.