OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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_MIPS | 5 #if V8_TARGET_ARCH_MIPS |
6 | 6 |
7 #include "src/codegen.h" | 7 #include "src/codegen.h" |
8 #include "src/ic/ic.h" | 8 #include "src/ic/ic.h" |
9 #include "src/ic/stub-cache.h" | 9 #include "src/ic/stub-cache.h" |
10 #include "src/interface-descriptors.h" | 10 #include "src/interface-descriptors.h" |
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
109 DCHECK(!scratch.is(no_reg)); | 109 DCHECK(!scratch.is(no_reg)); |
110 DCHECK(!extra.is(no_reg)); | 110 DCHECK(!extra.is(no_reg)); |
111 DCHECK(!extra2.is(no_reg)); | 111 DCHECK(!extra2.is(no_reg)); |
112 DCHECK(!extra3.is(no_reg)); | 112 DCHECK(!extra3.is(no_reg)); |
113 | 113 |
114 #ifdef DEBUG | 114 #ifdef DEBUG |
115 // If vector-based ics are in use, ensure that scratch, extra, extra2 and | 115 // If vector-based ics are in use, ensure that scratch, extra, extra2 and |
116 // extra3 don't conflict with the vector and slot registers, which need | 116 // extra3 don't conflict with the vector and slot registers, which need |
117 // to be preserved for a handler call or miss. | 117 // to be preserved for a handler call or miss. |
118 if (IC::ICUseVector(ic_kind)) { | 118 if (IC::ICUseVector(ic_kind)) { |
119 Register vector, slot; | 119 Register vector = LoadWithVectorDescriptor::VectorRegister(); |
120 if (ic_kind == Code::STORE_IC || ic_kind == Code::KEYED_STORE_IC) { | 120 Register slot = LoadWithVectorDescriptor::SlotRegister(); |
121 vector = VectorStoreICDescriptor::VectorRegister(); | |
122 slot = VectorStoreICDescriptor::SlotRegister(); | |
123 } else { | |
124 vector = LoadWithVectorDescriptor::VectorRegister(); | |
125 slot = LoadWithVectorDescriptor::SlotRegister(); | |
126 } | |
127 DCHECK(!AreAliased(vector, slot, scratch, extra, extra2, extra3)); | 121 DCHECK(!AreAliased(vector, slot, scratch, extra, extra2, extra3)); |
128 } | 122 } |
129 #endif | 123 #endif |
130 | 124 |
131 Counters* counters = masm->isolate()->counters(); | 125 Counters* counters = masm->isolate()->counters(); |
132 __ IncrementCounter(counters->megamorphic_stub_cache_probes(), 1, extra2, | 126 __ IncrementCounter(counters->megamorphic_stub_cache_probes(), 1, extra2, |
133 extra3); | 127 extra3); |
134 | 128 |
135 // Check that the receiver isn't a smi. | 129 // Check that the receiver isn't a smi. |
136 __ JumpIfSmi(receiver, &miss); | 130 __ JumpIfSmi(receiver, &miss); |
(...skipping 30 matching lines...) Expand all Loading... |
167 __ IncrementCounter(counters->megamorphic_stub_cache_misses(), 1, extra2, | 161 __ IncrementCounter(counters->megamorphic_stub_cache_misses(), 1, extra2, |
168 extra3); | 162 extra3); |
169 } | 163 } |
170 | 164 |
171 | 165 |
172 #undef __ | 166 #undef __ |
173 } // namespace internal | 167 } // namespace internal |
174 } // namespace v8 | 168 } // namespace v8 |
175 | 169 |
176 #endif // V8_TARGET_ARCH_MIPS | 170 #endif // V8_TARGET_ARCH_MIPS |
OLD | NEW |