| 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 289 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 300 if (topmost_optimized_code == NULL) { | 300 if (topmost_optimized_code == NULL) { |
| 301 topmost_optimized_code = code; | 301 topmost_optimized_code = code; |
| 302 safe_to_deopt_topmost_optimized_code = safe_to_deopt; | 302 safe_to_deopt_topmost_optimized_code = safe_to_deopt; |
| 303 } | 303 } |
| 304 } | 304 } |
| 305 } | 305 } |
| 306 #endif | 306 #endif |
| 307 | 307 |
| 308 // Move marked code from the optimized code list to the deoptimized | 308 // Move marked code from the optimized code list to the deoptimized |
| 309 // code list, collecting them into a ZoneList. | 309 // code list, collecting them into a ZoneList. |
| 310 Zone zone; | 310 Zone zone(isolate->allocator()); |
| 311 ZoneList<Code*> codes(10, &zone); | 311 ZoneList<Code*> codes(10, &zone); |
| 312 | 312 |
| 313 // Walk over all optimized code objects in this native context. | 313 // Walk over all optimized code objects in this native context. |
| 314 Code* prev = NULL; | 314 Code* prev = NULL; |
| 315 Object* element = context->OptimizedCodeListHead(); | 315 Object* element = context->OptimizedCodeListHead(); |
| 316 while (!element->IsUndefined()) { | 316 while (!element->IsUndefined()) { |
| 317 Code* code = Code::cast(element); | 317 Code* code = Code::cast(element); |
| 318 CHECK_EQ(code->kind(), Code::OPTIMIZED_FUNCTION); | 318 CHECK_EQ(code->kind(), Code::OPTIMIZED_FUNCTION); |
| 319 Object* next = code->next_code_link(); | 319 Object* next = code->next_code_link(); |
| 320 | 320 |
| (...skipping 3490 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3811 CHECK(value_info->IsMaterializedObject()); | 3811 CHECK(value_info->IsMaterializedObject()); |
| 3812 | 3812 |
| 3813 value_info->value_ = | 3813 value_info->value_ = |
| 3814 Handle<Object>(previously_materialized_objects->get(i), isolate_); | 3814 Handle<Object>(previously_materialized_objects->get(i), isolate_); |
| 3815 } | 3815 } |
| 3816 } | 3816 } |
| 3817 } | 3817 } |
| 3818 | 3818 |
| 3819 } // namespace internal | 3819 } // namespace internal |
| 3820 } // namespace v8 | 3820 } // namespace v8 |
| OLD | NEW |