| 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 #include "v8.h" | 5 #include "v8.h" |
| 6 | 6 |
| 7 #if V8_TARGET_ARCH_ARM64 | 7 #if V8_TARGET_ARCH_ARM64 |
| 8 | 8 |
| 9 #include "codegen.h" | 9 #include "codegen.h" |
| 10 #include "macro-assembler.h" | 10 #include "macro-assembler.h" |
| (...skipping 455 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 466 | 466 |
| 467 // Handle external strings. | 467 // Handle external strings. |
| 468 __ Bind(&external_string); | 468 __ Bind(&external_string); |
| 469 if (FLAG_debug_code) { | 469 if (FLAG_debug_code) { |
| 470 // Assert that we do not have a cons or slice (indirect strings) here. | 470 // Assert that we do not have a cons or slice (indirect strings) here. |
| 471 // Sequential strings have already been ruled out. | 471 // Sequential strings have already been ruled out. |
| 472 __ Tst(result, kIsIndirectStringMask); | 472 __ Tst(result, kIsIndirectStringMask); |
| 473 __ Assert(eq, kExternalStringExpectedButNotFound); | 473 __ Assert(eq, kExternalStringExpectedButNotFound); |
| 474 } | 474 } |
| 475 // Rule out short external strings. | 475 // Rule out short external strings. |
| 476 STATIC_CHECK(kShortExternalStringTag != 0); | 476 STATIC_ASSERT(kShortExternalStringTag != 0); |
| 477 // TestAndBranchIfAnySet can emit Tbnz. Do not use it because call_runtime | 477 // TestAndBranchIfAnySet can emit Tbnz. Do not use it because call_runtime |
| 478 // can be bound far away in deferred code. | 478 // can be bound far away in deferred code. |
| 479 __ Tst(result, kShortExternalStringMask); | 479 __ Tst(result, kShortExternalStringMask); |
| 480 __ B(ne, call_runtime); | 480 __ B(ne, call_runtime); |
| 481 __ Ldr(string, FieldMemOperand(string, ExternalString::kResourceDataOffset)); | 481 __ Ldr(string, FieldMemOperand(string, ExternalString::kResourceDataOffset)); |
| 482 | 482 |
| 483 Label ascii, done; | 483 Label ascii, done; |
| 484 __ Bind(&check_encoding); | 484 __ Bind(&check_encoding); |
| 485 STATIC_ASSERT(kTwoByteStringTag == 0); | 485 STATIC_ASSERT(kTwoByteStringTag == 0); |
| 486 __ TestAndBranchIfAnySet(result, kStringEncodingMask, &ascii); | 486 __ TestAndBranchIfAnySet(result, kStringEncodingMask, &ascii); |
| (...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 611 __ Fmul(result, double_temp3, double_temp1); | 611 __ Fmul(result, double_temp3, double_temp1); |
| 612 | 612 |
| 613 __ Bind(&done); | 613 __ Bind(&done); |
| 614 } | 614 } |
| 615 | 615 |
| 616 #undef __ | 616 #undef __ |
| 617 | 617 |
| 618 } } // namespace v8::internal | 618 } } // namespace v8::internal |
| 619 | 619 |
| 620 #endif // V8_TARGET_ARCH_ARM64 | 620 #endif // V8_TARGET_ARCH_ARM64 |
| OLD | NEW |