| 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 "src/accessors.h" | 7 #include "src/accessors.h" |
| 8 #include "src/ast/prettyprinter.h" | 8 #include "src/ast/prettyprinter.h" |
| 9 #include "src/codegen.h" | 9 #include "src/codegen.h" |
| 10 #include "src/disasm.h" | 10 #include "src/disasm.h" |
| (...skipping 550 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 561 ? static_cast<Code*>(isolate_->FindCodeObject(from_)) | 561 ? static_cast<Code*>(isolate_->FindCodeObject(from_)) |
| 562 : compiled_code; | 562 : compiled_code; |
| 563 } | 563 } |
| 564 } | 564 } |
| 565 FATAL("Could not find code for optimized function"); | 565 FATAL("Could not find code for optimized function"); |
| 566 return NULL; | 566 return NULL; |
| 567 } | 567 } |
| 568 | 568 |
| 569 | 569 |
| 570 void Deoptimizer::PrintFunctionName() { | 570 void Deoptimizer::PrintFunctionName() { |
| 571 if (function_->IsJSFunction()) { | 571 if (function_ != nullptr && function_->IsJSFunction()) { |
| 572 function_->ShortPrint(trace_scope_->file()); | 572 function_->ShortPrint(trace_scope_->file()); |
| 573 } else { | 573 } else { |
| 574 PrintF(trace_scope_->file(), | 574 PrintF(trace_scope_->file(), |
| 575 "%s", Code::Kind2String(compiled_code_->kind())); | 575 "%s", Code::Kind2String(compiled_code_->kind())); |
| 576 } | 576 } |
| 577 } | 577 } |
| 578 | 578 |
| 579 | 579 |
| 580 Deoptimizer::~Deoptimizer() { | 580 Deoptimizer::~Deoptimizer() { |
| 581 DCHECK(input_ == NULL && output_ == NULL); | 581 DCHECK(input_ == NULL && output_ == NULL); |
| (...skipping 3435 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4017 CHECK(value_info->IsMaterializedObject()); | 4017 CHECK(value_info->IsMaterializedObject()); |
| 4018 | 4018 |
| 4019 value_info->value_ = | 4019 value_info->value_ = |
| 4020 Handle<Object>(previously_materialized_objects->get(i), isolate_); | 4020 Handle<Object>(previously_materialized_objects->get(i), isolate_); |
| 4021 } | 4021 } |
| 4022 } | 4022 } |
| 4023 } | 4023 } |
| 4024 | 4024 |
| 4025 } // namespace internal | 4025 } // namespace internal |
| 4026 } // namespace v8 | 4026 } // namespace v8 |
| OLD | NEW |