| OLD | NEW |
| 1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #if V8_TARGET_ARCH_ARM64 | 5 #if V8_TARGET_ARCH_ARM64 |
| 6 | 6 |
| 7 #include "src/arm64/frames-arm64.h" | 7 #include "src/arm64/frames-arm64.h" |
| 8 #include "src/codegen.h" | 8 #include "src/codegen.h" |
| 9 #include "src/debug/debug.h" | 9 #include "src/debug/debug.h" |
| 10 #include "src/deoptimizer.h" | 10 #include "src/deoptimizer.h" |
| (...skipping 580 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 591 // on page 74. | 591 // on page 74. |
| 592 Label use_receiver, exit; | 592 Label use_receiver, exit; |
| 593 | 593 |
| 594 // If the result is a smi, it is *not* an object in the ECMA sense. | 594 // If the result is a smi, it is *not* an object in the ECMA sense. |
| 595 // x0: result | 595 // x0: result |
| 596 // jssp[0]: receiver (newly allocated object) | 596 // jssp[0]: receiver (newly allocated object) |
| 597 // jssp[1]: number of arguments (smi-tagged) | 597 // jssp[1]: number of arguments (smi-tagged) |
| 598 __ JumpIfSmi(x0, &use_receiver); | 598 __ JumpIfSmi(x0, &use_receiver); |
| 599 | 599 |
| 600 // If the type of the result (stored in its map) is less than | 600 // If the type of the result (stored in its map) is less than |
| 601 // FIRST_SPEC_OBJECT_TYPE, it is not an object in the ECMA sense. | 601 // FIRST_JS_RECEIVER_TYPE, it is not an object in the ECMA sense. |
| 602 __ JumpIfObjectType(x0, x1, x3, FIRST_SPEC_OBJECT_TYPE, &exit, ge); | 602 __ JumpIfObjectType(x0, x1, x3, FIRST_JS_RECEIVER_TYPE, &exit, ge); |
| 603 | 603 |
| 604 // Throw away the result of the constructor invocation and use the | 604 // Throw away the result of the constructor invocation and use the |
| 605 // on-stack receiver as the result. | 605 // on-stack receiver as the result. |
| 606 __ Bind(&use_receiver); | 606 __ Bind(&use_receiver); |
| 607 __ Peek(x0, 0); | 607 __ Peek(x0, 0); |
| 608 | 608 |
| 609 // Remove the receiver from the stack, remove caller arguments, and | 609 // Remove the receiver from the stack, remove caller arguments, and |
| 610 // return. | 610 // return. |
| 611 __ Bind(&exit); | 611 __ Bind(&exit); |
| 612 // x0: result | 612 // x0: result |
| (...skipping 1431 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2044 } | 2044 } |
| 2045 } | 2045 } |
| 2046 | 2046 |
| 2047 | 2047 |
| 2048 #undef __ | 2048 #undef __ |
| 2049 | 2049 |
| 2050 } // namespace internal | 2050 } // namespace internal |
| 2051 } // namespace v8 | 2051 } // namespace v8 |
| 2052 | 2052 |
| 2053 #endif // V8_TARGET_ARCH_ARM | 2053 #endif // V8_TARGET_ARCH_ARM |
| OLD | NEW |