| 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 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 86 V(ConstantT) \ | 86 V(ConstantT) \ |
| 87 V(Context) \ | 87 V(Context) \ |
| 88 V(DateField) \ | 88 V(DateField) \ |
| 89 V(DebugBreak) \ | 89 V(DebugBreak) \ |
| 90 V(DeclareGlobals) \ | 90 V(DeclareGlobals) \ |
| 91 V(Deoptimize) \ | 91 V(Deoptimize) \ |
| 92 V(DivI) \ | 92 V(DivI) \ |
| 93 V(DoubleToI) \ | 93 V(DoubleToI) \ |
| 94 V(DoubleToSmi) \ | 94 V(DoubleToSmi) \ |
| 95 V(Drop) \ | 95 V(Drop) \ |
| 96 V(Dummy) \ |
| 96 V(DummyUse) \ | 97 V(DummyUse) \ |
| 97 V(ElementsKind) \ | 98 V(ElementsKind) \ |
| 98 V(ForInCacheArray) \ | 99 V(ForInCacheArray) \ |
| 99 V(ForInPrepareMap) \ | 100 V(ForInPrepareMap) \ |
| 100 V(FunctionLiteral) \ | 101 V(FunctionLiteral) \ |
| 101 V(GetCachedArrayIndex) \ | 102 V(GetCachedArrayIndex) \ |
| 102 V(GlobalObject) \ | 103 V(GlobalObject) \ |
| 103 V(GlobalReceiver) \ | 104 V(GlobalReceiver) \ |
| 104 V(Goto) \ | 105 V(Goto) \ |
| 105 V(HasCachedArrayIndexAndBranch) \ | 106 V(HasCachedArrayIndexAndBranch) \ |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 149 V(NumberTagU) \ | 150 V(NumberTagU) \ |
| 150 V(NumberUntagD) \ | 151 V(NumberUntagD) \ |
| 151 V(OsrEntry) \ | 152 V(OsrEntry) \ |
| 152 V(OuterContext) \ | 153 V(OuterContext) \ |
| 153 V(Parameter) \ | 154 V(Parameter) \ |
| 154 V(Power) \ | 155 V(Power) \ |
| 155 V(Random) \ | 156 V(Random) \ |
| 156 V(PushArgument) \ | 157 V(PushArgument) \ |
| 157 V(RegExpLiteral) \ | 158 V(RegExpLiteral) \ |
| 158 V(Return) \ | 159 V(Return) \ |
| 160 V(SeqStringGetChar) \ |
| 159 V(SeqStringSetChar) \ | 161 V(SeqStringSetChar) \ |
| 160 V(ShiftI) \ | 162 V(ShiftI) \ |
| 161 V(SmiTag) \ | 163 V(SmiTag) \ |
| 162 V(SmiUntag) \ | 164 V(SmiUntag) \ |
| 163 V(StackCheck) \ | 165 V(StackCheck) \ |
| 164 V(StoreCodeEntry) \ | 166 V(StoreCodeEntry) \ |
| 165 V(StoreContextSlot) \ | 167 V(StoreContextSlot) \ |
| 166 V(StoreGlobalCell) \ | 168 V(StoreGlobalCell) \ |
| 167 V(StoreGlobalGeneric) \ | 169 V(StoreGlobalGeneric) \ |
| 168 V(StoreKeyed) \ | 170 V(StoreKeyed) \ |
| (...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 424 HBasicBlock* block_; | 426 HBasicBlock* block_; |
| 425 }; | 427 }; |
| 426 | 428 |
| 427 | 429 |
| 428 class LLazyBailout V8_FINAL : public LTemplateInstruction<0, 0, 0> { | 430 class LLazyBailout V8_FINAL : public LTemplateInstruction<0, 0, 0> { |
| 429 public: | 431 public: |
| 430 DECLARE_CONCRETE_INSTRUCTION(LazyBailout, "lazy-bailout") | 432 DECLARE_CONCRETE_INSTRUCTION(LazyBailout, "lazy-bailout") |
| 431 }; | 433 }; |
| 432 | 434 |
| 433 | 435 |
| 436 class LDummy V8_FINAL : public LTemplateInstruction<1, 0, 0> { |
| 437 public: |
| 438 explicit LDummy() { } |
| 439 DECLARE_CONCRETE_INSTRUCTION(Dummy, "dummy") |
| 440 }; |
| 441 |
| 442 |
| 434 class LDummyUse V8_FINAL : public LTemplateInstruction<1, 1, 0> { | 443 class LDummyUse V8_FINAL : public LTemplateInstruction<1, 1, 0> { |
| 435 public: | 444 public: |
| 436 explicit LDummyUse(LOperand* value) { | 445 explicit LDummyUse(LOperand* value) { |
| 437 inputs_[0] = value; | 446 inputs_[0] = value; |
| 438 } | 447 } |
| 439 DECLARE_CONCRETE_INSTRUCTION(DummyUse, "dummy-use") | 448 DECLARE_CONCRETE_INSTRUCTION(DummyUse, "dummy-use") |
| 440 }; | 449 }; |
| 441 | 450 |
| 442 | 451 |
| 443 class LDeoptimize V8_FINAL : public LTemplateInstruction<0, 0, 0> { | 452 class LDeoptimize V8_FINAL : public LTemplateInstruction<0, 0, 0> { |
| (...skipping 290 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 734 inputs_[0] = value; | 743 inputs_[0] = value; |
| 735 } | 744 } |
| 736 | 745 |
| 737 LOperand* value() { return inputs_[0]; } | 746 LOperand* value() { return inputs_[0]; } |
| 738 | 747 |
| 739 DECLARE_CONCRETE_INSTRUCTION(MathFloor, "math-floor") | 748 DECLARE_CONCRETE_INSTRUCTION(MathFloor, "math-floor") |
| 740 DECLARE_HYDROGEN_ACCESSOR(UnaryMathOperation) | 749 DECLARE_HYDROGEN_ACCESSOR(UnaryMathOperation) |
| 741 }; | 750 }; |
| 742 | 751 |
| 743 | 752 |
| 744 class LMathRound V8_FINAL : public LTemplateInstruction<1, 2, 1> { | 753 class LMathRound V8_FINAL : public LTemplateInstruction<1, 1, 1> { |
| 745 public: | 754 public: |
| 746 LMathRound(LOperand* context, LOperand* value, LOperand* temp) { | 755 LMathRound(LOperand* value, LOperand* temp) { |
| 747 inputs_[1] = context; | |
| 748 inputs_[0] = value; | 756 inputs_[0] = value; |
| 749 temps_[0] = temp; | 757 temps_[0] = temp; |
| 750 } | 758 } |
| 751 | 759 |
| 752 LOperand* context() { return inputs_[1]; } | |
| 753 LOperand* value() { return inputs_[0]; } | 760 LOperand* value() { return inputs_[0]; } |
| 754 LOperand* temp() { return temps_[0]; } | 761 LOperand* temp() { return temps_[0]; } |
| 755 | 762 |
| 756 DECLARE_CONCRETE_INSTRUCTION(MathRound, "math-round") | 763 DECLARE_CONCRETE_INSTRUCTION(MathRound, "math-round") |
| 757 DECLARE_HYDROGEN_ACCESSOR(UnaryMathOperation) | 764 DECLARE_HYDROGEN_ACCESSOR(UnaryMathOperation) |
| 758 }; | 765 }; |
| 759 | 766 |
| 760 | 767 |
| 761 class LMathAbs V8_FINAL : public LTemplateInstruction<1, 2, 0> { | 768 class LMathAbs V8_FINAL : public LTemplateInstruction<1, 2, 0> { |
| 762 public: | 769 public: |
| (...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 845 explicit LMathSqrt(LOperand* value) { | 852 explicit LMathSqrt(LOperand* value) { |
| 846 inputs_[0] = value; | 853 inputs_[0] = value; |
| 847 } | 854 } |
| 848 | 855 |
| 849 LOperand* value() { return inputs_[0]; } | 856 LOperand* value() { return inputs_[0]; } |
| 850 | 857 |
| 851 DECLARE_CONCRETE_INSTRUCTION(MathSqrt, "math-sqrt") | 858 DECLARE_CONCRETE_INSTRUCTION(MathSqrt, "math-sqrt") |
| 852 }; | 859 }; |
| 853 | 860 |
| 854 | 861 |
| 855 class LMathPowHalf V8_FINAL : public LTemplateInstruction<1, 2, 1> { | 862 class LMathPowHalf V8_FINAL : public LTemplateInstruction<1, 1, 1> { |
| 856 public: | 863 public: |
| 857 LMathPowHalf(LOperand* context, LOperand* value, LOperand* temp) { | 864 LMathPowHalf(LOperand* value, LOperand* temp) { |
| 858 inputs_[1] = context; | |
| 859 inputs_[0] = value; | 865 inputs_[0] = value; |
| 860 temps_[0] = temp; | 866 temps_[0] = temp; |
| 861 } | 867 } |
| 862 | 868 |
| 863 LOperand* context() { return inputs_[1]; } | |
| 864 LOperand* value() { return inputs_[0]; } | 869 LOperand* value() { return inputs_[0]; } |
| 865 LOperand* temp() { return temps_[0]; } | 870 LOperand* temp() { return temps_[0]; } |
| 866 | 871 |
| 867 DECLARE_CONCRETE_INSTRUCTION(MathPowHalf, "math-pow-half") | 872 DECLARE_CONCRETE_INSTRUCTION(MathPowHalf, "math-pow-half") |
| 868 }; | 873 }; |
| 869 | 874 |
| 870 | 875 |
| 871 class LCmpObjectEqAndBranch V8_FINAL : public LControlInstruction<2, 0> { | 876 class LCmpObjectEqAndBranch V8_FINAL : public LControlInstruction<2, 0> { |
| 872 public: | 877 public: |
| 873 LCmpObjectEqAndBranch(LOperand* left, LOperand* right) { | 878 LCmpObjectEqAndBranch(LOperand* left, LOperand* right) { |
| (...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 962 | 967 |
| 963 | 968 |
| 964 class LStringCompareAndBranch V8_FINAL : public LControlInstruction<3, 0> { | 969 class LStringCompareAndBranch V8_FINAL : public LControlInstruction<3, 0> { |
| 965 public: | 970 public: |
| 966 LStringCompareAndBranch(LOperand* context, LOperand* left, LOperand* right) { | 971 LStringCompareAndBranch(LOperand* context, LOperand* left, LOperand* right) { |
| 967 inputs_[0] = context; | 972 inputs_[0] = context; |
| 968 inputs_[1] = left; | 973 inputs_[1] = left; |
| 969 inputs_[2] = right; | 974 inputs_[2] = right; |
| 970 } | 975 } |
| 971 | 976 |
| 977 LOperand* context() { return inputs_[1]; } |
| 972 LOperand* left() { return inputs_[1]; } | 978 LOperand* left() { return inputs_[1]; } |
| 973 LOperand* right() { return inputs_[2]; } | 979 LOperand* right() { return inputs_[2]; } |
| 974 | 980 |
| 975 DECLARE_CONCRETE_INSTRUCTION(StringCompareAndBranch, | 981 DECLARE_CONCRETE_INSTRUCTION(StringCompareAndBranch, |
| 976 "string-compare-and-branch") | 982 "string-compare-and-branch") |
| 977 DECLARE_HYDROGEN_ACCESSOR(StringCompareAndBranch) | 983 DECLARE_HYDROGEN_ACCESSOR(StringCompareAndBranch) |
| 978 | 984 |
| 979 virtual void PrintDataTo(StringStream* stream) V8_OVERRIDE; | 985 virtual void PrintDataTo(StringStream* stream) V8_OVERRIDE; |
| 980 | 986 |
| 981 Token::Value op() const { return hydrogen()->token(); } | 987 Token::Value op() const { return hydrogen()->token(); } |
| (...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1066 public: | 1072 public: |
| 1067 LCmpT(LOperand* context, LOperand* left, LOperand* right) { | 1073 LCmpT(LOperand* context, LOperand* left, LOperand* right) { |
| 1068 inputs_[0] = context; | 1074 inputs_[0] = context; |
| 1069 inputs_[1] = left; | 1075 inputs_[1] = left; |
| 1070 inputs_[2] = right; | 1076 inputs_[2] = right; |
| 1071 } | 1077 } |
| 1072 | 1078 |
| 1073 DECLARE_CONCRETE_INSTRUCTION(CmpT, "cmp-t") | 1079 DECLARE_CONCRETE_INSTRUCTION(CmpT, "cmp-t") |
| 1074 DECLARE_HYDROGEN_ACCESSOR(CompareGeneric) | 1080 DECLARE_HYDROGEN_ACCESSOR(CompareGeneric) |
| 1075 | 1081 |
| 1082 LOperand* context() { return inputs_[0]; } |
| 1076 Token::Value op() const { return hydrogen()->token(); } | 1083 Token::Value op() const { return hydrogen()->token(); } |
| 1077 }; | 1084 }; |
| 1078 | 1085 |
| 1079 | 1086 |
| 1080 class LInstanceOf V8_FINAL : public LTemplateInstruction<1, 3, 0> { | 1087 class LInstanceOf V8_FINAL : public LTemplateInstruction<1, 3, 0> { |
| 1081 public: | 1088 public: |
| 1082 LInstanceOf(LOperand* context, LOperand* left, LOperand* right) { | 1089 LInstanceOf(LOperand* context, LOperand* left, LOperand* right) { |
| 1083 inputs_[0] = context; | 1090 inputs_[0] = context; |
| 1084 inputs_[1] = left; | 1091 inputs_[1] = left; |
| 1085 inputs_[2] = right; | 1092 inputs_[2] = right; |
| 1086 } | 1093 } |
| 1087 | 1094 |
| 1088 LOperand* context() { return inputs_[0]; } | 1095 LOperand* context() { return inputs_[0]; } |
| 1089 | 1096 |
| 1090 DECLARE_CONCRETE_INSTRUCTION(InstanceOf, "instance-of") | 1097 DECLARE_CONCRETE_INSTRUCTION(InstanceOf, "instance-of") |
| 1091 }; | 1098 }; |
| 1092 | 1099 |
| 1093 | 1100 |
| 1094 class LInstanceOfKnownGlobal V8_FINAL : public LTemplateInstruction<1, 2, 1> { | 1101 class LInstanceOfKnownGlobal V8_FINAL : public LTemplateInstruction<1, 2, 1> { |
| 1095 public: | 1102 public: |
| 1096 LInstanceOfKnownGlobal(LOperand* context, LOperand* value, LOperand* temp) { | 1103 LInstanceOfKnownGlobal(LOperand* context, LOperand* value, LOperand* temp) { |
| 1097 inputs_[0] = context; | 1104 inputs_[0] = context; |
| 1098 inputs_[1] = value; | 1105 inputs_[1] = value; |
| 1099 temps_[0] = temp; | 1106 temps_[0] = temp; |
| 1100 } | 1107 } |
| 1101 | 1108 |
| 1109 LOperand* context() { return inputs_[0]; } |
| 1102 LOperand* value() { return inputs_[1]; } | 1110 LOperand* value() { return inputs_[1]; } |
| 1103 LOperand* temp() { return temps_[0]; } | 1111 LOperand* temp() { return temps_[0]; } |
| 1104 | 1112 |
| 1105 DECLARE_CONCRETE_INSTRUCTION(InstanceOfKnownGlobal, | 1113 DECLARE_CONCRETE_INSTRUCTION(InstanceOfKnownGlobal, |
| 1106 "instance-of-known-global") | 1114 "instance-of-known-global") |
| 1107 DECLARE_HYDROGEN_ACCESSOR(InstanceOfKnownGlobal) | 1115 DECLARE_HYDROGEN_ACCESSOR(InstanceOfKnownGlobal) |
| 1108 | 1116 |
| 1109 Handle<JSFunction> function() const { return hydrogen()->function(); } | 1117 Handle<JSFunction> function() const { return hydrogen()->function(); } |
| 1110 LEnvironment* GetDeferredLazyDeoptimizationEnvironment() { | 1118 LEnvironment* GetDeferredLazyDeoptimizationEnvironment() { |
| 1111 return lazy_deopt_env_; | 1119 return lazy_deopt_env_; |
| (...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1330 DECLARE_CONCRETE_INSTRUCTION(DateField, "date-field") | 1338 DECLARE_CONCRETE_INSTRUCTION(DateField, "date-field") |
| 1331 DECLARE_HYDROGEN_ACCESSOR(DateField) | 1339 DECLARE_HYDROGEN_ACCESSOR(DateField) |
| 1332 | 1340 |
| 1333 Smi* index() const { return index_; } | 1341 Smi* index() const { return index_; } |
| 1334 | 1342 |
| 1335 private: | 1343 private: |
| 1336 Smi* index_; | 1344 Smi* index_; |
| 1337 }; | 1345 }; |
| 1338 | 1346 |
| 1339 | 1347 |
| 1348 class LSeqStringGetChar V8_FINAL : public LTemplateInstruction<1, 2, 0> { |
| 1349 public: |
| 1350 LSeqStringGetChar(LOperand* string, LOperand* index) { |
| 1351 inputs_[0] = string; |
| 1352 inputs_[1] = index; |
| 1353 } |
| 1354 |
| 1355 LOperand* string() const { return inputs_[0]; } |
| 1356 LOperand* index() const { return inputs_[1]; } |
| 1357 |
| 1358 DECLARE_CONCRETE_INSTRUCTION(SeqStringGetChar, "seq-string-get-char") |
| 1359 DECLARE_HYDROGEN_ACCESSOR(SeqStringGetChar) |
| 1360 }; |
| 1361 |
| 1362 |
| 1340 class LSeqStringSetChar V8_FINAL : public LTemplateInstruction<1, 3, 0> { | 1363 class LSeqStringSetChar V8_FINAL : public LTemplateInstruction<1, 3, 0> { |
| 1341 public: | 1364 public: |
| 1342 LSeqStringSetChar(LOperand* string, | 1365 LSeqStringSetChar(LOperand* string, |
| 1343 LOperand* index, | 1366 LOperand* index, |
| 1344 LOperand* value) { | 1367 LOperand* value) { |
| 1345 inputs_[0] = string; | 1368 inputs_[0] = string; |
| 1346 inputs_[1] = index; | 1369 inputs_[1] = index; |
| 1347 inputs_[2] = value; | 1370 inputs_[2] = value; |
| 1348 } | 1371 } |
| 1349 | 1372 |
| (...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1490 | 1513 |
| 1491 Token::Value op() const { return op_; } | 1514 Token::Value op() const { return op_; } |
| 1492 | 1515 |
| 1493 private: | 1516 private: |
| 1494 Token::Value op_; | 1517 Token::Value op_; |
| 1495 }; | 1518 }; |
| 1496 | 1519 |
| 1497 | 1520 |
| 1498 class LReturn V8_FINAL : public LTemplateInstruction<0, 3, 0> { | 1521 class LReturn V8_FINAL : public LTemplateInstruction<0, 3, 0> { |
| 1499 public: | 1522 public: |
| 1500 explicit LReturn(LOperand* value, LOperand* context, | 1523 explicit LReturn(LOperand* value, |
| 1524 LOperand* context, |
| 1501 LOperand* parameter_count) { | 1525 LOperand* parameter_count) { |
| 1502 inputs_[0] = value; | 1526 inputs_[0] = value; |
| 1503 inputs_[1] = context; | 1527 inputs_[1] = context; |
| 1504 inputs_[2] = parameter_count; | 1528 inputs_[2] = parameter_count; |
| 1505 } | 1529 } |
| 1506 | 1530 |
| 1507 bool has_constant_parameter_count() { | 1531 bool has_constant_parameter_count() { |
| 1508 return parameter_count()->IsConstantOperand(); | 1532 return parameter_count()->IsConstantOperand(); |
| 1509 } | 1533 } |
| 1510 LConstantOperand* constant_parameter_count() { | 1534 LConstantOperand* constant_parameter_count() { |
| (...skipping 1403 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2914 | 2938 |
| 2915 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); | 2939 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); |
| 2916 }; | 2940 }; |
| 2917 | 2941 |
| 2918 #undef DECLARE_HYDROGEN_ACCESSOR | 2942 #undef DECLARE_HYDROGEN_ACCESSOR |
| 2919 #undef DECLARE_CONCRETE_INSTRUCTION | 2943 #undef DECLARE_CONCRETE_INSTRUCTION |
| 2920 | 2944 |
| 2921 } } // namespace v8::internal | 2945 } } // namespace v8::internal |
| 2922 | 2946 |
| 2923 #endif // V8_IA32_LITHIUM_IA32_H_ | 2947 #endif // V8_IA32_LITHIUM_IA32_H_ |
| OLD | NEW |