| 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 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 116 // code generation attempt succeeded. | 116 // code generation attempt succeeded. |
| 117 bool GenerateCode(); | 117 bool GenerateCode(); |
| 118 | 118 |
| 119 // Finish the code by setting stack height, safepoint, and bailout | 119 // Finish the code by setting stack height, safepoint, and bailout |
| 120 // information on it. | 120 // information on it. |
| 121 void FinishCode(Handle<Code> code); | 121 void FinishCode(Handle<Code> code); |
| 122 | 122 |
| 123 // Deferred code support. | 123 // Deferred code support. |
| 124 void DoDeferredNumberTagD(LNumberTagD* instr); | 124 void DoDeferredNumberTagD(LNumberTagD* instr); |
| 125 void DoDeferredNumberTagU(LNumberTagU* instr); | 125 void DoDeferredNumberTagU(LNumberTagU* instr); |
| 126 void DoDeferredTaggedToI(LTaggedToI* instr); | 126 void DoDeferredTaggedToI(LTaggedToI* instr, Label* done); |
| 127 void DoDeferredMathAbsTaggedHeapNumber(LMathAbs* instr); | 127 void DoDeferredMathAbsTaggedHeapNumber(LMathAbs* instr); |
| 128 void DoDeferredStackCheck(LStackCheck* instr); | 128 void DoDeferredStackCheck(LStackCheck* instr); |
| 129 void DoDeferredRandom(LRandom* instr); | 129 void DoDeferredRandom(LRandom* instr); |
| 130 void DoDeferredStringCharCodeAt(LStringCharCodeAt* instr); | 130 void DoDeferredStringCharCodeAt(LStringCharCodeAt* instr); |
| 131 void DoDeferredStringCharFromCode(LStringCharFromCode* instr); | 131 void DoDeferredStringCharFromCode(LStringCharFromCode* instr); |
| 132 void DoDeferredAllocate(LAllocate* instr); | 132 void DoDeferredAllocate(LAllocate* instr); |
| 133 void DoDeferredInstanceOfKnownGlobal(LInstanceOfKnownGlobal* instr, | 133 void DoDeferredInstanceOfKnownGlobal(LInstanceOfKnownGlobal* instr, |
| 134 Label* map_check); | 134 Label* map_check); |
| 135 void DoDeferredInstanceMigration(LCheckMaps* instr, Register object); | 135 void DoDeferredInstanceMigration(LCheckMaps* instr, Register object); |
| 136 | 136 |
| (...skipping 286 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 423 codegen->AddDeferredCode(this); | 423 codegen->AddDeferredCode(this); |
| 424 } | 424 } |
| 425 | 425 |
| 426 virtual ~LDeferredCode() {} | 426 virtual ~LDeferredCode() {} |
| 427 virtual void Generate() = 0; | 427 virtual void Generate() = 0; |
| 428 virtual LInstruction* instr() = 0; | 428 virtual LInstruction* instr() = 0; |
| 429 | 429 |
| 430 void SetExit(Label* exit) { external_exit_ = exit; } | 430 void SetExit(Label* exit) { external_exit_ = exit; } |
| 431 Label* entry() { return &entry_; } | 431 Label* entry() { return &entry_; } |
| 432 Label* exit() { return external_exit_ != NULL ? external_exit_ : &exit_; } | 432 Label* exit() { return external_exit_ != NULL ? external_exit_ : &exit_; } |
| 433 Label* done() { return codegen_->NeedsDeferredFrame() ? &done_ : exit(); } |
| 433 int instruction_index() const { return instruction_index_; } | 434 int instruction_index() const { return instruction_index_; } |
| 434 | 435 |
| 435 protected: | 436 protected: |
| 436 LCodeGen* codegen() const { return codegen_; } | 437 LCodeGen* codegen() const { return codegen_; } |
| 437 MacroAssembler* masm() const { return codegen_->masm(); } | 438 MacroAssembler* masm() const { return codegen_->masm(); } |
| 438 | 439 |
| 439 private: | 440 private: |
| 440 LCodeGen* codegen_; | 441 LCodeGen* codegen_; |
| 441 Label entry_; | 442 Label entry_; |
| 442 Label exit_; | 443 Label exit_; |
| 444 Label done_; |
| 443 Label* external_exit_; | 445 Label* external_exit_; |
| 444 int instruction_index_; | 446 int instruction_index_; |
| 445 }; | 447 }; |
| 446 | 448 |
| 447 } } // namespace v8::internal | 449 } } // namespace v8::internal |
| 448 | 450 |
| 449 #endif // V8_X64_LITHIUM_CODEGEN_X64_H_ | 451 #endif // V8_X64_LITHIUM_CODEGEN_X64_H_ |
| OLD | NEW |