| 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_MIPS64 | 5 #if V8_TARGET_ARCH_MIPS64 |
| 6 | 6 |
| 7 // Note on Mips implementation: | 7 // Note on Mips implementation: |
| 8 // | 8 // |
| 9 // The result_register() for mips is the 'v0' register, which is defined | 9 // The result_register() for mips is the 'v0' register, which is defined |
| 10 // by the ABI to contain function return values. However, the first | 10 // by the ABI to contain function return values. However, the first |
| (...skipping 1249 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1260 __ Branch(done, ne, at, Operand(zero_reg)); | 1260 __ Branch(done, ne, at, Operand(zero_reg)); |
| 1261 __ li(a0, Operand(var->name())); | 1261 __ li(a0, Operand(var->name())); |
| 1262 __ push(a0); | 1262 __ push(a0); |
| 1263 __ CallRuntime(Runtime::kThrowReferenceError); | 1263 __ CallRuntime(Runtime::kThrowReferenceError); |
| 1264 } else { | 1264 } else { |
| 1265 __ Branch(done); | 1265 __ Branch(done); |
| 1266 } | 1266 } |
| 1267 } | 1267 } |
| 1268 } | 1268 } |
| 1269 | 1269 |
| 1270 | |
| 1271 void FullCodeGenerator::EmitGlobalVariableLoad(VariableProxy* proxy, | |
| 1272 TypeofMode typeof_mode) { | |
| 1273 #ifdef DEBUG | |
| 1274 Variable* var = proxy->var(); | |
| 1275 DCHECK(var->IsUnallocated() || | |
| 1276 (var->IsLookupSlot() && var->mode() == DYNAMIC_GLOBAL)); | |
| 1277 #endif | |
| 1278 __ li(LoadGlobalDescriptor::SlotRegister(), | |
| 1279 Operand(SmiFromSlot(proxy->VariableFeedbackSlot()))); | |
| 1280 CallLoadGlobalIC(typeof_mode); | |
| 1281 } | |
| 1282 | |
| 1283 | |
| 1284 void FullCodeGenerator::EmitVariableLoad(VariableProxy* proxy, | 1270 void FullCodeGenerator::EmitVariableLoad(VariableProxy* proxy, |
| 1285 TypeofMode typeof_mode) { | 1271 TypeofMode typeof_mode) { |
| 1286 // Record position before possible IC call. | 1272 // Record position before possible IC call. |
| 1287 SetExpressionPosition(proxy); | 1273 SetExpressionPosition(proxy); |
| 1288 PrepareForBailoutForId(proxy->BeforeId(), BailoutState::NO_REGISTERS); | 1274 PrepareForBailoutForId(proxy->BeforeId(), BailoutState::NO_REGISTERS); |
| 1289 Variable* var = proxy->var(); | 1275 Variable* var = proxy->var(); |
| 1290 | 1276 |
| 1291 // Three cases: global variables, lookup variables, and all other types of | 1277 // Three cases: global variables, lookup variables, and all other types of |
| 1292 // variables. | 1278 // variables. |
| 1293 switch (var->location()) { | 1279 switch (var->location()) { |
| (...skipping 2422 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3716 reinterpret_cast<uint64_t>( | 3702 reinterpret_cast<uint64_t>( |
| 3717 isolate->builtins()->OnStackReplacement()->entry())); | 3703 isolate->builtins()->OnStackReplacement()->entry())); |
| 3718 return ON_STACK_REPLACEMENT; | 3704 return ON_STACK_REPLACEMENT; |
| 3719 } | 3705 } |
| 3720 | 3706 |
| 3721 | 3707 |
| 3722 } // namespace internal | 3708 } // namespace internal |
| 3723 } // namespace v8 | 3709 } // namespace v8 |
| 3724 | 3710 |
| 3725 #endif // V8_TARGET_ARCH_MIPS64 | 3711 #endif // V8_TARGET_ARCH_MIPS64 |
| OLD | NEW |