Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(310)

Side by Side Diff: runtime/vm/aot_optimizer.h

Issue 2098643003: VM: [AOT] Make sure that we inline all resolved accessor invocations. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | runtime/vm/aot_optimizer.cc » ('j') | runtime/vm/aot_optimizer.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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_AOT_OPTIMIZER_H_ 5 #ifndef VM_AOT_OPTIMIZER_H_
6 #define VM_AOT_OPTIMIZER_H_ 6 #define VM_AOT_OPTIMIZER_H_
7 7
8 #include "vm/intermediate_language.h" 8 #include "vm/intermediate_language.h"
9 #include "vm/flow_graph.h" 9 #include "vm/flow_graph.h"
10 10
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 const ICData& TrySpecializeICData(const ICData& ic_data, intptr_t cid); 63 const ICData& TrySpecializeICData(const ICData& ic_data, intptr_t cid);
64 64
65 bool TryReplaceWithIndexedOp(InstanceCallInstr* call); 65 bool TryReplaceWithIndexedOp(InstanceCallInstr* call);
66 66
67 bool TryReplaceWithBinaryOp(InstanceCallInstr* call, Token::Kind op_kind); 67 bool TryReplaceWithBinaryOp(InstanceCallInstr* call, Token::Kind op_kind);
68 bool TryReplaceWithUnaryOp(InstanceCallInstr* call, Token::Kind op_kind); 68 bool TryReplaceWithUnaryOp(InstanceCallInstr* call, Token::Kind op_kind);
69 69
70 bool TryReplaceWithEqualityOp(InstanceCallInstr* call, Token::Kind op_kind); 70 bool TryReplaceWithEqualityOp(InstanceCallInstr* call, Token::Kind op_kind);
71 bool TryReplaceWithRelationalOp(InstanceCallInstr* call, Token::Kind op_kind); 71 bool TryReplaceWithRelationalOp(InstanceCallInstr* call, Token::Kind op_kind);
72 72
73 bool TryInlineFieldAccess(InstanceCallInstr* call);
73 bool TryInlineInstanceGetter(InstanceCallInstr* call); 74 bool TryInlineInstanceGetter(InstanceCallInstr* call);
74 bool TryInlineInstanceSetter(InstanceCallInstr* call, 75 bool TryInlineInstanceSetter(InstanceCallInstr* call,
75 const ICData& unary_ic_data); 76 const ICData& unary_ic_data);
76 77
77 bool TryInlineInstanceMethod(InstanceCallInstr* call);
78 bool TryInlineFloat32x4Constructor(StaticCallInstr* call, 78 bool TryInlineFloat32x4Constructor(StaticCallInstr* call,
79 MethodRecognizer::Kind recognized_kind); 79 MethodRecognizer::Kind recognized_kind);
80 bool TryInlineFloat64x2Constructor(StaticCallInstr* call, 80 bool TryInlineFloat64x2Constructor(StaticCallInstr* call,
81 MethodRecognizer::Kind recognized_kind); 81 MethodRecognizer::Kind recognized_kind);
82 bool TryInlineInt32x4Constructor(StaticCallInstr* call, 82 bool TryInlineInt32x4Constructor(StaticCallInstr* call,
83 MethodRecognizer::Kind recognized_kind); 83 MethodRecognizer::Kind recognized_kind);
84 bool TryInlineFloat32x4Method(InstanceCallInstr* call, 84 bool TryInlineFloat32x4Method(InstanceCallInstr* call,
85 MethodRecognizer::Kind recognized_kind); 85 MethodRecognizer::Kind recognized_kind);
86 bool TryInlineFloat64x2Method(InstanceCallInstr* call, 86 bool TryInlineFloat64x2Method(InstanceCallInstr* call,
87 MethodRecognizer::Kind recognized_kind); 87 MethodRecognizer::Kind recognized_kind);
88 bool TryInlineInt32x4Method(InstanceCallInstr* call, 88 bool TryInlineInt32x4Method(InstanceCallInstr* call,
89 MethodRecognizer::Kind recognized_kind); 89 MethodRecognizer::Kind recognized_kind);
90 void ReplaceWithInstanceOf(InstanceCallInstr* instr); 90 void ReplaceWithInstanceOf(InstanceCallInstr* instr);
91 bool TypeCheckAsClassEquality(const AbstractType& type); 91 bool TypeCheckAsClassEquality(const AbstractType& type);
92 void ReplaceWithTypeCast(InstanceCallInstr* instr); 92 void ReplaceWithTypeCast(InstanceCallInstr* instr);
93 93
94 bool TryReplaceInstanceCallWithInline(InstanceCallInstr* call);
95
96 // Insert a check of 'to_check' determined by 'unary_checks'. If the 94 // Insert a check of 'to_check' determined by 'unary_checks'. If the
97 // check fails it will deoptimize to 'deopt_id' using the deoptimization 95 // check fails it will deoptimize to 'deopt_id' using the deoptimization
98 // environment 'deopt_environment'. The check is inserted immediately 96 // environment 'deopt_environment'. The check is inserted immediately
99 // before 'insert_before'. 97 // before 'insert_before'.
100 void AddCheckClass(Definition* to_check, 98 void AddCheckClass(Definition* to_check,
101 const ICData& unary_checks, 99 const ICData& unary_checks,
102 intptr_t deopt_id, 100 intptr_t deopt_id,
103 Environment* deopt_environment, 101 Environment* deopt_environment,
104 Instruction* insert_before); 102 Instruction* insert_before);
105 Instruction* GetCheckClass(Definition* to_check, 103 Instruction* GetCheckClass(Definition* to_check,
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
171 169
172 GrowableArray<intptr_t>* inlining_black_list_; 170 GrowableArray<intptr_t>* inlining_black_list_;
173 171
174 DISALLOW_COPY_AND_ASSIGN(AotOptimizer); 172 DISALLOW_COPY_AND_ASSIGN(AotOptimizer);
175 }; 173 };
176 174
177 175
178 } // namespace dart 176 } // namespace dart
179 177
180 #endif // VM_AOT_OPTIMIZER_H_ 178 #endif // VM_AOT_OPTIMIZER_H_
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/aot_optimizer.cc » ('j') | runtime/vm/aot_optimizer.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698