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_MIPS | 7 #if V8_TARGET_ARCH_MIPS |
8 | 8 |
9 // Note on Mips implementation: | 9 // Note on Mips implementation: |
10 // | 10 // |
(...skipping 1302 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1313 // space for nested functions that don't need literals cloning. If | 1313 // space for nested functions that don't need literals cloning. If |
1314 // we're running with the --always-opt or the --prepare-always-opt | 1314 // we're running with the --always-opt or the --prepare-always-opt |
1315 // flag, we need to use the runtime function so that the new function | 1315 // flag, we need to use the runtime function so that the new function |
1316 // we are creating here gets a chance to have its code optimized and | 1316 // we are creating here gets a chance to have its code optimized and |
1317 // doesn't just get a copy of the existing unoptimized code. | 1317 // doesn't just get a copy of the existing unoptimized code. |
1318 if (!FLAG_always_opt && | 1318 if (!FLAG_always_opt && |
1319 !FLAG_prepare_always_opt && | 1319 !FLAG_prepare_always_opt && |
1320 !pretenure && | 1320 !pretenure && |
1321 scope()->is_function_scope() && | 1321 scope()->is_function_scope() && |
1322 info->num_literals() == 0) { | 1322 info->num_literals() == 0) { |
1323 FastNewClosureStub stub(isolate(), | 1323 FastNewClosureStub stub(isolate(), info->strict_mode(), info->kind()); |
1324 info->strict_mode(), | |
1325 info->is_generator()); | |
1326 __ li(a2, Operand(info)); | 1324 __ li(a2, Operand(info)); |
1327 __ CallStub(&stub); | 1325 __ CallStub(&stub); |
1328 } else { | 1326 } else { |
1329 __ li(a0, Operand(info)); | 1327 __ li(a0, Operand(info)); |
1330 __ LoadRoot(a1, pretenure ? Heap::kTrueValueRootIndex | 1328 __ LoadRoot(a1, pretenure ? Heap::kTrueValueRootIndex |
1331 : Heap::kFalseValueRootIndex); | 1329 : Heap::kFalseValueRootIndex); |
1332 __ Push(cp, a0, a1); | 1330 __ Push(cp, a0, a1); |
1333 __ CallRuntime(Runtime::kNewClosure, 3); | 1331 __ CallRuntime(Runtime::kNewClosure, 3); |
1334 } | 1332 } |
1335 context()->Plug(v0); | 1333 context()->Plug(v0); |
(...skipping 3539 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4875 Assembler::target_address_at(pc_immediate_load_address)) == | 4873 Assembler::target_address_at(pc_immediate_load_address)) == |
4876 reinterpret_cast<uint32_t>( | 4874 reinterpret_cast<uint32_t>( |
4877 isolate->builtins()->OsrAfterStackCheck()->entry())); | 4875 isolate->builtins()->OsrAfterStackCheck()->entry())); |
4878 return OSR_AFTER_STACK_CHECK; | 4876 return OSR_AFTER_STACK_CHECK; |
4879 } | 4877 } |
4880 | 4878 |
4881 | 4879 |
4882 } } // namespace v8::internal | 4880 } } // namespace v8::internal |
4883 | 4881 |
4884 #endif // V8_TARGET_ARCH_MIPS | 4882 #endif // V8_TARGET_ARCH_MIPS |
OLD | NEW |