Changeset 204570 in webkit


Ignore:
Timestamp:
Aug 17, 2016, 2:00:45 PM (9 years ago)
Author:
mark.lam@apple.com
Message:

Remove an invalid assertion in the DFG backend's GetById emitter.
https://bugs.webkit.org/show_bug.cgi?id=160925
<rdar://problem/27248961>

Reviewed by Filip Pizlo.

JSTests:

  • stress/dfg-get-by-id-should-not-assert-non-null-prediction.js: Added.

Source/JavaScriptCore:

The DFG backend's GetById assertion that the node's prediction not be SpecNone
is just plain wrong. It assumes that we can never have a GetById node without a
type prediction, but this is not true. The following test case proves otherwise:

function foo() {

"use strict";
return --argumentscallee;

}

Will remove the assertion. Nothing else needs to change as the DFG is working
correctly without the assertion.

  • dfg/DFGSpeculativeJIT32_64.cpp:

(JSC::DFG::SpeculativeJIT::compile):

  • dfg/DFGSpeculativeJIT64.cpp:

(JSC::DFG::SpeculativeJIT::compile):

Location:
trunk
Files:
1 added
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/JSTests/ChangeLog

    r204504 r204570  
     12016-08-17  Mark Lam  <mark.lam@apple.com>
     2
     3        Remove an invalid assertion in the DFG backend's GetById emitter.
     4        https://bugs.webkit.org/show_bug.cgi?id=160925
     5        <rdar://problem/27248961>
     6
     7        Reviewed by Filip Pizlo.
     8
     9        * stress/dfg-get-by-id-should-not-assert-non-null-prediction.js: Added.
     10
    1112016-08-16  Ryan Haddad  <ryanhaddad@apple.com>
    212
  • trunk/Source/JavaScriptCore/ChangeLog

    r204542 r204570  
     12016-08-17  Mark Lam  <mark.lam@apple.com>
     2
     3        Remove an invalid assertion in the DFG backend's GetById emitter.
     4        https://bugs.webkit.org/show_bug.cgi?id=160925
     5        <rdar://problem/27248961>
     6
     7        Reviewed by Filip Pizlo.
     8
     9        The DFG backend's GetById assertion that the node's prediction not be SpecNone
     10        is just plain wrong.  It assumes that we can never have a GetById node without a
     11        type prediction, but this is not true.  The following test case proves otherwise:
     12
     13            function foo() {
     14                "use strict";
     15                return --arguments["callee"];
     16            }
     17
     18        Will remove the assertion.  Nothing else needs to change as the DFG is working
     19        correctly without the assertion.
     20
     21        * dfg/DFGSpeculativeJIT32_64.cpp:
     22        (JSC::DFG::SpeculativeJIT::compile):
     23        * dfg/DFGSpeculativeJIT64.cpp:
     24        (JSC::DFG::SpeculativeJIT::compile):
     25
    1262016-08-16  Mark Lam  <mark.lam@apple.com>
    227
  • trunk/Source/JavaScriptCore/dfg/DFGSpeculativeJIT32_64.cpp

    r204495 r204570  
    41764176
    41774177    case GetById: {
    4178         ASSERT(node->prediction());
    4179        
    41804178        switch (node->child1().useKind()) {
    41814179        case CellUse: {
  • trunk/Source/JavaScriptCore/dfg/DFGSpeculativeJIT64.cpp

    r204470 r204570  
    41214121
    41224122    case GetById: {
    4123         ASSERT(node->prediction());
    4124 
    41254123        switch (node->child1().useKind()) {
    41264124        case CellUse: {
Note: See TracChangeset for help on using the changeset viewer.