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

Unified Diff: runtime/vm/kernel_to_il.cc

Issue 2781313003: Add kernel_offset to all expressions; Make KernelConstMapKeyEqualsTraits use kernel_offset (Closed)
Patch Set: Removed debug printf Created 3 years, 9 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/kernel_to_il.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/kernel_to_il.cc
diff --git a/runtime/vm/kernel_to_il.cc b/runtime/vm/kernel_to_il.cc
index 990a4b7c411c9b5d458bc664f043408eb087a372..4ef5572e973ebd63ed0a80213a3a9027e95e872a 100644
--- a/runtime/vm/kernel_to_il.cc
+++ b/runtime/vm/kernel_to_il.cc
@@ -1484,7 +1484,7 @@ bool ConstantEvaluator::GetCachedConstant(TreeNode* node, Instance* value) {
return false;
}
KernelConstantsMap constants(script_.compile_time_constants());
- *value ^= constants.GetOrNull(node, &is_present);
+ *value ^= constants.GetOrNull(node->kernel_offset(), &is_present);
// Mutator compiler thread may add constants while background compiler
// is running, and thus change the value of 'compile_time_constants';
// do not assert that 'compile_time_constants' has not changed.
@@ -1516,7 +1516,7 @@ void ConstantEvaluator::CacheConstantValue(TreeNode* node,
script_.set_compile_time_constants(array);
}
KernelConstantsMap constants(script_.compile_time_constants());
- constants.InsertNewOrGetValue(node, value);
+ constants.InsertNewOrGetValue(node->kernel_offset(), value);
script_.set_compile_time_constants(constants.Release());
}
« no previous file with comments | « runtime/vm/kernel_to_il.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698