Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(281)

Side by Side Diff: vm/code_descriptors.cc

Issue 10827249: - Register canonical names for internal VM classes and get rid of the method GetSingletonClassName (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « vm/class_finalizer_test.cc ('k') | vm/code_generator.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/code_descriptors.h" 5 #include "vm/code_descriptors.h"
6 6
7 namespace dart { 7 namespace dart {
8 8
9 void DescriptorList::AddDescriptor(PcDescriptors::Kind kind, 9 void DescriptorList::AddDescriptor(PcDescriptors::Kind kind,
10 intptr_t pc_offset, 10 intptr_t pc_offset,
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
73 } 73 }
74 return true; 74 return true;
75 } 75 }
76 76
77 77
78 RawArray* StackmapTableBuilder::FinalizeStackmaps(const Code& code) { 78 RawArray* StackmapTableBuilder::FinalizeStackmaps(const Code& code) {
79 ASSERT(Verify()); 79 ASSERT(Verify());
80 intptr_t num_entries = Length(); 80 intptr_t num_entries = Length();
81 uword entry_point = code.EntryPoint(); 81 uword entry_point = code.EntryPoint();
82 if (num_entries == 0) { 82 if (num_entries == 0) {
83 return Array::Empty(); 83 return Object::empty_array();
84 } 84 }
85 for (intptr_t i = 0; i < num_entries; i++) { 85 for (intptr_t i = 0; i < num_entries; i++) {
86 stack_map_ = Map(i); 86 stack_map_ = Map(i);
87 stack_map_.SetPC(entry_point + stack_map_.PC()); 87 stack_map_.SetPC(entry_point + stack_map_.PC());
88 stack_map_.SetCode(code); 88 stack_map_.SetCode(code);
89 } 89 }
90 return Array::MakeArray(list_); 90 return Array::MakeArray(list_);
91 } 91 }
92 92
93 93
94 RawStackmap* StackmapTableBuilder::Map(int index) const { 94 RawStackmap* StackmapTableBuilder::Map(int index) const {
95 Stackmap& map = Stackmap::Handle(); 95 Stackmap& map = Stackmap::Handle();
96 map ^= list_.At(index); 96 map ^= list_.At(index);
97 return map.raw(); 97 return map.raw();
98 } 98 }
99 99
100 } // namespace dart 100 } // namespace dart
OLDNEW
« no previous file with comments | « vm/class_finalizer_test.cc ('k') | vm/code_generator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698