[Webkit-unassigned] [Bug 157136] New: Byte codes for dot call and bracket call of super are different

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Apr 28 07:03:47 PDT 2016


https://bugs.webkit.org/show_bug.cgi?id=157136

            Bug ID: 157136
           Summary: Byte codes for dot call and bracket call of super are
                    different
    Classification: Unclassified
           Product: WebKit
           Version: WebKit Nightly Build
          Hardware: Unspecified
                OS: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: JavaScriptCore
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: gskachkov at gmail.com

(new class D extends class { m() {}} { constructor() { super(); super['m']() } }())
[   0] enter             
[   1] get_scope         loc3
[   3] mov               loc4, loc3
[   6] mov               loc5, this
[   9] mov               this, <JSValue()>(const1)
[  12] get_by_id         loc6, head3, __proto__(@id0)    predicting None
[  21] mov               loc8, loc5
[  24] construct         loc6, loc6, 1, 14 status(Could Take Slow Path)    predicting None
[  33] is_empty          loc9, this
[  36] jtrue             loc9, 6(->42)
[  39] throw_static_error String (atomic) (identifier): 'super()' can't be called more than once in a constructor., ID: 4(const2), true
[  42] mov               this, loc6
[  45] get_by_id         loc6, head3, PrivateSymbol.homeObject(@id1)    predicting None
[  54] get_by_id         loc7, loc6, __proto__(@id0)    predicting None
[  63] get_by_id         loc8, loc7, m(@id2)    predicting None
[  72] op_check_tdz      this
[  74] mov               loc10, this
[  77] call              loc8, loc8, 1, 16 status(Could Take Slow Path)    Original; predicting None
[  86] op_check_tdz      this
[  88] is_object         loc6, this
[  91] jtrue             loc6, 16(->107)
[  94] is_undefined      loc6, this
[  97] jtrue             loc6, 6(->103)
[ 100] throw_static_error String (atomic) (identifier): Cannot return a non-object type in the constructor of a derived class., ID: 4(const3), false
[ 103] op_check_tdz      this
[ 105] ret               this
[ 107] ret               this


(new class D extends class { m() {}} { constructor() { super(); super.m() } }())
[   0] enter             
[   1] get_scope         loc3
[   3] mov               loc4, loc3
[   6] mov               loc5, this
[   9] mov               this, <JSValue()>(const1)
[  12] get_by_id         loc6, head3, __proto__(@id0)    predicting None
[  21] mov               loc8, loc5
[  24] construct         loc6, loc6, 1, 14 status(Could Take Slow Path)    predicting None
[  33] is_empty          loc9, this
[  36] jtrue             loc9, 6(->42)
[  39] throw_static_error String (atomic) (identifier): 'super()' can't be called more than once in a constructor., ID: 4(const2), true
[  42] mov               this, loc6
[  45] op_check_tdz      this
[  47] mov               loc8, this
[  50] get_by_id         loc9, head3, PrivateSymbol.homeObject(@id1)    predicting None
[  59] get_by_id         loc10, loc9, __proto__(@id0)    predicting None
[  68] get_by_id         loc6, loc10, m(@id2)    predicting None
[  77] call              loc6, loc6, 1, 14 status(Could Take Slow Path)    Original; predicting None
[  86] op_check_tdz      this
[  88] is_object         loc6, this
[  91] jtrue             loc6, 16(->107)
[  94] is_undefined      loc6, this
[  97] jtrue             loc6, 6(->103)
[ 100] throw_static_error String (atomic) (identifier): Cannot return a non-object type in the constructor of a derived class., ID: 4(const3), false
[ 103] op_check_tdz      this
[ 105] ret               this
[ 107] ret               this

For my prospective it should be the same byte code. lines 45 are diffrent

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20160428/1d6ce4f1/attachment-0001.html>


More information about the webkit-unassigned mailing list