| 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 7787 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7798 virtual Instruction* Canonicalize(FlowGraph* flow_graph); | 7798 virtual Instruction* Canonicalize(FlowGraph* flow_graph); |
| 7799 | 7799 |
| 7800 bool IsNullCheck() const { | 7800 bool IsNullCheck() const { |
| 7801 return DeoptIfNull() || DeoptIfNotNull(); | 7801 return DeoptIfNull() || DeoptIfNotNull(); |
| 7802 } | 7802 } |
| 7803 | 7803 |
| 7804 bool DeoptIfNull() const; | 7804 bool DeoptIfNull() const; |
| 7805 bool DeoptIfNotNull() const; | 7805 bool DeoptIfNotNull() const; |
| 7806 | 7806 |
| 7807 bool IsDenseSwitch() const; | 7807 bool IsDenseSwitch() const; |
| 7808 static bool IsDenseCidRange(const ICData& unary_checks); |
| 7808 intptr_t ComputeCidMask() const; | 7809 intptr_t ComputeCidMask() const; |
| 7809 static bool IsDenseMask(intptr_t mask); | 7810 static bool IsDenseMask(intptr_t mask); |
| 7810 | 7811 |
| 7811 virtual bool AllowsCSE() const { return true; } | 7812 virtual bool AllowsCSE() const { return true; } |
| 7812 virtual EffectSet Dependencies() const; | 7813 virtual EffectSet Dependencies() const; |
| 7813 virtual EffectSet Effects() const { return EffectSet::None(); } | 7814 virtual EffectSet Effects() const { return EffectSet::None(); } |
| 7814 virtual bool AttributesEqual(Instruction* other) const; | 7815 virtual bool AttributesEqual(Instruction* other) const; |
| 7815 | 7816 |
| 7816 void set_licm_hoisted(bool value) { licm_hoisted_ = value; } | 7817 void set_licm_hoisted(bool value) { licm_hoisted_ = value; } |
| 7817 | 7818 |
| 7818 static bool IsImmutableClassId(intptr_t cid); | 7819 static bool IsImmutableClassId(intptr_t cid); |
| 7819 | 7820 |
| 7820 PRINT_OPERANDS_TO_SUPPORT | 7821 PRINT_OPERANDS_TO_SUPPORT |
| 7821 | 7822 |
| 7822 private: | 7823 private: |
| 7823 const ICData& unary_checks_; | 7824 const ICData& unary_checks_; |
| 7824 GrowableArray<intptr_t> cids_; // Sorted, lowest first. | 7825 GrowableArray<intptr_t> cids_; // Sorted, lowest first. |
| 7825 bool licm_hoisted_; | 7826 bool licm_hoisted_; |
| 7827 bool is_dense_switch_; |
| 7826 const TokenPosition token_pos_; | 7828 const TokenPosition token_pos_; |
| 7827 | 7829 |
| 7828 DISALLOW_COPY_AND_ASSIGN(CheckClassInstr); | 7830 DISALLOW_COPY_AND_ASSIGN(CheckClassInstr); |
| 7829 }; | 7831 }; |
| 7830 | 7832 |
| 7831 | 7833 |
| 7832 class CheckSmiInstr : public TemplateInstruction<1, NoThrow, Pure> { | 7834 class CheckSmiInstr : public TemplateInstruction<1, NoThrow, Pure> { |
| 7833 public: | 7835 public: |
| 7834 CheckSmiInstr(Value* value, intptr_t deopt_id, TokenPosition token_pos) | 7836 CheckSmiInstr(Value* value, intptr_t deopt_id, TokenPosition token_pos) |
| 7835 : TemplateInstruction(deopt_id), | 7837 : TemplateInstruction(deopt_id), |
| (...skipping 445 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 8281 LocationSummary* Name::MakeLocationSummary(Zone* zone, bool opt) const { \ | 8283 LocationSummary* Name::MakeLocationSummary(Zone* zone, bool opt) const { \ |
| 8282 UNIMPLEMENTED(); \ | 8284 UNIMPLEMENTED(); \ |
| 8283 return NULL; \ | 8285 return NULL; \ |
| 8284 } \ | 8286 } \ |
| 8285 void Name::EmitNativeCode(FlowGraphCompiler* compiler) { UNIMPLEMENTED(); } | 8287 void Name::EmitNativeCode(FlowGraphCompiler* compiler) { UNIMPLEMENTED(); } |
| 8286 | 8288 |
| 8287 | 8289 |
| 8288 } // namespace dart | 8290 } // namespace dart |
| 8289 | 8291 |
| 8290 #endif // VM_INTERMEDIATE_LANGUAGE_H_ | 8292 #endif // VM_INTERMEDIATE_LANGUAGE_H_ |
| OLD | NEW |