| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 258 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 269 | 269 |
| 270 virtual void SetDeferredLazyDeoptimizationEnvironment(LEnvironment* env) { } | 270 virtual void SetDeferredLazyDeoptimizationEnvironment(LEnvironment* env) { } |
| 271 | 271 |
| 272 void MarkAsCall() { bit_field_ = IsCallBits::update(bit_field_, true); } | 272 void MarkAsCall() { bit_field_ = IsCallBits::update(bit_field_, true); } |
| 273 bool IsCall() const { return IsCallBits::decode(bit_field_); } | 273 bool IsCall() const { return IsCallBits::decode(bit_field_); } |
| 274 | 274 |
| 275 // Interface to the register allocator and iterators. | 275 // Interface to the register allocator and iterators. |
| 276 bool ClobbersTemps() const { return IsCall(); } | 276 bool ClobbersTemps() const { return IsCall(); } |
| 277 bool ClobbersRegisters() const { return IsCall(); } | 277 bool ClobbersRegisters() const { return IsCall(); } |
| 278 virtual bool ClobbersDoubleRegisters() const { | 278 virtual bool ClobbersDoubleRegisters() const { |
| 279 return IsCall() || | 279 return IsCall(); |
| 280 // We only have rudimentary X87Stack tracking, thus in general | |
| 281 // cannot handle phi-nodes. | |
| 282 (!CpuFeatures::IsSafeForSnapshot(SSE2) && IsControl()); | |
| 283 } | 280 } |
| 284 | 281 |
| 285 virtual bool HasResult() const = 0; | 282 virtual bool HasResult() const = 0; |
| 286 virtual LOperand* result() const = 0; | 283 virtual LOperand* result() const = 0; |
| 287 | 284 |
| 288 bool HasDoubleRegisterResult(); | 285 bool HasDoubleRegisterResult(); |
| 289 bool HasDoubleRegisterInput(); | 286 bool HasDoubleRegisterInput(); |
| 290 bool IsDoubleInput(X87Register reg, LCodeGen* cgen); | 287 bool IsDoubleInput(X87Register reg, LCodeGen* cgen); |
| 291 | 288 |
| 292 LOperand* FirstInput() { return InputAt(0); } | 289 LOperand* FirstInput() { return InputAt(0); } |
| (...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 401 virtual bool HasInterestingComment(LCodeGen* gen) const V8_OVERRIDE { | 398 virtual bool HasInterestingComment(LCodeGen* gen) const V8_OVERRIDE { |
| 402 return !IsRedundant(); | 399 return !IsRedundant(); |
| 403 } | 400 } |
| 404 | 401 |
| 405 DECLARE_CONCRETE_INSTRUCTION(InstructionGap, "gap") | 402 DECLARE_CONCRETE_INSTRUCTION(InstructionGap, "gap") |
| 406 }; | 403 }; |
| 407 | 404 |
| 408 | 405 |
| 409 class LGoto V8_FINAL : public LTemplateInstruction<0, 0, 0> { | 406 class LGoto V8_FINAL : public LTemplateInstruction<0, 0, 0> { |
| 410 public: | 407 public: |
| 411 explicit LGoto(int block_id) : block_id_(block_id) { } | 408 explicit LGoto(HBasicBlock* block) : block_(block) { } |
| 412 | 409 |
| 413 virtual bool HasInterestingComment(LCodeGen* gen) const V8_OVERRIDE; | 410 virtual bool HasInterestingComment(LCodeGen* gen) const V8_OVERRIDE; |
| 414 DECLARE_CONCRETE_INSTRUCTION(Goto, "goto") | 411 DECLARE_CONCRETE_INSTRUCTION(Goto, "goto") |
| 415 virtual void PrintDataTo(StringStream* stream) V8_OVERRIDE; | 412 virtual void PrintDataTo(StringStream* stream) V8_OVERRIDE; |
| 416 virtual bool IsControl() const V8_OVERRIDE { return true; } | 413 virtual bool IsControl() const V8_OVERRIDE { return true; } |
| 417 | 414 |
| 418 int block_id() const { return block_id_; } | 415 int block_id() const { return block_->block_id(); } |
| 416 HBasicBlock* block() const { return block_; } |
| 419 | 417 |
| 420 private: | 418 private: |
| 421 int block_id_; | 419 HBasicBlock* block_; |
| 422 }; | 420 }; |
| 423 | 421 |
| 424 | 422 |
| 425 class LLazyBailout V8_FINAL : public LTemplateInstruction<0, 0, 0> { | 423 class LLazyBailout V8_FINAL : public LTemplateInstruction<0, 0, 0> { |
| 426 public: | 424 public: |
| 427 DECLARE_CONCRETE_INSTRUCTION(LazyBailout, "lazy-bailout") | 425 DECLARE_CONCRETE_INSTRUCTION(LazyBailout, "lazy-bailout") |
| 428 }; | 426 }; |
| 429 | 427 |
| 430 | 428 |
| 431 class LDummyUse V8_FINAL : public LTemplateInstruction<1, 1, 0> { | 429 class LDummyUse V8_FINAL : public LTemplateInstruction<1, 1, 0> { |
| (...skipping 2478 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2910 | 2908 |
| 2911 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); | 2909 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); |
| 2912 }; | 2910 }; |
| 2913 | 2911 |
| 2914 #undef DECLARE_HYDROGEN_ACCESSOR | 2912 #undef DECLARE_HYDROGEN_ACCESSOR |
| 2915 #undef DECLARE_CONCRETE_INSTRUCTION | 2913 #undef DECLARE_CONCRETE_INSTRUCTION |
| 2916 | 2914 |
| 2917 } } // namespace v8::internal | 2915 } } // namespace v8::internal |
| 2918 | 2916 |
| 2919 #endif // V8_IA32_LITHIUM_IA32_H_ | 2917 #endif // V8_IA32_LITHIUM_IA32_H_ |
| OLD | NEW |