| 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 1426 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1437 } | 1437 } |
| 1438 | 1438 |
| 1439 LOperand* left() { return inputs_[0]; } | 1439 LOperand* left() { return inputs_[0]; } |
| 1440 LOperand* right() { return inputs_[1]; } | 1440 LOperand* right() { return inputs_[1]; } |
| 1441 | 1441 |
| 1442 DECLARE_CONCRETE_INSTRUCTION(Power, "power") | 1442 DECLARE_CONCRETE_INSTRUCTION(Power, "power") |
| 1443 DECLARE_HYDROGEN_ACCESSOR(Power) | 1443 DECLARE_HYDROGEN_ACCESSOR(Power) |
| 1444 }; | 1444 }; |
| 1445 | 1445 |
| 1446 | 1446 |
| 1447 class LRandom V8_FINAL : public LTemplateInstruction<1, 1, 0> { | 1447 class LRandom V8_FINAL : public LTemplateInstruction<1, 1, 3> { |
| 1448 public: | 1448 public: |
| 1449 explicit LRandom(LOperand* global_object) { | 1449 LRandom(LOperand* global_object, |
| 1450 LOperand* scratch, |
| 1451 LOperand* scratch2, |
| 1452 LOperand* scratch3) { |
| 1450 inputs_[0] = global_object; | 1453 inputs_[0] = global_object; |
| 1454 temps_[0] = scratch; |
| 1455 temps_[1] = scratch2; |
| 1456 temps_[2] = scratch3; |
| 1451 } | 1457 } |
| 1452 | 1458 |
| 1453 LOperand* global_object() { return inputs_[0]; } | 1459 LOperand* global_object() const { return inputs_[0]; } |
| 1460 LOperand* scratch() const { return temps_[0]; } |
| 1461 LOperand* scratch2() const { return temps_[1]; } |
| 1462 LOperand* scratch3() const { return temps_[2]; } |
| 1454 | 1463 |
| 1455 DECLARE_CONCRETE_INSTRUCTION(Random, "random") | 1464 DECLARE_CONCRETE_INSTRUCTION(Random, "random") |
| 1456 DECLARE_HYDROGEN_ACCESSOR(Random) | 1465 DECLARE_HYDROGEN_ACCESSOR(Random) |
| 1457 }; | 1466 }; |
| 1458 | 1467 |
| 1459 | 1468 |
| 1460 class LArithmeticD V8_FINAL : public LTemplateInstruction<1, 2, 0> { | 1469 class LArithmeticD V8_FINAL : public LTemplateInstruction<1, 2, 0> { |
| 1461 public: | 1470 public: |
| 1462 LArithmeticD(Token::Value op, LOperand* left, LOperand* right) | 1471 LArithmeticD(Token::Value op, LOperand* left, LOperand* right) |
| 1463 : op_(op) { | 1472 : op_(op) { |
| (...skipping 619 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2083 inputs_[0] = value; | 2092 inputs_[0] = value; |
| 2084 temps_[0] = temp; | 2093 temps_[0] = temp; |
| 2085 temps_[1] = temp2; | 2094 temps_[1] = temp2; |
| 2086 } | 2095 } |
| 2087 | 2096 |
| 2088 LOperand* value() { return inputs_[0]; } | 2097 LOperand* value() { return inputs_[0]; } |
| 2089 LOperand* temp() { return temps_[0]; } | 2098 LOperand* temp() { return temps_[0]; } |
| 2090 LOperand* temp2() { return temps_[1]; } | 2099 LOperand* temp2() { return temps_[1]; } |
| 2091 | 2100 |
| 2092 DECLARE_CONCRETE_INSTRUCTION(TaggedToI, "tagged-to-i") | 2101 DECLARE_CONCRETE_INSTRUCTION(TaggedToI, "tagged-to-i") |
| 2093 DECLARE_HYDROGEN_ACCESSOR(UnaryOperation) | 2102 DECLARE_HYDROGEN_ACCESSOR(Change) |
| 2094 | 2103 |
| 2095 bool truncating() { return hydrogen()->CanTruncateToInt32(); } | 2104 bool truncating() { return hydrogen()->CanTruncateToInt32(); } |
| 2096 }; | 2105 }; |
| 2097 | 2106 |
| 2098 | 2107 |
| 2099 class LSmiTag V8_FINAL : public LTemplateInstruction<1, 1, 0> { | 2108 class LSmiTag V8_FINAL : public LTemplateInstruction<1, 1, 0> { |
| 2100 public: | 2109 public: |
| 2101 explicit LSmiTag(LOperand* value) { | 2110 explicit LSmiTag(LOperand* value) { |
| 2102 inputs_[0] = value; | 2111 inputs_[0] = value; |
| 2103 } | 2112 } |
| (...skipping 633 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2737 ZoneList<HValue*>* objects_to_materialize); | 2746 ZoneList<HValue*>* objects_to_materialize); |
| 2738 | 2747 |
| 2739 void VisitInstruction(HInstruction* current); | 2748 void VisitInstruction(HInstruction* current); |
| 2740 | 2749 |
| 2741 void DoBasicBlock(HBasicBlock* block, HBasicBlock* next_block); | 2750 void DoBasicBlock(HBasicBlock* block, HBasicBlock* next_block); |
| 2742 LInstruction* DoBit(Token::Value op, HBitwiseBinaryOperation* instr); | 2751 LInstruction* DoBit(Token::Value op, HBitwiseBinaryOperation* instr); |
| 2743 LInstruction* DoShift(Token::Value op, HBitwiseBinaryOperation* instr); | 2752 LInstruction* DoShift(Token::Value op, HBitwiseBinaryOperation* instr); |
| 2744 LInstruction* DoArithmeticD(Token::Value op, | 2753 LInstruction* DoArithmeticD(Token::Value op, |
| 2745 HArithmeticBinaryOperation* instr); | 2754 HArithmeticBinaryOperation* instr); |
| 2746 LInstruction* DoArithmeticT(Token::Value op, | 2755 LInstruction* DoArithmeticT(Token::Value op, |
| 2747 HArithmeticBinaryOperation* instr); | 2756 HBinaryOperation* instr); |
| 2748 | 2757 |
| 2749 LPlatformChunk* chunk_; | 2758 LPlatformChunk* chunk_; |
| 2750 CompilationInfo* info_; | 2759 CompilationInfo* info_; |
| 2751 HGraph* const graph_; | 2760 HGraph* const graph_; |
| 2752 Zone* zone_; | 2761 Zone* zone_; |
| 2753 Status status_; | 2762 Status status_; |
| 2754 HInstruction* current_instruction_; | 2763 HInstruction* current_instruction_; |
| 2755 HBasicBlock* current_block_; | 2764 HBasicBlock* current_block_; |
| 2756 HBasicBlock* next_block_; | 2765 HBasicBlock* next_block_; |
| 2757 int argument_count_; | 2766 int argument_count_; |
| 2758 LAllocator* allocator_; | 2767 LAllocator* allocator_; |
| 2759 int position_; | 2768 int position_; |
| 2760 LInstruction* instruction_pending_deoptimization_environment_; | 2769 LInstruction* instruction_pending_deoptimization_environment_; |
| 2761 BailoutId pending_deoptimization_ast_id_; | 2770 BailoutId pending_deoptimization_ast_id_; |
| 2762 | 2771 |
| 2763 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); | 2772 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); |
| 2764 }; | 2773 }; |
| 2765 | 2774 |
| 2766 #undef DECLARE_HYDROGEN_ACCESSOR | 2775 #undef DECLARE_HYDROGEN_ACCESSOR |
| 2767 #undef DECLARE_CONCRETE_INSTRUCTION | 2776 #undef DECLARE_CONCRETE_INSTRUCTION |
| 2768 | 2777 |
| 2769 } } // namespace v8::internal | 2778 } } // namespace v8::internal |
| 2770 | 2779 |
| 2771 #endif // V8_MIPS_LITHIUM_MIPS_H_ | 2780 #endif // V8_MIPS_LITHIUM_MIPS_H_ |
| OLD | NEW |