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_IA32 | 5 #if V8_TARGET_ARCH_IA32 |
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 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
146 void StubCache::GenerateProbe(MacroAssembler* masm, Code::Kind ic_kind, | 146 void StubCache::GenerateProbe(MacroAssembler* masm, Code::Kind ic_kind, |
147 Code::Flags flags, Register receiver, | 147 Code::Flags flags, Register receiver, |
148 Register name, Register scratch, Register extra, | 148 Register name, Register scratch, Register extra, |
149 Register extra2, Register extra3) { | 149 Register extra2, Register extra3) { |
150 Label miss; | 150 Label miss; |
151 | 151 |
152 // Assert that code is valid. The multiplying code relies on the entry size | 152 // Assert that code is valid. The multiplying code relies on the entry size |
153 // being 12. | 153 // being 12. |
154 DCHECK(sizeof(Entry) == 12); | 154 DCHECK(sizeof(Entry) == 12); |
155 | 155 |
156 // Assert the flags do not name a specific type. | |
157 DCHECK(Code::ExtractTypeFromFlags(flags) == 0); | |
158 | |
159 // Assert that there are no register conflicts. | 156 // Assert that there are no register conflicts. |
160 DCHECK(!scratch.is(receiver)); | 157 DCHECK(!scratch.is(receiver)); |
161 DCHECK(!scratch.is(name)); | 158 DCHECK(!scratch.is(name)); |
162 DCHECK(!extra.is(receiver)); | 159 DCHECK(!extra.is(receiver)); |
163 DCHECK(!extra.is(name)); | 160 DCHECK(!extra.is(name)); |
164 DCHECK(!extra.is(scratch)); | 161 DCHECK(!extra.is(scratch)); |
165 | 162 |
166 // Assert scratch and extra registers are valid, and extra2/3 are unused. | 163 // Assert scratch and extra registers are valid, and extra2/3 are unused. |
167 DCHECK(!scratch.is(no_reg)); | 164 DCHECK(!scratch.is(no_reg)); |
168 DCHECK(extra2.is(no_reg)); | 165 DCHECK(extra2.is(no_reg)); |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
210 __ bind(&miss); | 207 __ bind(&miss); |
211 __ IncrementCounter(counters->megamorphic_stub_cache_misses(), 1); | 208 __ IncrementCounter(counters->megamorphic_stub_cache_misses(), 1); |
212 } | 209 } |
213 | 210 |
214 | 211 |
215 #undef __ | 212 #undef __ |
216 } // namespace internal | 213 } // namespace internal |
217 } // namespace v8 | 214 } // namespace v8 |
218 | 215 |
219 #endif // V8_TARGET_ARCH_IA32 | 216 #endif // V8_TARGET_ARCH_IA32 |
OLD | NEW |