| 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 "v8.h" | 5 #include "v8.h" |
| 6 | 6 |
| 7 #include "accessors.h" | 7 #include "accessors.h" |
| 8 #include "codegen.h" | 8 #include "codegen.h" |
| 9 #include "deoptimizer.h" | 9 #include "deoptimizer.h" |
| 10 #include "disasm.h" | 10 #include "disasm.h" |
| (...skipping 304 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 315 SharedFunctionInfo* shared = function->shared(); | 315 SharedFunctionInfo* shared = function->shared(); |
| 316 function->set_code(shared->code()); | 316 function->set_code(shared->code()); |
| 317 | 317 |
| 318 if (FLAG_trace_deopt) { | 318 if (FLAG_trace_deopt) { |
| 319 CodeTracer::Scope scope(code->GetHeap()->isolate()->GetCodeTracer()); | 319 CodeTracer::Scope scope(code->GetHeap()->isolate()->GetCodeTracer()); |
| 320 PrintF(scope.file(), "[deoptimizer unlinked: "); | 320 PrintF(scope.file(), "[deoptimizer unlinked: "); |
| 321 function->PrintName(scope.file()); | 321 function->PrintName(scope.file()); |
| 322 PrintF(scope.file(), | 322 PrintF(scope.file(), |
| 323 " / %" V8PRIxPTR "]\n", reinterpret_cast<intptr_t>(function)); | 323 " / %" V8PRIxPTR "]\n", reinterpret_cast<intptr_t>(function)); |
| 324 } | 324 } |
| 325 |
| 326 if (code->marked_for_instant_optimization()) { |
| 327 Compiler::Optimize(function, "marked for instant optimization"); |
| 328 } |
| 325 } | 329 } |
| 326 }; | 330 }; |
| 327 | 331 |
| 328 // Unlink all functions that refer to marked code. | 332 // Unlink all functions that refer to marked code. |
| 329 SelectedCodeUnlinker unlinker; | 333 SelectedCodeUnlinker unlinker; |
| 330 VisitAllOptimizedFunctionsForContext(context, &unlinker); | 334 VisitAllOptimizedFunctionsForContext(context, &unlinker); |
| 331 | 335 |
| 332 Isolate* isolate = context->GetHeap()->isolate(); | 336 Isolate* isolate = context->GetHeap()->isolate(); |
| 333 #ifdef DEBUG | 337 #ifdef DEBUG |
| 334 Code* topmost_optimized_code = NULL; | 338 Code* topmost_optimized_code = NULL; |
| (...skipping 3246 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3581 } | 3585 } |
| 3582 | 3586 |
| 3583 | 3587 |
| 3584 void DeoptimizedFrameInfo::Iterate(ObjectVisitor* v) { | 3588 void DeoptimizedFrameInfo::Iterate(ObjectVisitor* v) { |
| 3585 v->VisitPointer(BitCast<Object**>(&function_)); | 3589 v->VisitPointer(BitCast<Object**>(&function_)); |
| 3586 v->VisitPointers(parameters_, parameters_ + parameters_count_); | 3590 v->VisitPointers(parameters_, parameters_ + parameters_count_); |
| 3587 v->VisitPointers(expression_stack_, expression_stack_ + expression_count_); | 3591 v->VisitPointers(expression_stack_, expression_stack_ + expression_count_); |
| 3588 } | 3592 } |
| 3589 | 3593 |
| 3590 } } // namespace v8::internal | 3594 } } // namespace v8::internal |
| OLD | NEW |