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/deoptimizer.h" | 5 #include "src/deoptimizer.h" |
6 | 6 |
7 #include <memory> | 7 #include <memory> |
8 | 8 |
9 #include "src/accessors.h" | 9 #include "src/accessors.h" |
10 #include "src/ast/prettyprinter.h" | 10 #include "src/ast/prettyprinter.h" |
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
250 if (FLAG_trace_deopt) { | 250 if (FLAG_trace_deopt) { |
251 CodeTracer::Scope scope(isolate->GetCodeTracer()); | 251 CodeTracer::Scope scope(isolate->GetCodeTracer()); |
252 PrintF(scope.file(), "[deoptimizer found activation of function: "); | 252 PrintF(scope.file(), "[deoptimizer found activation of function: "); |
253 function->PrintName(scope.file()); | 253 function->PrintName(scope.file()); |
254 PrintF(scope.file(), | 254 PrintF(scope.file(), |
255 " / %" V8PRIxPTR "]\n", reinterpret_cast<intptr_t>(function)); | 255 " / %" V8PRIxPTR "]\n", reinterpret_cast<intptr_t>(function)); |
256 } | 256 } |
257 SafepointEntry safepoint = code->GetSafepointEntry(it.frame()->pc()); | 257 SafepointEntry safepoint = code->GetSafepointEntry(it.frame()->pc()); |
258 int deopt_index = safepoint.deoptimization_index(); | 258 int deopt_index = safepoint.deoptimization_index(); |
259 // Turbofan deopt is checked when we are patching addresses on stack. | 259 // Turbofan deopt is checked when we are patching addresses on stack. |
260 bool turbofanned = code->is_turbofanned() && | 260 bool turbofanned = |
261 function->shared()->asm_function() && | 261 code->is_turbofanned() && function->shared()->asm_function(); |
262 !FLAG_turbo_asm_deoptimization; | |
263 bool safe_to_deopt = | 262 bool safe_to_deopt = |
264 deopt_index != Safepoint::kNoDeoptimizationIndex || turbofanned; | 263 deopt_index != Safepoint::kNoDeoptimizationIndex || turbofanned; |
265 bool builtin = code->kind() == Code::BUILTIN; | 264 bool builtin = code->kind() == Code::BUILTIN; |
266 CHECK(topmost_optimized_code == NULL || safe_to_deopt || turbofanned || | 265 CHECK(topmost_optimized_code == NULL || safe_to_deopt || turbofanned || |
267 builtin); | 266 builtin); |
268 if (topmost_optimized_code == NULL) { | 267 if (topmost_optimized_code == NULL) { |
269 topmost_optimized_code = code; | 268 topmost_optimized_code = code; |
270 safe_to_deopt_topmost_optimized_code = safe_to_deopt; | 269 safe_to_deopt_topmost_optimized_code = safe_to_deopt; |
271 } | 270 } |
272 } | 271 } |
(...skipping 3736 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4009 CHECK(value_info->IsMaterializedObject()); | 4008 CHECK(value_info->IsMaterializedObject()); |
4010 | 4009 |
4011 value_info->value_ = | 4010 value_info->value_ = |
4012 Handle<Object>(previously_materialized_objects->get(i), isolate_); | 4011 Handle<Object>(previously_materialized_objects->get(i), isolate_); |
4013 } | 4012 } |
4014 } | 4013 } |
4015 } | 4014 } |
4016 | 4015 |
4017 } // namespace internal | 4016 } // namespace internal |
4018 } // namespace v8 | 4017 } // namespace v8 |
OLD | NEW |