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

Unified Diff: sdk/lib/_internal/compiler/implementation/ssa/nodes.dart

Issue 256453004: Avoid inlining constants that are used via a deferred import. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Use intermediate constants. Created 6 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: sdk/lib/_internal/compiler/implementation/ssa/nodes.dart
diff --git a/sdk/lib/_internal/compiler/implementation/ssa/nodes.dart b/sdk/lib/_internal/compiler/implementation/ssa/nodes.dart
index ad006f8a43bc919bfeccba29bd739bc6395bd0eb..2476e29d59b8e56760fed9f692451d5e5f6f35d4 100644
--- a/sdk/lib/_internal/compiler/implementation/ssa/nodes.dart
+++ b/sdk/lib/_internal/compiler/implementation/ssa/nodes.dart
@@ -184,6 +184,13 @@ class HGraph {
return result;
}
+ HConstant addDeferredConstant(Constant constant, PrefixElement prefix, Compiler compiler) {
Johnni Winther 2014/04/28 11:58:31 Long line.
sigurdm 2014/04/28 12:07:48 Done.
+ Constant wrapper = new DeferredConstant(constant,
+ prefix);
Johnni Winther 2014/04/28 11:58:31 Put this on one line.
sigurdm 2014/04/28 12:07:48 Done.
+ compiler.deferredLoadTask.registerConstantDeferredUse(wrapper, prefix);
+ return addConstant(wrapper, compiler);
+ }
+
HConstant addConstantInt(int i, Compiler compiler) {
return addConstant(compiler.backend.constantSystem.createInt(i), compiler);
}

Powered by Google App Engine
This is Rietveld 408576698