OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef V8_HYDROGEN_INSTRUCTIONS_H_ | 5 #ifndef V8_HYDROGEN_INSTRUCTIONS_H_ |
6 #define V8_HYDROGEN_INSTRUCTIONS_H_ | 6 #define V8_HYDROGEN_INSTRUCTIONS_H_ |
7 | 7 |
8 #include "src/v8.h" | 8 #include "src/v8.h" |
9 | 9 |
10 #include "src/allocation.h" | 10 #include "src/allocation.h" |
(...skipping 6073 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6084 Representation::UInteger8()); | 6084 Representation::UInteger8()); |
6085 } | 6085 } |
6086 | 6086 |
6087 static HObjectAccess ForNameHashField() { | 6087 static HObjectAccess ForNameHashField() { |
6088 return HObjectAccess(kInobject, | 6088 return HObjectAccess(kInobject, |
6089 Name::kHashFieldOffset, | 6089 Name::kHashFieldOffset, |
6090 Representation::Integer32()); | 6090 Representation::Integer32()); |
6091 } | 6091 } |
6092 | 6092 |
6093 static HObjectAccess ForMapInstanceTypeAndBitField() { | 6093 static HObjectAccess ForMapInstanceTypeAndBitField() { |
6094 STATIC_ASSERT((Map::kInstanceTypeOffset & 1) == 0); | 6094 STATIC_ASSERT((Map::kInstanceTypeAndBitFieldOffset & 1) == 0); |
6095 STATIC_ASSERT(Map::kBitFieldOffset == Map::kInstanceTypeOffset + 1); | 6095 // Ensure the two fields share one 16-bit word, endian-independent. |
| 6096 STATIC_ASSERT((Map::kBitFieldOffset & ~1) == |
| 6097 (Map::kInstanceTypeOffset & ~1)); |
6096 return HObjectAccess(kInobject, | 6098 return HObjectAccess(kInobject, |
6097 Map::kInstanceTypeOffset, | 6099 Map::kInstanceTypeAndBitFieldOffset, |
6098 Representation::UInteger16()); | 6100 Representation::UInteger16()); |
6099 } | 6101 } |
6100 | 6102 |
6101 static HObjectAccess ForPropertyCellValue() { | 6103 static HObjectAccess ForPropertyCellValue() { |
6102 return HObjectAccess(kInobject, PropertyCell::kValueOffset); | 6104 return HObjectAccess(kInobject, PropertyCell::kValueOffset); |
6103 } | 6105 } |
6104 | 6106 |
6105 static HObjectAccess ForCellValue() { | 6107 static HObjectAccess ForCellValue() { |
6106 return HObjectAccess(kInobject, Cell::kValueOffset); | 6108 return HObjectAccess(kInobject, Cell::kValueOffset); |
6107 } | 6109 } |
(...skipping 1694 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7802 }; | 7804 }; |
7803 | 7805 |
7804 | 7806 |
7805 | 7807 |
7806 #undef DECLARE_INSTRUCTION | 7808 #undef DECLARE_INSTRUCTION |
7807 #undef DECLARE_CONCRETE_INSTRUCTION | 7809 #undef DECLARE_CONCRETE_INSTRUCTION |
7808 | 7810 |
7809 } } // namespace v8::internal | 7811 } } // namespace v8::internal |
7810 | 7812 |
7811 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ | 7813 #endif // V8_HYDROGEN_INSTRUCTIONS_H_ |
OLD | NEW |