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 #include "src/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #if V8_TARGET_ARCH_MIPS64 | 7 #if V8_TARGET_ARCH_MIPS64 |
8 | 8 |
9 #include "src/codegen.h" | 9 #include "src/codegen.h" |
10 #include "src/ic-inl.h" | 10 #include "src/ic-inl.h" |
(...skipping 1111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1122 | 1122 |
1123 #undef __ | 1123 #undef __ |
1124 #define __ ACCESS_MASM(masm()) | 1124 #define __ ACCESS_MASM(masm()) |
1125 | 1125 |
1126 | 1126 |
1127 Handle<Code> NamedStoreHandlerCompiler::CompileStoreInterceptor( | 1127 Handle<Code> NamedStoreHandlerCompiler::CompileStoreInterceptor( |
1128 Handle<JSObject> object, Handle<Name> name) { | 1128 Handle<JSObject> object, Handle<Name> name) { |
1129 __ Push(receiver(), this->name(), value()); | 1129 __ Push(receiver(), this->name(), value()); |
1130 | 1130 |
1131 // Do tail-call to the runtime system. | 1131 // Do tail-call to the runtime system. |
1132 ExternalReference store_ic_property = | 1132 ExternalReference store_ic_property = ExternalReference( |
1133 ExternalReference(IC_Utility(IC::kStoreInterceptorProperty), isolate()); | 1133 IC_Utility(IC::kStorePropertyWithInterceptor), isolate()); |
1134 __ TailCallExternalReference(store_ic_property, 3, 1); | 1134 __ TailCallExternalReference(store_ic_property, 3, 1); |
1135 | 1135 |
1136 // Return the generated code. | 1136 // Return the generated code. |
1137 return GetCode(kind(), Code::FAST, name); | 1137 return GetCode(kind(), Code::FAST, name); |
1138 } | 1138 } |
1139 | 1139 |
1140 | 1140 |
1141 Handle<Code> NamedLoadHandlerCompiler::CompileLoadNonexistent( | 1141 Handle<Code> NamedLoadHandlerCompiler::CompileLoadNonexistent( |
1142 Handle<HeapType> type, Handle<JSObject> last, Handle<Name> name) { | 1142 Handle<HeapType> type, Handle<JSObject> last, Handle<Name> name) { |
1143 NonexistentFrontend(type, last, name); | 1143 NonexistentFrontend(type, last, name); |
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1312 // Prepare tail call to StoreIC_ArrayLength. | 1312 // Prepare tail call to StoreIC_ArrayLength. |
1313 __ Push(receiver(), value()); | 1313 __ Push(receiver(), value()); |
1314 | 1314 |
1315 ExternalReference ref = | 1315 ExternalReference ref = |
1316 ExternalReference(IC_Utility(IC::kStoreIC_ArrayLength), | 1316 ExternalReference(IC_Utility(IC::kStoreIC_ArrayLength), |
1317 masm()->isolate()); | 1317 masm()->isolate()); |
1318 __ TailCallExternalReference(ref, 2, 1); | 1318 __ TailCallExternalReference(ref, 2, 1); |
1319 } | 1319 } |
1320 | 1320 |
1321 | 1321 |
1322 Handle<Code> PropertyICCompiler::CompileIndexedStorePolymorphic( | 1322 Handle<Code> PropertyICCompiler::CompileKeyedStorePolymorphic( |
1323 MapHandleList* receiver_maps, CodeHandleList* handler_stubs, | 1323 MapHandleList* receiver_maps, CodeHandleList* handler_stubs, |
1324 MapHandleList* transitioned_maps) { | 1324 MapHandleList* transitioned_maps) { |
1325 Label miss; | 1325 Label miss; |
1326 __ JumpIfSmi(receiver(), &miss); | 1326 __ JumpIfSmi(receiver(), &miss); |
1327 | 1327 |
1328 int receiver_count = receiver_maps->length(); | 1328 int receiver_count = receiver_maps->length(); |
1329 __ ld(scratch1(), FieldMemOperand(receiver(), HeapObject::kMapOffset)); | 1329 __ ld(scratch1(), FieldMemOperand(receiver(), HeapObject::kMapOffset)); |
1330 for (int i = 0; i < receiver_count; ++i) { | 1330 for (int i = 0; i < receiver_count; ++i) { |
1331 if (transitioned_maps->at(i).is_null()) { | 1331 if (transitioned_maps->at(i).is_null()) { |
1332 __ Jump(handler_stubs->at(i), RelocInfo::CODE_TARGET, eq, | 1332 __ Jump(handler_stubs->at(i), RelocInfo::CODE_TARGET, eq, |
(...skipping 12 matching lines...) Expand all Loading... |
1345 | 1345 |
1346 // Return the generated code. | 1346 // Return the generated code. |
1347 return GetCode(kind(), Code::NORMAL, factory()->empty_string(), POLYMORPHIC); | 1347 return GetCode(kind(), Code::NORMAL, factory()->empty_string(), POLYMORPHIC); |
1348 } | 1348 } |
1349 | 1349 |
1350 | 1350 |
1351 #undef __ | 1351 #undef __ |
1352 #define __ ACCESS_MASM(masm) | 1352 #define __ ACCESS_MASM(masm) |
1353 | 1353 |
1354 | 1354 |
1355 void IndexedHandlerCompiler::GenerateLoadDictionaryElement( | 1355 void ElementHandlerCompiler::GenerateLoadDictionaryElement( |
1356 MacroAssembler* masm) { | 1356 MacroAssembler* masm) { |
1357 // The return address is in ra | 1357 // The return address is in ra |
1358 Label slow, miss; | 1358 Label slow, miss; |
1359 | 1359 |
1360 Register key = LoadIC::NameRegister(); | 1360 Register key = LoadIC::NameRegister(); |
1361 Register receiver = LoadIC::ReceiverRegister(); | 1361 Register receiver = LoadIC::ReceiverRegister(); |
1362 ASSERT(receiver.is(a1)); | 1362 ASSERT(receiver.is(a1)); |
1363 ASSERT(key.is(a2)); | 1363 ASSERT(key.is(a2)); |
1364 | 1364 |
1365 __ UntagAndJumpIfNotSmi(a6, key, &miss); | 1365 __ UntagAndJumpIfNotSmi(a6, key, &miss); |
(...skipping 15 matching lines...) Expand all Loading... |
1381 | 1381 |
1382 TailCallBuiltin(masm, Builtins::kKeyedLoadIC_Miss); | 1382 TailCallBuiltin(masm, Builtins::kKeyedLoadIC_Miss); |
1383 } | 1383 } |
1384 | 1384 |
1385 | 1385 |
1386 #undef __ | 1386 #undef __ |
1387 | 1387 |
1388 } } // namespace v8::internal | 1388 } } // namespace v8::internal |
1389 | 1389 |
1390 #endif // V8_TARGET_ARCH_MIPS64 | 1390 #endif // V8_TARGET_ARCH_MIPS64 |
OLD | NEW |