OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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_PPC | 5 #if V8_TARGET_ARCH_PPC |
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 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
130 DCHECK(!scratch.is(no_reg)); | 130 DCHECK(!scratch.is(no_reg)); |
131 DCHECK(!extra.is(no_reg)); | 131 DCHECK(!extra.is(no_reg)); |
132 DCHECK(!extra2.is(no_reg)); | 132 DCHECK(!extra2.is(no_reg)); |
133 DCHECK(!extra3.is(no_reg)); | 133 DCHECK(!extra3.is(no_reg)); |
134 | 134 |
135 #ifdef DEBUG | 135 #ifdef DEBUG |
136 // If vector-based ics are in use, ensure that scratch, extra, extra2 and | 136 // If vector-based ics are in use, ensure that scratch, extra, extra2 and |
137 // extra3 don't conflict with the vector and slot registers, which need | 137 // extra3 don't conflict with the vector and slot registers, which need |
138 // to be preserved for a handler call or miss. | 138 // to be preserved for a handler call or miss. |
139 if (IC::ICUseVector(ic_kind)) { | 139 if (IC::ICUseVector(ic_kind)) { |
140 Register vector = LoadWithVectorDescriptor::VectorRegister(); | 140 Register vector, slot; |
141 Register slot = LoadWithVectorDescriptor::SlotRegister(); | 141 if (ic_kind == Code::STORE_IC || ic_kind == Code::KEYED_STORE_IC) { |
| 142 vector = VectorStoreICDescriptor::VectorRegister(); |
| 143 slot = VectorStoreICDescriptor::SlotRegister(); |
| 144 } else { |
| 145 vector = LoadWithVectorDescriptor::VectorRegister(); |
| 146 slot = LoadWithVectorDescriptor::SlotRegister(); |
| 147 } |
142 DCHECK(!AreAliased(vector, slot, scratch, extra, extra2, extra3)); | 148 DCHECK(!AreAliased(vector, slot, scratch, extra, extra2, extra3)); |
143 } | 149 } |
144 #endif | 150 #endif |
145 | 151 |
146 Counters* counters = masm->isolate()->counters(); | 152 Counters* counters = masm->isolate()->counters(); |
147 __ IncrementCounter(counters->megamorphic_stub_cache_probes(), 1, extra2, | 153 __ IncrementCounter(counters->megamorphic_stub_cache_probes(), 1, extra2, |
148 extra3); | 154 extra3); |
149 | 155 |
150 // Check that the receiver isn't a smi. | 156 // Check that the receiver isn't a smi. |
151 __ JumpIfSmi(receiver, &miss); | 157 __ JumpIfSmi(receiver, &miss); |
(...skipping 27 matching lines...) Expand all Loading... |
179 __ IncrementCounter(counters->megamorphic_stub_cache_misses(), 1, extra2, | 185 __ IncrementCounter(counters->megamorphic_stub_cache_misses(), 1, extra2, |
180 extra3); | 186 extra3); |
181 } | 187 } |
182 | 188 |
183 | 189 |
184 #undef __ | 190 #undef __ |
185 } // namespace internal | 191 } // namespace internal |
186 } // namespace v8 | 192 } // namespace v8 |
187 | 193 |
188 #endif // V8_TARGET_ARCH_PPC | 194 #endif // V8_TARGET_ARCH_PPC |
OLD | NEW |