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

Side by Side Diff: src/ic/arm64/ic-arm64.cc

Issue 2732273003: Disentangle assembler from isolate. (Closed)
Patch Set: Address feedback. Created 3 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 | « src/ia32/macro-assembler-ia32.cc ('k') | src/isolate.cc » ('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 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/assembler-arm64-inl.h" 7 #include "src/arm64/assembler-arm64-inl.h"
8 #include "src/codegen.h" 8 #include "src/codegen.h"
9 #include "src/ic/ic.h" 9 #include "src/ic/ic.h"
10 #include "src/ic/stub-cache.h" 10 #include "src/ic/stub-cache.h"
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 LOG(isolate, PatchIC(address, info_address, info.SmiCheckDelta())); 64 LOG(isolate, PatchIC(address, info_address, info.SmiCheckDelta()));
65 } 65 }
66 66
67 // Patch and activate code generated by JumpPatchSite::EmitJumpIfNotSmi() 67 // Patch and activate code generated by JumpPatchSite::EmitJumpIfNotSmi()
68 // and JumpPatchSite::EmitJumpIfSmi(). 68 // and JumpPatchSite::EmitJumpIfSmi().
69 // Changing 69 // Changing
70 // tb(n)z xzr, #0, <target> 70 // tb(n)z xzr, #0, <target>
71 // to 71 // to
72 // tb(!n)z test_reg, #0, <target> 72 // tb(!n)z test_reg, #0, <target>
73 Instruction* to_patch = info.SmiCheck(); 73 Instruction* to_patch = info.SmiCheck();
74 PatchingAssembler patcher(isolate, to_patch, 1); 74 PatchingAssembler patcher(isolate, reinterpret_cast<byte*>(to_patch), 1);
75 DCHECK(to_patch->IsTestBranch()); 75 DCHECK(to_patch->IsTestBranch());
76 DCHECK(to_patch->ImmTestBranchBit5() == 0); 76 DCHECK(to_patch->ImmTestBranchBit5() == 0);
77 DCHECK(to_patch->ImmTestBranchBit40() == 0); 77 DCHECK(to_patch->ImmTestBranchBit40() == 0);
78 78
79 STATIC_ASSERT(kSmiTag == 0); 79 STATIC_ASSERT(kSmiTag == 0);
80 STATIC_ASSERT(kSmiTagMask == 1); 80 STATIC_ASSERT(kSmiTagMask == 1);
81 81
82 int branch_imm = to_patch->ImmTestBranch(); 82 int branch_imm = to_patch->ImmTestBranch();
83 Register smi_reg; 83 Register smi_reg;
84 if (check == ENABLE_INLINED_SMI_CHECK) { 84 if (check == ENABLE_INLINED_SMI_CHECK) {
(...skipping 11 matching lines...) Expand all
96 } else { 96 } else {
97 DCHECK(to_patch->Mask(TestBranchMask) == TBNZ); 97 DCHECK(to_patch->Mask(TestBranchMask) == TBNZ);
98 // This is JumpIfSmi(smi_reg, branch_imm). 98 // This is JumpIfSmi(smi_reg, branch_imm).
99 patcher.tbz(smi_reg, 0, branch_imm); 99 patcher.tbz(smi_reg, 0, branch_imm);
100 } 100 }
101 } 101 }
102 } // namespace internal 102 } // namespace internal
103 } // namespace v8 103 } // namespace v8
104 104
105 #endif // V8_TARGET_ARCH_ARM64 105 #endif // V8_TARGET_ARCH_ARM64
OLDNEW
« no previous file with comments | « src/ia32/macro-assembler-ia32.cc ('k') | src/isolate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698