RESOLVED FIXED 151747
Polymorphic operand types for DFG and FTL div.
https://bugs.webkit.org/show_bug.cgi?id=151747
Summary Polymorphic operand types for DFG and FTL div.
Mark Lam
Reported 2015-12-02 09:05:02 PST
Patch coming.
Attachments
x86_64 benchmark results with FTL. (63.59 KB, text/plain)
2015-12-07 23:57 PST, Mark Lam
no flags
x86_64 benchmark results with DFG only. (63.87 KB, text/plain)
2015-12-07 23:58 PST, Mark Lam
no flags
x86 benchmark results with DFG. (63.81 KB, text/plain)
2015-12-07 23:59 PST, Mark Lam
no flags
proposed patch. (27.88 KB, patch)
2015-12-08 00:20 PST, Mark Lam
buildbot: commit-queue-
Archive of layout-test-results from ews102 for mac-yosemite (799.98 KB, application/zip)
2015-12-08 01:07 PST, Build Bot
no flags
Archive of layout-test-results from ews105 for mac-yosemite-wk2 (975.78 KB, application/zip)
2015-12-08 01:10 PST, Build Bot
no flags
Archive of layout-test-results from ews114 for mac-yosemite (934.42 KB, application/zip)
2015-12-08 01:30 PST, Build Bot
no flags
proposed patch 2: fixed EWS failure. (28.68 KB, patch)
2015-12-08 11:31 PST, Mark Lam
no flags
patch 3: fixed valid style issues. (28.68 KB, patch)
2015-12-08 11:38 PST, Mark Lam
no flags
patch 4: Changed comment about 2 operands being const. (28.23 KB, patch)
2015-12-08 11:48 PST, Mark Lam
ggaren: review+
Radar WebKit Bug Importer
Comment 1 2015-12-02 09:08:23 PST
Mark Lam
Comment 2 2015-12-07 23:02:33 PST
*** Bug 151749 has been marked as a duplicate of this bug. ***
Mark Lam
Comment 3 2015-12-07 23:57:29 PST
Created attachment 266846 [details] x86_64 benchmark results with FTL.
Mark Lam
Comment 4 2015-12-07 23:58:38 PST
Created attachment 266847 [details] x86_64 benchmark results with DFG only.
Mark Lam
Comment 5 2015-12-07 23:59:10 PST
Created attachment 266848 [details] x86 benchmark results with DFG.
Mark Lam
Comment 6 2015-12-08 00:20:21 PST
Created attachment 266851 [details] proposed patch.
WebKit Commit Bot
Comment 7 2015-12-08 00:22:39 PST
Attachment 266851 [details] did not pass style-queue: ERROR: Source/JavaScriptCore/ftl/FTLInlineCacheDescriptorInlines.h:40: Wrong number of spaces before statement. (expected: 8) [whitespace/indent] [4] ERROR: Source/JavaScriptCore/ftl/FTLInlineCacheDescriptorInlines.h:40: Comma should be at the beginning of the line in a member initialization list. [whitespace/init] [4] Total errors found: 2 in 20 files If any of these errors are false positives, please file a bug against check-webkit-style.
Build Bot
Comment 8 2015-12-08 01:07:25 PST
Comment on attachment 266851 [details] proposed patch. Attachment 266851 [details] did not pass mac-ews (mac): Output: http://webkit-queues.webkit.org/results/531793 New failing tests: svg/in-html/sizing/svg-inline.html
Build Bot
Comment 9 2015-12-08 01:07:28 PST
Created attachment 266856 [details] Archive of layout-test-results from ews102 for mac-yosemite The attached test failures were seen while running run-webkit-tests on the mac-ews. Bot: ews102 Port: mac-yosemite Platform: Mac OS X 10.10.5
Build Bot
Comment 10 2015-12-08 01:10:39 PST
Comment on attachment 266851 [details] proposed patch. Attachment 266851 [details] did not pass mac-wk2-ews (mac-wk2): Output: http://webkit-queues.webkit.org/results/531797 New failing tests: svg/in-html/sizing/svg-inline.html
Build Bot
Comment 11 2015-12-08 01:10:41 PST
Created attachment 266858 [details] Archive of layout-test-results from ews105 for mac-yosemite-wk2 The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews. Bot: ews105 Port: mac-yosemite-wk2 Platform: Mac OS X 10.10.5
Build Bot
Comment 12 2015-12-08 01:30:47 PST
Comment on attachment 266851 [details] proposed patch. Attachment 266851 [details] did not pass mac-debug-ews (mac): Output: http://webkit-queues.webkit.org/results/531826 New failing tests: svg/in-html/sizing/svg-inline.html
Build Bot
Comment 13 2015-12-08 01:30:49 PST
Created attachment 266860 [details] Archive of layout-test-results from ews114 for mac-yosemite The attached test failures were seen while running run-webkit-tests on the mac-debug-ews. Bot: ews114 Port: mac-yosemite Platform: Mac OS X 10.10.5
Mark Lam
Comment 14 2015-12-08 09:18:37 PST
Comment on attachment 266851 [details] proposed patch. Taking off review while I investigate the EWS failure.
Mark Lam
Comment 15 2015-12-08 11:31:37 PST
Created attachment 266918 [details] proposed patch 2: fixed EWS failure. The EWS crashed test is due https://bugs.webkit.org/show_bug.cgi?id=151997. Applied a workaround in this patch.
WebKit Commit Bot
Comment 16 2015-12-08 11:34:17 PST
Attachment 266918 [details] did not pass style-queue: ERROR: Source/JavaScriptCore/dfg/DFGSpeculativeJIT.cpp:3754: Should have only a single space after a punctuation in a comment. [whitespace/comments] [5] ERROR: Source/JavaScriptCore/ftl/FTLLowerDFGToLLVM.cpp:1985: Should have only a single space after a punctuation in a comment. [whitespace/comments] [5] ERROR: Source/JavaScriptCore/ftl/FTLInlineCacheDescriptorInlines.h:40: Wrong number of spaces before statement. (expected: 8) [whitespace/indent] [4] ERROR: Source/JavaScriptCore/ftl/FTLInlineCacheDescriptorInlines.h:40: Comma should be at the beginning of the line in a member initialization list. [whitespace/init] [4] Total errors found: 4 in 20 files If any of these errors are false positives, please file a bug against check-webkit-style.
Geoffrey Garen
Comment 17 2015-12-08 11:34:41 PST
Comment on attachment 266918 [details] proposed patch 2: fixed EWS failure. View in context: https://bugs.webkit.org/attachment.cgi?id=266918&action=review > Source/JavaScriptCore/ftl/FTLLowerDFGToLLVM.cpp:1972 > + if (leftOperand.isConst()) { > + // FIXME: https://bugs.webkit.org/show_bug.cgi?id=151997 > + // The DFG should have folded a division of a const by a const into a const result, > + // but doesn't. For now, we work around it by treating the rightChild as not const. > + // We only saw this issue manifest with the DFG backend, but this check is added here > + // as a conservative defense until the issue is in the DFG front end. > + } else if (rightChild->isInt32Constant()) > + rightOperand.setConstInt32(rightChild->asInt32()); > +#if USE(JSVALUE64) > + else if (rightChild->isDoubleConstant()) > + rightOperand.setConstDouble(rightChild->asNumber()); Do all of our snippets make this assumption that they will never see two constants? I don't think this is a good assumption to make. Thought the DFG often optimizes constants, it does not promise to.
Mark Lam
Comment 18 2015-12-08 11:38:18 PST
Created attachment 266920 [details] patch 3: fixed valid style issues.
WebKit Commit Bot
Comment 19 2015-12-08 11:39:15 PST
Attachment 266920 [details] did not pass style-queue: ERROR: Source/JavaScriptCore/ftl/FTLInlineCacheDescriptorInlines.h:40: Wrong number of spaces before statement. (expected: 8) [whitespace/indent] [4] ERROR: Source/JavaScriptCore/ftl/FTLInlineCacheDescriptorInlines.h:40: Comma should be at the beginning of the line in a member initialization list. [whitespace/init] [4] Total errors found: 2 in 20 files If any of these errors are false positives, please file a bug against check-webkit-style.
Mark Lam
Comment 20 2015-12-08 11:48:16 PST
Created attachment 266923 [details] patch 4: Changed comment about 2 operands being const.
WebKit Commit Bot
Comment 21 2015-12-08 11:50:32 PST
Attachment 266923 [details] did not pass style-queue: ERROR: Source/JavaScriptCore/ftl/FTLInlineCacheDescriptorInlines.h:40: Wrong number of spaces before statement. (expected: 8) [whitespace/indent] [4] ERROR: Source/JavaScriptCore/ftl/FTLInlineCacheDescriptorInlines.h:40: Comma should be at the beginning of the line in a member initialization list. [whitespace/init] [4] Total errors found: 2 in 20 files If any of these errors are false positives, please file a bug against check-webkit-style.
Geoffrey Garen
Comment 22 2015-12-08 13:39:30 PST
Comment on attachment 266923 [details] patch 4: Changed comment about 2 operands being const. r=me
Mark Lam
Comment 23 2015-12-08 13:45:48 PST
Thanks for the review. Landed in r193781: <http://trac.webkit.org/r193781>.
Note You need to log in before you can comment on or make changes to this bug.