| 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_MIPS | 5 #if V8_TARGET_ARCH_MIPS |
| 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 1479 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1490 Label materialized; | 1490 Label materialized; |
| 1491 // Registers will be used as follows: | 1491 // Registers will be used as follows: |
| 1492 // t1 = materialized value (RegExp literal) | 1492 // t1 = materialized value (RegExp literal) |
| 1493 // t0 = JS function, literals array | 1493 // t0 = JS function, literals array |
| 1494 // a3 = literal index | 1494 // a3 = literal index |
| 1495 // a2 = RegExp pattern | 1495 // a2 = RegExp pattern |
| 1496 // a1 = RegExp flags | 1496 // a1 = RegExp flags |
| 1497 // a0 = RegExp literal clone | 1497 // a0 = RegExp literal clone |
| 1498 __ lw(a0, MemOperand(fp, JavaScriptFrameConstants::kFunctionOffset)); | 1498 __ lw(a0, MemOperand(fp, JavaScriptFrameConstants::kFunctionOffset)); |
| 1499 __ lw(t0, FieldMemOperand(a0, JSFunction::kLiteralsOffset)); | 1499 __ lw(t0, FieldMemOperand(a0, JSFunction::kLiteralsOffset)); |
| 1500 int literal_offset = | 1500 int literal_offset = LiteralsArray::OffsetOfLiteralAt(expr->literal_index()); |
| 1501 FixedArray::kHeaderSize + expr->literal_index() * kPointerSize; | |
| 1502 __ lw(t1, FieldMemOperand(t0, literal_offset)); | 1501 __ lw(t1, FieldMemOperand(t0, literal_offset)); |
| 1503 __ LoadRoot(at, Heap::kUndefinedValueRootIndex); | 1502 __ LoadRoot(at, Heap::kUndefinedValueRootIndex); |
| 1504 __ Branch(&materialized, ne, t1, Operand(at)); | 1503 __ Branch(&materialized, ne, t1, Operand(at)); |
| 1505 | 1504 |
| 1506 // Create regexp literal using runtime function. | 1505 // Create regexp literal using runtime function. |
| 1507 // Result will be in v0. | 1506 // Result will be in v0. |
| 1508 __ li(a3, Operand(Smi::FromInt(expr->literal_index()))); | 1507 __ li(a3, Operand(Smi::FromInt(expr->literal_index()))); |
| 1509 __ li(a2, Operand(expr->pattern())); | 1508 __ li(a2, Operand(expr->pattern())); |
| 1510 __ li(a1, Operand(expr->flags())); | 1509 __ li(a1, Operand(expr->flags())); |
| 1511 __ Push(t0, a3, a2, a1); | 1510 __ Push(t0, a3, a2, a1); |
| (...skipping 3728 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5240 reinterpret_cast<uint32_t>( | 5239 reinterpret_cast<uint32_t>( |
| 5241 isolate->builtins()->OsrAfterStackCheck()->entry())); | 5240 isolate->builtins()->OsrAfterStackCheck()->entry())); |
| 5242 return OSR_AFTER_STACK_CHECK; | 5241 return OSR_AFTER_STACK_CHECK; |
| 5243 } | 5242 } |
| 5244 | 5243 |
| 5245 | 5244 |
| 5246 } // namespace internal | 5245 } // namespace internal |
| 5247 } // namespace v8 | 5246 } // namespace v8 |
| 5248 | 5247 |
| 5249 #endif // V8_TARGET_ARCH_MIPS | 5248 #endif // V8_TARGET_ARCH_MIPS |
| OLD | NEW |