| OLD | NEW |
| 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, 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_OPT_CODE_GENERATOR_IA32_H_ | 5 #ifndef VM_OPT_CODE_GENERATOR_IA32_H_ |
| 6 #define VM_OPT_CODE_GENERATOR_IA32_H_ | 6 #define VM_OPT_CODE_GENERATOR_IA32_H_ |
| 7 | 7 |
| 8 #ifndef VM_OPT_CODE_GENERATOR_H_ | 8 #ifndef VM_OPT_CODE_GENERATOR_H_ |
| 9 #error Do not include opt_code_generator_ia32.h; use opt_code_generator.h. | 9 #error Do not include opt_code_generator_ia32.h; use opt_code_generator.h. |
| 10 #endif | 10 #endif |
| (...skipping 29 matching lines...) Expand all Loading... |
| 40 virtual void VisitDoWhileNode(DoWhileNode* node); | 40 virtual void VisitDoWhileNode(DoWhileNode* node); |
| 41 virtual void VisitWhileNode(WhileNode* node); | 41 virtual void VisitWhileNode(WhileNode* node); |
| 42 virtual void VisitIfNode(IfNode* node); | 42 virtual void VisitIfNode(IfNode* node); |
| 43 virtual void VisitInstanceCallNode(InstanceCallNode* node); | 43 virtual void VisitInstanceCallNode(InstanceCallNode* node); |
| 44 virtual void VisitStaticCallNode(StaticCallNode* node); | 44 virtual void VisitStaticCallNode(StaticCallNode* node); |
| 45 virtual void VisitReturnNode(ReturnNode* node); | 45 virtual void VisitReturnNode(ReturnNode* node); |
| 46 virtual void VisitSequenceNode(SequenceNode* node_sequence); | 46 virtual void VisitSequenceNode(SequenceNode* node_sequence); |
| 47 virtual void VisitStoreInstanceFieldNode(StoreInstanceFieldNode* node); | 47 virtual void VisitStoreInstanceFieldNode(StoreInstanceFieldNode* node); |
| 48 virtual void VisitCatchClauseNode(CatchClauseNode* node); | 48 virtual void VisitCatchClauseNode(CatchClauseNode* node); |
| 49 virtual void VisitTryCatchNode(TryCatchNode* node); | 49 virtual void VisitTryCatchNode(TryCatchNode* node); |
| 50 virtual void VisitUnaryOpNode(UnaryOpNode* node); |
| 50 | 51 |
| 51 // Return true if intrinsification succeeded and no more code is needed. | 52 // Return true if intrinsification succeeded and no more code is needed. |
| 52 // Returns false if either no intrinsification occured or if intrinsified | 53 // Returns false if either no intrinsification occured or if intrinsified |
| 53 // code needs the rest for slow case execution. | 54 // code needs the rest for slow case execution. |
| 54 virtual bool TryIntrinsify(); | 55 virtual bool TryIntrinsify(); |
| 55 virtual void GeneratePreEntryCode(); | 56 virtual void GeneratePreEntryCode(); |
| 56 virtual bool IsOptimizing() const { return true; } | 57 virtual bool IsOptimizing() const { return true; } |
| 57 | 58 |
| 58 virtual void CountBackwardLoop() {} | 59 virtual void CountBackwardLoop() {} |
| 59 virtual void GenerateDeferredCode(); | 60 virtual void GenerateDeferredCode(); |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 102 void GenerateInstanceSetter(const InstanceSetterArgs& args); | 103 void GenerateInstanceSetter(const InstanceSetterArgs& args); |
| 103 void InlineInstanceSetter(AstNode* node, | 104 void InlineInstanceSetter(AstNode* node, |
| 104 intptr_t id, | 105 intptr_t id, |
| 105 AstNode* receiver, | 106 AstNode* receiver, |
| 106 const String& field_name, | 107 const String& field_name, |
| 107 Register recv_reg, | 108 Register recv_reg, |
| 108 Register value_reg); | 109 Register value_reg); |
| 109 | 110 |
| 110 void CallDeoptimize(intptr_t node_id, intptr_t token_index); | 111 void CallDeoptimize(intptr_t node_id, intptr_t token_index); |
| 111 | 112 |
| 113 void GenerateSmiUnaryOp(UnaryOpNode* node); |
| 114 |
| 112 void GenerateSmiBinaryOp(BinaryOpNode* node); | 115 void GenerateSmiBinaryOp(BinaryOpNode* node); |
| 113 void GenerateSmiShiftBinaryOp(BinaryOpNode* node); | 116 void GenerateSmiShiftBinaryOp(BinaryOpNode* node); |
| 114 | 117 |
| 115 void GenerateDoubleBinaryOp(BinaryOpNode* node); | 118 void GenerateDoubleBinaryOp(BinaryOpNode* node); |
| 116 void GenerateMintBinaryOp(BinaryOpNode* node, bool allow_smi); | 119 void GenerateMintBinaryOp(BinaryOpNode* node, bool allow_smi); |
| 117 void CheckIfDoubleOrSmi(Register reg, | 120 void CheckIfDoubleOrSmi(Register reg, |
| 118 Register temp, | 121 Register temp, |
| 119 Label* is_smi, | 122 Label* is_smi, |
| 120 Label* not_double_or_smi); | 123 Label* not_double_or_smi); |
| 121 void GenerateDirectCall(intptr_t node_id, | 124 void GenerateDirectCall(intptr_t node_id, |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 159 const Class& smi_class_; | 162 const Class& smi_class_; |
| 160 const Class& double_class_; | 163 const Class& double_class_; |
| 161 | 164 |
| 162 DISALLOW_IMPLICIT_CONSTRUCTORS(OptimizingCodeGenerator); | 165 DISALLOW_IMPLICIT_CONSTRUCTORS(OptimizingCodeGenerator); |
| 163 }; | 166 }; |
| 164 | 167 |
| 165 } // namespace dart | 168 } // namespace dart |
| 166 | 169 |
| 167 | 170 |
| 168 #endif // VM_OPT_CODE_GENERATOR_IA32_H_ | 171 #endif // VM_OPT_CODE_GENERATOR_IA32_H_ |
| OLD | NEW |