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 547 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
558 public: | 558 public: |
559 LDivI(LOperand* left, LOperand* right, LOperand* temp) { | 559 LDivI(LOperand* left, LOperand* right, LOperand* temp) { |
560 inputs_[0] = left; | 560 inputs_[0] = left; |
561 inputs_[1] = right; | 561 inputs_[1] = right; |
562 temps_[0] = temp; | 562 temps_[0] = temp; |
563 } | 563 } |
564 | 564 |
565 LOperand* left() { return inputs_[0]; } | 565 LOperand* left() { return inputs_[0]; } |
566 LOperand* right() { return inputs_[1]; } | 566 LOperand* right() { return inputs_[1]; } |
567 | 567 |
| 568 bool is_flooring() { return hydrogen_value()->IsMathFloorOfDiv(); } |
| 569 |
568 DECLARE_CONCRETE_INSTRUCTION(DivI, "div-i") | 570 DECLARE_CONCRETE_INSTRUCTION(DivI, "div-i") |
569 DECLARE_HYDROGEN_ACCESSOR(Div) | 571 DECLARE_HYDROGEN_ACCESSOR(Div) |
570 }; | 572 }; |
571 | 573 |
572 | 574 |
573 class LMathFloorOfDiv: public LTemplateInstruction<1, 2, 1> { | 575 class LMathFloorOfDiv: public LTemplateInstruction<1, 2, 1> { |
574 public: | 576 public: |
575 LMathFloorOfDiv(LOperand* left, | 577 LMathFloorOfDiv(LOperand* left, |
576 LOperand* right, | 578 LOperand* right, |
577 LOperand* temp = NULL) { | 579 LOperand* temp = NULL) { |
(...skipping 2140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2718 | 2720 |
2719 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); | 2721 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); |
2720 }; | 2722 }; |
2721 | 2723 |
2722 #undef DECLARE_HYDROGEN_ACCESSOR | 2724 #undef DECLARE_HYDROGEN_ACCESSOR |
2723 #undef DECLARE_CONCRETE_INSTRUCTION | 2725 #undef DECLARE_CONCRETE_INSTRUCTION |
2724 | 2726 |
2725 } } // namespace v8::internal | 2727 } } // namespace v8::internal |
2726 | 2728 |
2727 #endif // V8_IA32_LITHIUM_IA32_H_ | 2729 #endif // V8_IA32_LITHIUM_IA32_H_ |
OLD | NEW |