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

Unified Diff: runtime/vm/intermediate_language.cc

Issue 1263573010: Use zone when allocating handles in FlowGraphCompiler assembling operations. Add profiling VM tags… (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: sync Created 5 years, 4 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
« no previous file with comments | « runtime/vm/intermediate_language.h ('k') | runtime/vm/parser.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/intermediate_language.cc
diff --git a/runtime/vm/intermediate_language.cc b/runtime/vm/intermediate_language.cc
index 1ba2c3f1992448e16255c9808d30d9407a3a3987..d05c601b87d7ae16473d35ed8491142a97f88521 100644
--- a/runtime/vm/intermediate_language.cc
+++ b/runtime/vm/intermediate_language.cc
@@ -49,7 +49,19 @@ Definition::Definition(intptr_t deopt_id)
ssa_temp_index_(-1),
input_use_list_(NULL),
env_use_list_(NULL),
- constant_value_(Object::ZoneHandle(ConstantPropagator::Unknown())) {
+ constant_value_(NULL) {
+}
+
+
+// A value in the constant propagation lattice.
+// - non-constant sentinel
+// - a constant (any non-sentinel value)
+// - unknown sentinel
+Object& Definition::constant_value() {
+ if (constant_value_ == NULL) {
+ constant_value_ = &Object::ZoneHandle(ConstantPropagator::Unknown());
+ }
+ return *constant_value_;
}
« no previous file with comments | « runtime/vm/intermediate_language.h ('k') | runtime/vm/parser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698