| 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 #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/ic/ic.h" | 9 #include "src/ic/ic.h" | 
| 10 #include "src/ic/ic-compiler.h" | 10 #include "src/ic/ic-compiler.h" | 
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 55   __ ld(map_reg, FieldMemOperand(receiver(), HeapObject::kMapOffset)); | 55   __ ld(map_reg, FieldMemOperand(receiver(), HeapObject::kMapOffset)); | 
| 56   for (int current = 0; current < receiver_count; ++current) { | 56   for (int current = 0; current < receiver_count; ++current) { | 
| 57     Handle<HeapType> type = types->at(current); | 57     Handle<HeapType> type = types->at(current); | 
| 58     Handle<Map> map = IC::TypeToMap(*type, isolate()); | 58     Handle<Map> map = IC::TypeToMap(*type, isolate()); | 
| 59     if (!map->is_deprecated()) { | 59     if (!map->is_deprecated()) { | 
| 60       number_of_handled_maps++; | 60       number_of_handled_maps++; | 
| 61       // Check map and tail call if there's a match. | 61       // Check map and tail call if there's a match. | 
| 62       // Separate compare from branch, to provide path for above JumpIfSmi(). | 62       // Separate compare from branch, to provide path for above JumpIfSmi(). | 
| 63       Handle<WeakCell> cell = Map::WeakCellForMap(map); | 63       Handle<WeakCell> cell = Map::WeakCellForMap(map); | 
| 64       __ GetWeakValue(match, cell); | 64       __ GetWeakValue(match, cell); | 
|  | 65       __ Dsubu(match, match, Operand(map_reg)); | 
| 65       if (type->Is(HeapType::Number())) { | 66       if (type->Is(HeapType::Number())) { | 
| 66         DCHECK(!number_case.is_unused()); | 67         DCHECK(!number_case.is_unused()); | 
| 67         __ bind(&number_case); | 68         __ bind(&number_case); | 
| 68       } | 69       } | 
| 69       __ Jump(handlers->at(current), RelocInfo::CODE_TARGET, eq, match, | 70       __ Jump(handlers->at(current), RelocInfo::CODE_TARGET, eq, match, | 
| 70               Operand(map_reg)); | 71               Operand(zero_reg)); | 
| 71     } | 72     } | 
| 72   } | 73   } | 
| 73   DCHECK(number_of_handled_maps != 0); | 74   DCHECK(number_of_handled_maps != 0); | 
| 74 | 75 | 
| 75   __ bind(&miss); | 76   __ bind(&miss); | 
| 76   TailCallBuiltin(masm(), MissBuiltin(kind())); | 77   TailCallBuiltin(masm(), MissBuiltin(kind())); | 
| 77 | 78 | 
| 78   // Return the generated code. | 79   // Return the generated code. | 
| 79   InlineCacheState state = | 80   InlineCacheState state = | 
| 80       number_of_handled_maps > 1 ? POLYMORPHIC : MONOMORPHIC; | 81       number_of_handled_maps > 1 ? POLYMORPHIC : MONOMORPHIC; | 
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 131   // Do tail-call to runtime routine. | 132   // Do tail-call to runtime routine. | 
| 132   __ TailCallRuntime(Runtime::kSetProperty, 4, 1); | 133   __ TailCallRuntime(Runtime::kSetProperty, 4, 1); | 
| 133 } | 134 } | 
| 134 | 135 | 
| 135 | 136 | 
| 136 #undef __ | 137 #undef __ | 
| 137 } | 138 } | 
| 138 }  // namespace v8::internal | 139 }  // namespace v8::internal | 
| 139 | 140 | 
| 140 #endif  // V8_TARGET_ARCH_MIPS64 | 141 #endif  // V8_TARGET_ARCH_MIPS64 | 
| OLD | NEW | 
|---|