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

Unified Diff: runtime/vm/flow_graph_compiler.cc

Issue 1411873005: Start remove dependencies on compiler-related files. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: removed some unnecessry includes Created 5 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/flow_graph_compiler.h ('k') | runtime/vm/intermediate_language.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/flow_graph_compiler.cc
diff --git a/runtime/vm/flow_graph_compiler.cc b/runtime/vm/flow_graph_compiler.cc
index 4c6b4b7f32cd63a9a9bb35b52d880fb34838d7d1..485e00fc55d0dfb7c7db73696ba17cdc2b965b7c 100644
--- a/runtime/vm/flow_graph_compiler.cc
+++ b/runtime/vm/flow_graph_compiler.cc
@@ -227,6 +227,27 @@ FlowGraphCompiler::FlowGraphCompiler(
}
+bool FlowGraphCompiler::IsUnboxedField(const Field& field) {
+ bool valid_class = (SupportsUnboxedDoubles() &&
+ (field.guarded_cid() == kDoubleCid)) ||
+ (SupportsUnboxedSimd128() &&
+ (field.guarded_cid() == kFloat32x4Cid)) ||
+ (SupportsUnboxedSimd128() &&
+ (field.guarded_cid() == kFloat64x2Cid));
+ return field.is_unboxing_candidate()
+ && !field.is_final()
+ && !field.is_nullable()
+ && valid_class;
+}
+
+
+bool FlowGraphCompiler::IsPotentialUnboxedField(const Field& field) {
+ return field.is_unboxing_candidate() &&
+ (FlowGraphCompiler::IsUnboxedField(field) ||
+ (!field.is_final() && (field.guarded_cid() == kIllegalCid)));
+}
+
+
void FlowGraphCompiler::InitCompiler() {
pc_descriptors_list_ = new(zone()) DescriptorList(64);
exception_handlers_list_ = new(zone())ExceptionHandlerList();
« no previous file with comments | « runtime/vm/flow_graph_compiler.h ('k') | runtime/vm/intermediate_language.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698