Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(351)

Side by Side Diff: runtime/vm/assembler_arm64.cc

Issue 1778103003: Invoke CallToRuntime via Thread instead of ObjectPools. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « runtime/vm/assembler_arm64.h ('k') | runtime/vm/assembler_ia32.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/globals.h" // NOLINT 5 #include "vm/globals.h" // NOLINT
6 #if defined(TARGET_ARCH_ARM64) 6 #if defined(TARGET_ARCH_ARM64)
7 7
8 #include "vm/assembler.h" 8 #include "vm/assembler.h"
9 #include "vm/cpu.h" 9 #include "vm/cpu.h"
10 #include "vm/longjump.h" 10 #include "vm/longjump.h"
(...skipping 594 matching lines...) Expand 10 before | Expand all | Expand 10 after
605 ldr(TMP, FieldAddress(CODE_REG, Code::entry_point_offset())); 605 ldr(TMP, FieldAddress(CODE_REG, Code::entry_point_offset()));
606 blr(TMP); 606 blr(TMP);
607 } 607 }
608 608
609 609
610 void Assembler::BranchLinkPatchable(const StubEntry& stub_entry) { 610 void Assembler::BranchLinkPatchable(const StubEntry& stub_entry) {
611 BranchLink(stub_entry, kPatchable); 611 BranchLink(stub_entry, kPatchable);
612 } 612 }
613 613
614 614
615 void Assembler::BranchLinkToRuntime() {
616 ldr(LR, Address(THR, Thread::call_to_runtime_entry_point_offset()));
617 ldr(CODE_REG, Address(THR, Thread::call_to_runtime_stub_offset()));
618 blr(LR);
619 }
620
621
615 void Assembler::BranchLinkWithEquivalence(const StubEntry& stub_entry, 622 void Assembler::BranchLinkWithEquivalence(const StubEntry& stub_entry,
616 const Object& equivalence) { 623 const Object& equivalence) {
617 const Code& target = Code::Handle(stub_entry.code()); 624 const Code& target = Code::Handle(stub_entry.code());
618 const int32_t offset = ObjectPool::element_offset( 625 const int32_t offset = ObjectPool::element_offset(
619 object_pool_wrapper_.FindObject(target, equivalence)); 626 object_pool_wrapper_.FindObject(target, equivalence));
620 LoadWordFromPoolOffset(CODE_REG, offset); 627 LoadWordFromPoolOffset(CODE_REG, offset);
621 ldr(TMP, FieldAddress(CODE_REG, Code::entry_point_offset())); 628 ldr(TMP, FieldAddress(CODE_REG, Code::entry_point_offset()));
622 blr(TMP); 629 blr(TMP);
623 } 630 }
624 631
(...skipping 860 matching lines...) Expand 10 before | Expand all | Expand 10 after
1485 add(base, array, Operand(index, LSL, shift)); 1492 add(base, array, Operand(index, LSL, shift));
1486 } 1493 }
1487 const OperandSize size = Address::OperandSizeFor(cid); 1494 const OperandSize size = Address::OperandSizeFor(cid);
1488 ASSERT(Address::CanHoldOffset(offset, Address::Offset, size)); 1495 ASSERT(Address::CanHoldOffset(offset, Address::Offset, size));
1489 return Address(base, offset, Address::Offset, size); 1496 return Address(base, offset, Address::Offset, size);
1490 } 1497 }
1491 1498
1492 } // namespace dart 1499 } // namespace dart
1493 1500
1494 #endif // defined TARGET_ARCH_ARM64 1501 #endif // defined TARGET_ARCH_ARM64
OLDNEW
« no previous file with comments | « runtime/vm/assembler_arm64.h ('k') | runtime/vm/assembler_ia32.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698