| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #include "vm/compiler.h" | 5 #include "vm/compiler.h" |
| 6 | 6 |
| 7 #include "vm/assembler.h" | 7 #include "vm/assembler.h" |
| 8 | 8 |
| 9 #include "vm/ast_printer.h" | 9 #include "vm/ast_printer.h" |
| 10 #include "vm/code_generator.h" | 10 #include "vm/code_generator.h" |
| (...skipping 426 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 437 function_fullname); | 437 function_fullname); |
| 438 const LocalVarDescriptors& var_descriptors = | 438 const LocalVarDescriptors& var_descriptors = |
| 439 LocalVarDescriptors::Handle(code.var_descriptors()); | 439 LocalVarDescriptors::Handle(code.var_descriptors()); |
| 440 intptr_t var_desc_length = | 440 intptr_t var_desc_length = |
| 441 var_descriptors.IsNull() ? 0 : var_descriptors.Length(); | 441 var_descriptors.IsNull() ? 0 : var_descriptors.Length(); |
| 442 String& var_name = String::Handle(); | 442 String& var_name = String::Handle(); |
| 443 for (intptr_t i = 0; i < var_desc_length; i++) { | 443 for (intptr_t i = 0; i < var_desc_length; i++) { |
| 444 var_name = var_descriptors.GetName(i); | 444 var_name = var_descriptors.GetName(i); |
| 445 RawLocalVarDescriptors::VarInfo var_info; | 445 RawLocalVarDescriptors::VarInfo var_info; |
| 446 var_descriptors.GetInfo(i, &var_info); | 446 var_descriptors.GetInfo(i, &var_info); |
| 447 if (var_info.kind == RawLocalVarDescriptors::kContextChain) { | 447 if (var_info.kind == RawLocalVarDescriptors::kSavedCallerContext) { |
| 448 OS::Print(" saved CTX reg offset %"Pd"\n", var_info.index); | 448 OS::Print(" saved caller's CTX reg offset %"Pd"\n", var_info.index); |
| 449 } else if (var_info.kind == RawLocalVarDescriptors::kSavedCurrentContext) { |
| 450 OS::Print(" saved current CTX reg offset %"Pd"\n", var_info.index); |
| 449 } else { | 451 } else { |
| 450 if (var_info.kind == RawLocalVarDescriptors::kContextLevel) { | 452 if (var_info.kind == RawLocalVarDescriptors::kContextLevel) { |
| 451 OS::Print(" context level %"Pd" scope %d", | 453 OS::Print(" context level %"Pd" scope %d", |
| 452 var_info.index, var_info.scope_id); | 454 var_info.index, var_info.scope_id); |
| 453 } else if (var_info.kind == RawLocalVarDescriptors::kStackVar) { | 455 } else if (var_info.kind == RawLocalVarDescriptors::kStackVar) { |
| 454 OS::Print(" stack var '%s' offset %"Pd"", | 456 OS::Print(" stack var '%s' offset %"Pd"", |
| 455 var_name.ToCString(), var_info.index); | 457 var_name.ToCString(), var_info.index); |
| 456 } else { | 458 } else { |
| 457 ASSERT(var_info.kind == RawLocalVarDescriptors::kContextVar); | 459 ASSERT(var_info.kind == RawLocalVarDescriptors::kContextVar); |
| 458 OS::Print(" context var '%s' level %d offset %"Pd"", | 460 OS::Print(" context var '%s' level %d offset %"Pd"", |
| (...skipping 235 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 694 Object::Handle(isolate->object_store()->sticky_error()); | 696 Object::Handle(isolate->object_store()->sticky_error()); |
| 695 isolate->object_store()->clear_sticky_error(); | 697 isolate->object_store()->clear_sticky_error(); |
| 696 isolate->set_long_jump_base(base); | 698 isolate->set_long_jump_base(base); |
| 697 return result.raw(); | 699 return result.raw(); |
| 698 } | 700 } |
| 699 UNREACHABLE(); | 701 UNREACHABLE(); |
| 700 return Object::null(); | 702 return Object::null(); |
| 701 } | 703 } |
| 702 | 704 |
| 703 } // namespace dart | 705 } // namespace dart |
| OLD | NEW |