| 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 #ifndef VM_LOCATIONS_H_ | 5 #ifndef VM_LOCATIONS_H_ |
| 6 #define VM_LOCATIONS_H_ | 6 #define VM_LOCATIONS_H_ |
| 7 | 7 |
| 8 #include "vm/allocation.h" | 8 #include "vm/allocation.h" |
| 9 #include "vm/assembler.h" | 9 #include "vm/assembler.h" |
| 10 #include "vm/bitfield.h" | 10 #include "vm/bitfield.h" |
| (...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 164 } | 164 } |
| 165 | 165 |
| 166 intptr_t stack_index() const { | 166 intptr_t stack_index() const { |
| 167 ASSERT(IsStackSlot()); | 167 ASSERT(IsStackSlot()); |
| 168 // Decode stack index manually to preserve sign. | 168 // Decode stack index manually to preserve sign. |
| 169 return payload() - kStackIndexBias; | 169 return payload() - kStackIndexBias; |
| 170 } | 170 } |
| 171 | 171 |
| 172 const char* Name() const; | 172 const char* Name() const; |
| 173 void PrintTo(BufferFormatter* f) const; | 173 void PrintTo(BufferFormatter* f) const; |
| 174 void Print() const; |
| 174 | 175 |
| 175 // Compare two locations. | 176 // Compare two locations. |
| 176 bool Equals(Location other) const { | 177 bool Equals(Location other) const { |
| 177 return value_ == other.value_; | 178 return value_ == other.value_; |
| 178 } | 179 } |
| 179 | 180 |
| 180 private: | 181 private: |
| 181 explicit Location(uword value) : value_(value) { } | 182 explicit Location(uword value) : value_(value) { } |
| 182 | 183 |
| 183 Location(Kind kind, uword payload) | 184 Location(Kind kind, uword payload) |
| (...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 282 GrowableArray<Location> temp_locations_; | 283 GrowableArray<Location> temp_locations_; |
| 283 Location output_location_; | 284 Location output_location_; |
| 284 | 285 |
| 285 const bool is_call_; | 286 const bool is_call_; |
| 286 }; | 287 }; |
| 287 | 288 |
| 288 | 289 |
| 289 } // namespace dart | 290 } // namespace dart |
| 290 | 291 |
| 291 #endif // VM_LOCATIONS_H_ | 292 #endif // VM_LOCATIONS_H_ |
| OLD | NEW |