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 555 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
566 LDivI(LOperand* left, LOperand* right, LOperand* temp) { | 566 LDivI(LOperand* left, LOperand* right, LOperand* temp) { |
567 inputs_[0] = left; | 567 inputs_[0] = left; |
568 inputs_[1] = right; | 568 inputs_[1] = right; |
569 temps_[0] = temp; | 569 temps_[0] = temp; |
570 } | 570 } |
571 | 571 |
572 LOperand* left() { return inputs_[0]; } | 572 LOperand* left() { return inputs_[0]; } |
573 LOperand* right() { return inputs_[1]; } | 573 LOperand* right() { return inputs_[1]; } |
574 LOperand* temp() { return temps_[0]; } | 574 LOperand* temp() { return temps_[0]; } |
575 | 575 |
| 576 bool is_flooring() { return hydrogen_value()->IsMathFloorOfDiv(); } |
| 577 |
576 DECLARE_CONCRETE_INSTRUCTION(DivI, "div-i") | 578 DECLARE_CONCRETE_INSTRUCTION(DivI, "div-i") |
577 DECLARE_HYDROGEN_ACCESSOR(Div) | 579 DECLARE_HYDROGEN_ACCESSOR(Div) |
578 }; | 580 }; |
579 | 581 |
580 | 582 |
581 class LMathFloorOfDiv: public LTemplateInstruction<1, 2, 1> { | 583 class LMathFloorOfDiv: public LTemplateInstruction<1, 2, 1> { |
582 public: | 584 public: |
583 LMathFloorOfDiv(LOperand* left, | 585 LMathFloorOfDiv(LOperand* left, |
584 LOperand* right, | 586 LOperand* right, |
585 LOperand* temp = NULL) { | 587 LOperand* temp = NULL) { |
(...skipping 1951 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2537 | 2539 |
2538 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); | 2540 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); |
2539 }; | 2541 }; |
2540 | 2542 |
2541 #undef DECLARE_HYDROGEN_ACCESSOR | 2543 #undef DECLARE_HYDROGEN_ACCESSOR |
2542 #undef DECLARE_CONCRETE_INSTRUCTION | 2544 #undef DECLARE_CONCRETE_INSTRUCTION |
2543 | 2545 |
2544 } } // namespace v8::int | 2546 } } // namespace v8::int |
2545 | 2547 |
2546 #endif // V8_X64_LITHIUM_X64_H_ | 2548 #endif // V8_X64_LITHIUM_X64_H_ |
OLD | NEW |