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

Unified Diff: runtime/vm/locations.cc

Issue 401683003: Specialize mint shift code on arm for a constant shift amount. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/locations.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/locations.cc
===================================================================
--- runtime/vm/locations.cc (revision 38346)
+++ runtime/vm/locations.cc (working copy)
@@ -84,6 +84,14 @@
}
+Location Location::WritableRegisterOrSmiConstant(Value* value) {
+ ConstantInstr* constant = value->definition()->AsConstant();
+ return ((constant != NULL) && Assembler::IsSafeSmi(constant->value()))
+ ? Location::Constant(constant->value())
+ : Location::WritableRegister();
+}
+
+
Location Location::FixedRegisterOrConstant(Value* value, Register reg) {
ConstantInstr* constant = value->definition()->AsConstant();
return ((constant != NULL) && Assembler::IsSafe(constant->value()))
« no previous file with comments | « runtime/vm/locations.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698