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

Side by Side Diff: vm/intermediate_language.cc

Issue 11648006: Create read only handles for empty_array and sentinel objects (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: Created 8 years 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/handles.h ('k') | vm/object.h » ('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/intermediate_language.h" 5 #include "vm/intermediate_language.h"
6 6
7 #include "vm/bit_vector.h" 7 #include "vm/bit_vector.h"
8 #include "vm/dart_entry.h" 8 #include "vm/dart_entry.h"
9 #include "vm/flow_graph_allocator.h" 9 #include "vm/flow_graph_allocator.h"
10 #include "vm/flow_graph_builder.h" 10 #include "vm/flow_graph_builder.h"
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 (ResultCid() == kDynamicCid) || 142 (ResultCid() == kDynamicCid) ||
143 (other_load->ResultCid() == kDynamicCid)))); 143 (other_load->ResultCid() == kDynamicCid))));
144 return offset_in_bytes() == other_load->offset_in_bytes(); 144 return offset_in_bytes() == other_load->offset_in_bytes();
145 } 145 }
146 146
147 147
148 bool LoadStaticFieldInstr::AttributesEqual(Instruction* other) const { 148 bool LoadStaticFieldInstr::AttributesEqual(Instruction* other) const {
149 LoadStaticFieldInstr* other_load = other->AsLoadStaticField(); 149 LoadStaticFieldInstr* other_load = other->AsLoadStaticField();
150 ASSERT(other_load != NULL); 150 ASSERT(other_load != NULL);
151 // Assert that the field is initialized. 151 // Assert that the field is initialized.
152 ASSERT(field().value() != Object::sentinel()); 152 ASSERT(field().value() != Object::sentinel().raw());
153 ASSERT(field().value() != Object::transition_sentinel()); 153 ASSERT(field().value() != Object::transition_sentinel().raw());
154 return field().raw() == other_load->field().raw(); 154 return field().raw() == other_load->field().raw();
155 } 155 }
156 156
157 157
158 bool StringCharCodeAtInstr::AttributesEqual(Instruction* other) const { 158 bool StringCharCodeAtInstr::AttributesEqual(Instruction* other) const {
159 StringCharCodeAtInstr* other_load = other->AsStringCharCodeAt(); 159 StringCharCodeAtInstr* other_load = other->AsStringCharCodeAt();
160 ASSERT(other_load != NULL); 160 ASSERT(other_load != NULL);
161 return class_id() == other_load->class_id(); 161 return class_id() == other_load->class_id();
162 } 162 }
163 163
(...skipping 2608 matching lines...) Expand 10 before | Expand all | Expand 10 after
2772 default: 2772 default:
2773 UNREACHABLE(); 2773 UNREACHABLE();
2774 return -1; 2774 return -1;
2775 } 2775 }
2776 } 2776 }
2777 2777
2778 2778
2779 #undef __ 2779 #undef __
2780 2780
2781 } // namespace dart 2781 } // namespace dart
OLDNEW
« no previous file with comments | « vm/handles.h ('k') | vm/object.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698