OLD | NEW |
1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 ASSERT(index < length_); | 68 ASSERT(index < length_); |
69 return &Memory::uint8_at(entries_ + (index * entry_size_)); | 69 return &Memory::uint8_at(entries_ + (index * entry_size_)); |
70 } | 70 } |
71 | 71 |
72 // Reserve 13 bits for the gap code size. On ARM a constant pool can be | 72 // Reserve 13 bits for the gap code size. On ARM a constant pool can be |
73 // emitted when generating the gap code. The size of the const pool is less | 73 // emitted when generating the gap code. The size of the const pool is less |
74 // than what can be represented in 12 bits, so 13 bits gives room for having | 74 // than what can be represented in 12 bits, so 13 bits gives room for having |
75 // instructions before potentially emitting a constant pool. | 75 // instructions before potentially emitting a constant pool. |
76 static const int kGapCodeSizeBits = 13; | 76 static const int kGapCodeSizeBits = 13; |
77 static const int kDeoptIndexBits = 32 - kGapCodeSizeBits; | 77 static const int kDeoptIndexBits = 32 - kGapCodeSizeBits; |
78 class GapCodeSizeField: public BitField<unsigned, 0, kGapCodeSizeBits> {}; | 78 class GapCodeSizeField: public BitField<unsigned, 0, kGapCodeSizeBits> {} |
79 class DeoptimizationIndexField: | 79 class DeoptimizationIndexField: |
80 public BitField<int, kGapCodeSizeBits, kDeoptIndexBits> {}; | 80 public BitField<int, kGapCodeSizeBits, kDeoptIndexBits> {} |
81 | 81 |
82 static bool HasRegisters(uint8_t* entry); | 82 static bool HasRegisters(uint8_t* entry); |
83 static bool HasRegisterAt(uint8_t* entry, int reg_index); | 83 static bool HasRegisterAt(uint8_t* entry, int reg_index); |
84 | 84 |
85 void PrintEntry(unsigned index) const; | 85 void PrintEntry(unsigned index) const; |
86 | 86 |
87 private: | 87 private: |
88 static const uint8_t kNoRegisters = 0xFF; | 88 static const uint8_t kNoRegisters = 0xFF; |
89 | 89 |
90 static const int kLengthOffset = 0; | 90 static const int kLengthOffset = 0; |
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
188 | 188 |
189 bool emitted_; | 189 bool emitted_; |
190 unsigned offset_; | 190 unsigned offset_; |
191 | 191 |
192 DISALLOW_COPY_AND_ASSIGN(SafepointTableBuilder); | 192 DISALLOW_COPY_AND_ASSIGN(SafepointTableBuilder); |
193 }; | 193 }; |
194 | 194 |
195 } } // namespace v8::internal | 195 } } // namespace v8::internal |
196 | 196 |
197 #endif // V8_SAFEPOINT_TABLE_H_ | 197 #endif // V8_SAFEPOINT_TABLE_H_ |
OLD | NEW |