| 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 4008 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4019 virtual void PrintOperandsTo(BufferFormatter* f) const; | 4019 virtual void PrintOperandsTo(BufferFormatter* f) const; |
| 4020 | 4020 |
| 4021 virtual intptr_t InputCount() const { | 4021 virtual intptr_t InputCount() const { |
| 4022 return values_->length(); | 4022 return values_->length(); |
| 4023 } | 4023 } |
| 4024 | 4024 |
| 4025 virtual Value* InputAt(intptr_t i) const { | 4025 virtual Value* InputAt(intptr_t i) const { |
| 4026 return (*values_)[i]; | 4026 return (*values_)[i]; |
| 4027 } | 4027 } |
| 4028 | 4028 |
| 4029 // SelectRepresentations pass is run once more while MaterializeObject |
| 4030 // instructions are still in the graph. To avoid any redundant boxing |
| 4031 // operations inserted by that pass we should indicate that this |
| 4032 // instruction can cope with any representation as it is essentially |
| 4033 // an environment use. |
| 4034 virtual Representation RequiredInputRepresentation(intptr_t idx) const { |
| 4035 ASSERT(0 <= idx && idx < InputCount()); |
| 4036 return kNoRepresentation; |
| 4037 } |
| 4038 |
| 4029 virtual bool CanDeoptimize() const { return false; } | 4039 virtual bool CanDeoptimize() const { return false; } |
| 4030 virtual EffectSet Effects() const { return EffectSet::None(); } | 4040 virtual EffectSet Effects() const { return EffectSet::None(); } |
| 4031 | 4041 |
| 4032 Location* locations() { return locations_; } | 4042 Location* locations() { return locations_; } |
| 4033 void set_locations(Location* locations) { locations_ = locations; } | 4043 void set_locations(Location* locations) { locations_ = locations; } |
| 4034 | 4044 |
| 4035 virtual bool MayThrow() const { return false; } | 4045 virtual bool MayThrow() const { return false; } |
| 4036 | 4046 |
| 4037 private: | 4047 private: |
| 4038 virtual void RawSetInputAt(intptr_t i, Value* value) { | 4048 virtual void RawSetInputAt(intptr_t i, Value* value) { |
| (...skipping 3071 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7110 ForwardInstructionIterator* current_iterator_; | 7120 ForwardInstructionIterator* current_iterator_; |
| 7111 | 7121 |
| 7112 private: | 7122 private: |
| 7113 DISALLOW_COPY_AND_ASSIGN(FlowGraphVisitor); | 7123 DISALLOW_COPY_AND_ASSIGN(FlowGraphVisitor); |
| 7114 }; | 7124 }; |
| 7115 | 7125 |
| 7116 | 7126 |
| 7117 } // namespace dart | 7127 } // namespace dart |
| 7118 | 7128 |
| 7119 #endif // VM_INTERMEDIATE_LANGUAGE_H_ | 7129 #endif // VM_INTERMEDIATE_LANGUAGE_H_ |
| OLD | NEW |