| OLD | NEW | 
|---|
| 1 // Copyright (c) 2011, the Dart project authors.  Please see the AUTHORS file | 1 // Copyright (c) 2011, 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/disassembler.h" | 5 #include "vm/disassembler.h" | 
| 6 | 6 | 
| 7 #include "vm/assembler.h" | 7 #include "vm/assembler.h" | 
| 8 #include "vm/deopt_instructions.h" | 8 #include "vm/deopt_instructions.h" | 
| 9 #include "vm/globals.h" | 9 #include "vm/globals.h" | 
| 10 #include "vm/il_printer.h" | 10 #include "vm/il_printer.h" | 
| (...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 198   THR_Print("Pointer offsets for function: {\n"); | 198   THR_Print("Pointer offsets for function: {\n"); | 
| 199   // Pointer offsets are stored in descending order. | 199   // Pointer offsets are stored in descending order. | 
| 200   Object& obj = Object::Handle(); | 200   Object& obj = Object::Handle(); | 
| 201   for (intptr_t i = code.pointer_offsets_length() - 1; i >= 0; i--) { | 201   for (intptr_t i = code.pointer_offsets_length() - 1; i >= 0; i--) { | 
| 202     const uword addr = code.GetPointerOffsetAt(i) + code.EntryPoint(); | 202     const uword addr = code.GetPointerOffsetAt(i) + code.EntryPoint(); | 
| 203     obj = *reinterpret_cast<RawObject**>(addr); | 203     obj = *reinterpret_cast<RawObject**>(addr); | 
| 204     THR_Print(" %d : %#" Px " '%s'\n", | 204     THR_Print(" %d : %#" Px " '%s'\n", | 
| 205               code.GetPointerOffsetAt(i), addr, obj.ToCString()); | 205               code.GetPointerOffsetAt(i), addr, obj.ToCString()); | 
| 206   } | 206   } | 
| 207   THR_Print("}\n"); | 207   THR_Print("}\n"); | 
| 208 |  | 
| 209   ASSERT(ObjectPool::Handle(code.GetObjectPool()).Length() == 0); |  | 
| 210 #else | 208 #else | 
| 211   ASSERT(code.pointer_offsets_length() == 0); | 209   ASSERT(code.pointer_offsets_length() == 0); | 
|  | 210 #endif | 
| 212 | 211 | 
| 213   const ObjectPool& object_pool = ObjectPool::Handle(code.GetObjectPool()); | 212   const ObjectPool& object_pool = ObjectPool::Handle(code.GetObjectPool()); | 
| 214   object_pool.DebugPrint(); | 213   object_pool.DebugPrint(); | 
| 215 #endif |  | 
| 216 | 214 | 
| 217   THR_Print("PC Descriptors for function '%s' {\n", function_fullname); | 215   THR_Print("PC Descriptors for function '%s' {\n", function_fullname); | 
| 218   PcDescriptors::PrintHeaderString(); | 216   PcDescriptors::PrintHeaderString(); | 
| 219   const PcDescriptors& descriptors = | 217   const PcDescriptors& descriptors = | 
| 220       PcDescriptors::Handle(code.pc_descriptors()); | 218       PcDescriptors::Handle(code.pc_descriptors()); | 
| 221   THR_Print("%s}\n", descriptors.ToCString()); | 219   THR_Print("%s}\n", descriptors.ToCString()); | 
| 222 | 220 | 
| 223   uword start = Instructions::Handle(code.instructions()).EntryPoint(); | 221   uword start = Instructions::Handle(code.instructions()).EntryPoint(); | 
| 224   const Array& deopt_table = Array::Handle(code.deopt_info_array()); | 222   const Array& deopt_table = Array::Handle(code.deopt_info_array()); | 
| 225   intptr_t deopt_table_length = DeoptTable::GetLength(deopt_table); | 223   intptr_t deopt_table_length = DeoptTable::GetLength(deopt_table); | 
| (...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 327     THR_Print("}\n"); | 325     THR_Print("}\n"); | 
| 328   } | 326   } | 
| 329   if (optimized && FLAG_trace_inlining_intervals) { | 327   if (optimized && FLAG_trace_inlining_intervals) { | 
| 330     code.DumpInlinedIntervals(); | 328     code.DumpInlinedIntervals(); | 
| 331   } | 329   } | 
| 332 } | 330 } | 
| 333 | 331 | 
| 334 #endif  // !PRODUCT | 332 #endif  // !PRODUCT | 
| 335 | 333 | 
| 336 }  // namespace dart | 334 }  // namespace dart | 
| OLD | NEW | 
|---|