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_ARM | 7 #if V8_TARGET_ARCH_ARM |
8 | 8 |
9 #include "src/code-stubs.h" | 9 #include "src/code-stubs.h" |
10 #include "src/codegen.h" | 10 #include "src/codegen.h" |
(...skipping 1315 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1326 // space for nested functions that don't need literals cloning. If | 1326 // space for nested functions that don't need literals cloning. If |
1327 // we're running with the --always-opt or the --prepare-always-opt | 1327 // we're running with the --always-opt or the --prepare-always-opt |
1328 // flag, we need to use the runtime function so that the new function | 1328 // flag, we need to use the runtime function so that the new function |
1329 // we are creating here gets a chance to have its code optimized and | 1329 // we are creating here gets a chance to have its code optimized and |
1330 // doesn't just get a copy of the existing unoptimized code. | 1330 // doesn't just get a copy of the existing unoptimized code. |
1331 if (!FLAG_always_opt && | 1331 if (!FLAG_always_opt && |
1332 !FLAG_prepare_always_opt && | 1332 !FLAG_prepare_always_opt && |
1333 !pretenure && | 1333 !pretenure && |
1334 scope()->is_function_scope() && | 1334 scope()->is_function_scope() && |
1335 info->num_literals() == 0) { | 1335 info->num_literals() == 0) { |
1336 FastNewClosureStub stub(isolate(), | 1336 FastNewClosureStub stub(isolate(), info->strict_mode(), |
1337 info->strict_mode(), | 1337 info->is_generator(), info->is_concise_method()); |
1338 info->is_generator()); | |
1339 __ mov(r2, Operand(info)); | 1338 __ mov(r2, Operand(info)); |
1340 __ CallStub(&stub); | 1339 __ CallStub(&stub); |
1341 } else { | 1340 } else { |
1342 __ mov(r0, Operand(info)); | 1341 __ mov(r0, Operand(info)); |
1343 __ LoadRoot(r1, pretenure ? Heap::kTrueValueRootIndex | 1342 __ LoadRoot(r1, pretenure ? Heap::kTrueValueRootIndex |
1344 : Heap::kFalseValueRootIndex); | 1343 : Heap::kFalseValueRootIndex); |
1345 __ Push(cp, r0, r1); | 1344 __ Push(cp, r0, r1); |
1346 __ CallRuntime(Runtime::kNewClosure, 3); | 1345 __ CallRuntime(Runtime::kNewClosure, 3); |
1347 } | 1346 } |
1348 context()->Plug(r0); | 1347 context()->Plug(r0); |
(...skipping 3574 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4923 | 4922 |
4924 DCHECK(interrupt_address == | 4923 DCHECK(interrupt_address == |
4925 isolate->builtins()->OsrAfterStackCheck()->entry()); | 4924 isolate->builtins()->OsrAfterStackCheck()->entry()); |
4926 return OSR_AFTER_STACK_CHECK; | 4925 return OSR_AFTER_STACK_CHECK; |
4927 } | 4926 } |
4928 | 4927 |
4929 | 4928 |
4930 } } // namespace v8::internal | 4929 } } // namespace v8::internal |
4931 | 4930 |
4932 #endif // V8_TARGET_ARCH_ARM | 4931 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |