OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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 #include "src/arm64/lithium-codegen-arm64.h" | 7 #include "src/arm64/lithium-codegen-arm64.h" |
8 #include "src/arm64/lithium-gap-resolver-arm64.h" | 8 #include "src/arm64/lithium-gap-resolver-arm64.h" |
9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" |
10 #include "src/code-factory.h" | 10 #include "src/code-factory.h" |
(...skipping 979 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
990 data->SetArgumentsStackHeight(i, | 990 data->SetArgumentsStackHeight(i, |
991 Smi::FromInt(env->arguments_stack_height())); | 991 Smi::FromInt(env->arguments_stack_height())); |
992 data->SetPc(i, Smi::FromInt(env->pc_offset())); | 992 data->SetPc(i, Smi::FromInt(env->pc_offset())); |
993 } | 993 } |
994 | 994 |
995 code->set_deoptimization_data(*data); | 995 code->set_deoptimization_data(*data); |
996 } | 996 } |
997 | 997 |
998 | 998 |
999 void LCodeGen::PopulateDeoptimizationLiteralsWithInlinedFunctions() { | 999 void LCodeGen::PopulateDeoptimizationLiteralsWithInlinedFunctions() { |
1000 DCHECK(deoptimization_literals_.length() == 0); | 1000 DCHECK_EQ(0, deoptimization_literals_.length()); |
1001 | 1001 for (auto function : chunk()->inlined_functions()) { |
1002 const ZoneList<Handle<JSFunction> >* inlined_closures = | 1002 DefineDeoptimizationLiteral(function); |
1003 chunk()->inlined_closures(); | |
1004 | |
1005 for (int i = 0, length = inlined_closures->length(); i < length; i++) { | |
1006 DefineDeoptimizationLiteral(inlined_closures->at(i)); | |
1007 } | 1003 } |
1008 | |
1009 inlined_function_count_ = deoptimization_literals_.length(); | 1004 inlined_function_count_ = deoptimization_literals_.length(); |
1010 } | 1005 } |
1011 | 1006 |
1012 | 1007 |
1013 void LCodeGen::DeoptimizeBranch( | 1008 void LCodeGen::DeoptimizeBranch( |
1014 LInstruction* instr, Deoptimizer::DeoptReason deopt_reason, | 1009 LInstruction* instr, Deoptimizer::DeoptReason deopt_reason, |
1015 BranchType branch_type, Register reg, int bit, | 1010 BranchType branch_type, Register reg, int bit, |
1016 Deoptimizer::BailoutType* override_bailout_type) { | 1011 Deoptimizer::BailoutType* override_bailout_type) { |
1017 LEnvironment* environment = instr->environment(); | 1012 LEnvironment* environment = instr->environment(); |
1018 RegisterEnvironmentForDeoptimization(environment, Safepoint::kNoLazyDeopt); | 1013 RegisterEnvironmentForDeoptimization(environment, Safepoint::kNoLazyDeopt); |
(...skipping 5085 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6104 Handle<ScopeInfo> scope_info = instr->scope_info(); | 6099 Handle<ScopeInfo> scope_info = instr->scope_info(); |
6105 __ Push(scope_info); | 6100 __ Push(scope_info); |
6106 __ Push(ToRegister(instr->function())); | 6101 __ Push(ToRegister(instr->function())); |
6107 CallRuntime(Runtime::kPushBlockContext, 2, instr); | 6102 CallRuntime(Runtime::kPushBlockContext, 2, instr); |
6108 RecordSafepoint(Safepoint::kNoLazyDeopt); | 6103 RecordSafepoint(Safepoint::kNoLazyDeopt); |
6109 } | 6104 } |
6110 | 6105 |
6111 | 6106 |
6112 | 6107 |
6113 } } // namespace v8::internal | 6108 } } // namespace v8::internal |
OLD | NEW |