| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef VM_INTERMEDIATE_LANGUAGE_H_ | 5 #ifndef VM_INTERMEDIATE_LANGUAGE_H_ |
| 6 #define VM_INTERMEDIATE_LANGUAGE_H_ | 6 #define VM_INTERMEDIATE_LANGUAGE_H_ |
| 7 | 7 |
| 8 #include "vm/allocation.h" | 8 #include "vm/allocation.h" |
| 9 #include "vm/ast.h" | 9 #include "vm/ast.h" |
| 10 #include "vm/growable_array.h" | 10 #include "vm/growable_array.h" |
| (...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 82 V(_Double, truncateToDouble, DoubleTruncate, 615732263) \ | 82 V(_Double, truncateToDouble, DoubleTruncate, 615732263) \ |
| 83 V(_Double, roundToDouble, DoubleRound, 622146406) \ | 83 V(_Double, roundToDouble, DoubleRound, 622146406) \ |
| 84 V(_Double, floorToDouble, DoubleFloor, 1614014643) \ | 84 V(_Double, floorToDouble, DoubleFloor, 1614014643) \ |
| 85 V(_Double, ceilToDouble, DoubleCeil, 277859570) \ | 85 V(_Double, ceilToDouble, DoubleCeil, 277859570) \ |
| 86 V(_Double, _modulo, DoubleMod, 1443289156) \ | 86 V(_Double, _modulo, DoubleMod, 1443289156) \ |
| 87 V(::, sqrt, MathSqrt, 465520247) \ | 87 V(::, sqrt, MathSqrt, 465520247) \ |
| 88 V(::, sin, MathSin, 730107143) \ | 88 V(::, sin, MathSin, 730107143) \ |
| 89 V(::, cos, MathCos, 1282146521) \ | 89 V(::, cos, MathCos, 1282146521) \ |
| 90 V(::, min, MathMin, 1022567780) \ | 90 V(::, min, MathMin, 1022567780) \ |
| 91 V(::, max, MathMax, 612058870) \ | 91 V(::, max, MathMax, 612058870) \ |
| 92 V(::, _doublePow, MathDoublePow, 2125162289) \ | 92 V(::, _doublePow, MathDoublePow, 342259456) \ |
| 93 V(Float32x4, Float32x4., Float32x4Constructor, 1314950569) \ | 93 V(Float32x4, Float32x4., Float32x4Constructor, 1314950569) \ |
| 94 V(Float32x4, Float32x4.zero, Float32x4Zero, 1432281809) \ | 94 V(Float32x4, Float32x4.zero, Float32x4Zero, 1432281809) \ |
| 95 V(Float32x4, Float32x4.splat, Float32x4Splat, 1148280442) \ | 95 V(Float32x4, Float32x4.splat, Float32x4Splat, 1148280442) \ |
| 96 V(Float32x4, Float32x4.fromInt32x4Bits, Float32x4FromInt32x4Bits, \ | 96 V(Float32x4, Float32x4.fromInt32x4Bits, Float32x4FromInt32x4Bits, \ |
| 97 872145194) \ | 97 872145194) \ |
| 98 V(Float32x4, Float32x4.fromFloat64x2, Float32x4FromFloat64x2, 1511660322) \ | 98 V(Float32x4, Float32x4.fromFloat64x2, Float32x4FromFloat64x2, 1511660322) \ |
| 99 V(_Float32x4, shuffle, Float32x4Shuffle, 1178727105) \ | 99 V(_Float32x4, shuffle, Float32x4Shuffle, 1178727105) \ |
| 100 V(_Float32x4, shuffleMix, Float32x4ShuffleMix, 927956119) \ | 100 V(_Float32x4, shuffleMix, Float32x4ShuffleMix, 927956119) \ |
| 101 V(_Float32x4, get:x, Float32x4ShuffleX, 1351747629) \ | 101 V(_Float32x4, get:x, Float32x4ShuffleX, 1351747629) \ |
| 102 V(_Float32x4, get:y, Float32x4ShuffleY, 217416201) \ | 102 V(_Float32x4, get:y, Float32x4ShuffleY, 217416201) \ |
| (...skipping 7330 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7433 virtual bool AllowsCSE() const { return true; } | 7433 virtual bool AllowsCSE() const { return true; } |
| 7434 virtual EffectSet Effects() const { return EffectSet::None(); } | 7434 virtual EffectSet Effects() const { return EffectSet::None(); } |
| 7435 virtual EffectSet Dependencies() const { return EffectSet::None(); } | 7435 virtual EffectSet Dependencies() const { return EffectSet::None(); } |
| 7436 virtual bool AttributesEqual(Instruction* other) const { | 7436 virtual bool AttributesEqual(Instruction* other) const { |
| 7437 InvokeMathCFunctionInstr* other_invoke = other->AsInvokeMathCFunction(); | 7437 InvokeMathCFunctionInstr* other_invoke = other->AsInvokeMathCFunction(); |
| 7438 return other_invoke->recognized_kind() == recognized_kind(); | 7438 return other_invoke->recognized_kind() == recognized_kind(); |
| 7439 } | 7439 } |
| 7440 | 7440 |
| 7441 virtual bool MayThrow() const { return false; } | 7441 virtual bool MayThrow() const { return false; } |
| 7442 | 7442 |
| 7443 private: | |
| 7444 static const intptr_t kSavedSpTempIndex = 0; | 7443 static const intptr_t kSavedSpTempIndex = 0; |
| 7445 static const intptr_t kObjectTempIndex = 1; | 7444 static const intptr_t kObjectTempIndex = 1; |
| 7446 static const intptr_t kDoubleTempIndex = 2; | 7445 static const intptr_t kDoubleTempIndex = 2; |
| 7446 |
| 7447 private: |
| 7447 virtual void RawSetInputAt(intptr_t i, Value* value) { | 7448 virtual void RawSetInputAt(intptr_t i, Value* value) { |
| 7448 (*inputs_)[i] = value; | 7449 (*inputs_)[i] = value; |
| 7449 } | 7450 } |
| 7450 | 7451 |
| 7451 ZoneGrowableArray<Value*>* inputs_; | 7452 ZoneGrowableArray<Value*>* inputs_; |
| 7452 const MethodRecognizer::Kind recognized_kind_; | 7453 const MethodRecognizer::Kind recognized_kind_; |
| 7453 const intptr_t token_pos_; | 7454 const intptr_t token_pos_; |
| 7454 | 7455 |
| 7455 DISALLOW_COPY_AND_ASSIGN(InvokeMathCFunctionInstr); | 7456 DISALLOW_COPY_AND_ASSIGN(InvokeMathCFunctionInstr); |
| 7456 }; | 7457 }; |
| (...skipping 499 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7956 ForwardInstructionIterator* current_iterator_; | 7957 ForwardInstructionIterator* current_iterator_; |
| 7957 | 7958 |
| 7958 private: | 7959 private: |
| 7959 DISALLOW_COPY_AND_ASSIGN(FlowGraphVisitor); | 7960 DISALLOW_COPY_AND_ASSIGN(FlowGraphVisitor); |
| 7960 }; | 7961 }; |
| 7961 | 7962 |
| 7962 | 7963 |
| 7963 } // namespace dart | 7964 } // namespace dart |
| 7964 | 7965 |
| 7965 #endif // VM_INTERMEDIATE_LANGUAGE_H_ | 7966 #endif // VM_INTERMEDIATE_LANGUAGE_H_ |
| OLD | NEW |