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_CRANKSHAFT_MIPS64_LITHIUM_MIPS_H_ | 5 #ifndef V8_CRANKSHAFT_MIPS64_LITHIUM_MIPS_H_ |
6 #define V8_CRANKSHAFT_MIPS64_LITHIUM_MIPS_H_ | 6 #define V8_CRANKSHAFT_MIPS64_LITHIUM_MIPS_H_ |
7 | 7 |
8 #include "src/crankshaft/hydrogen.h" | 8 #include "src/crankshaft/hydrogen.h" |
9 #include "src/crankshaft/lithium.h" | 9 #include "src/crankshaft/lithium.h" |
10 #include "src/crankshaft/lithium-allocator.h" | 10 #include "src/crankshaft/lithium-allocator.h" |
(...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
217 void set_pointer_map(LPointerMap* p) { pointer_map_.set(p); } | 217 void set_pointer_map(LPointerMap* p) { pointer_map_.set(p); } |
218 LPointerMap* pointer_map() const { return pointer_map_.get(); } | 218 LPointerMap* pointer_map() const { return pointer_map_.get(); } |
219 bool HasPointerMap() const { return pointer_map_.is_set(); } | 219 bool HasPointerMap() const { return pointer_map_.is_set(); } |
220 | 220 |
221 void set_hydrogen_value(HValue* value) { hydrogen_value_ = value; } | 221 void set_hydrogen_value(HValue* value) { hydrogen_value_ = value; } |
222 HValue* hydrogen_value() const { return hydrogen_value_; } | 222 HValue* hydrogen_value() const { return hydrogen_value_; } |
223 | 223 |
224 void MarkAsCall() { bit_field_ = IsCallBits::update(bit_field_, true); } | 224 void MarkAsCall() { bit_field_ = IsCallBits::update(bit_field_, true); } |
225 bool IsCall() const { return IsCallBits::decode(bit_field_); } | 225 bool IsCall() const { return IsCallBits::decode(bit_field_); } |
226 | 226 |
| 227 void MarkAsSyntacticTailCall() { |
| 228 bit_field_ = IsSyntacticTailCallBits::update(bit_field_, true); |
| 229 } |
| 230 bool IsSyntacticTailCall() const { |
| 231 return IsSyntacticTailCallBits::decode(bit_field_); |
| 232 } |
| 233 |
227 // Interface to the register allocator and iterators. | 234 // Interface to the register allocator and iterators. |
228 bool ClobbersTemps() const { return IsCall(); } | 235 bool ClobbersTemps() const { return IsCall(); } |
229 bool ClobbersRegisters() const { return IsCall(); } | 236 bool ClobbersRegisters() const { return IsCall(); } |
230 virtual bool ClobbersDoubleRegisters(Isolate* isolate) const { | 237 virtual bool ClobbersDoubleRegisters(Isolate* isolate) const { |
231 return IsCall(); | 238 return IsCall(); |
232 } | 239 } |
233 | 240 |
234 // Interface to the register allocator and iterators. | 241 // Interface to the register allocator and iterators. |
235 bool IsMarkedAsCall() const { return IsCall(); } | 242 bool IsMarkedAsCall() const { return IsCall(); } |
236 | 243 |
(...skipping 14 matching lines...) Expand all Loading... |
251 | 258 |
252 private: | 259 private: |
253 // Iterator interface. | 260 // Iterator interface. |
254 friend class InputIterator; | 261 friend class InputIterator; |
255 | 262 |
256 friend class TempIterator; | 263 friend class TempIterator; |
257 virtual int TempCount() = 0; | 264 virtual int TempCount() = 0; |
258 virtual LOperand* TempAt(int i) = 0; | 265 virtual LOperand* TempAt(int i) = 0; |
259 | 266 |
260 class IsCallBits: public BitField<bool, 0, 1> {}; | 267 class IsCallBits: public BitField<bool, 0, 1> {}; |
| 268 class IsSyntacticTailCallBits : public BitField<bool, IsCallBits::kNext, 1> { |
| 269 }; |
261 | 270 |
262 LEnvironment* environment_; | 271 LEnvironment* environment_; |
263 SetOncePointer<LPointerMap> pointer_map_; | 272 SetOncePointer<LPointerMap> pointer_map_; |
264 HValue* hydrogen_value_; | 273 HValue* hydrogen_value_; |
265 int bit_field_; | 274 int bit_field_; |
266 }; | 275 }; |
267 | 276 |
268 | 277 |
269 // R = number of result operands (0 or 1). | 278 // R = number of result operands (0 or 1). |
270 template<int R> | 279 template<int R> |
(...skipping 2391 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2662 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); | 2671 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); |
2663 }; | 2672 }; |
2664 | 2673 |
2665 #undef DECLARE_HYDROGEN_ACCESSOR | 2674 #undef DECLARE_HYDROGEN_ACCESSOR |
2666 #undef DECLARE_CONCRETE_INSTRUCTION | 2675 #undef DECLARE_CONCRETE_INSTRUCTION |
2667 | 2676 |
2668 } // namespace internal | 2677 } // namespace internal |
2669 } // namespace v8 | 2678 } // namespace v8 |
2670 | 2679 |
2671 #endif // V8_CRANKSHAFT_MIPS64_LITHIUM_MIPS_H_ | 2680 #endif // V8_CRANKSHAFT_MIPS64_LITHIUM_MIPS_H_ |
OLD | NEW |