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

Unified Diff: src/compiler/machine-operator.h

Issue 531093002: Lower simplified StringLessThan[OrEqual] to runtime call. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebased Created 6 years, 3 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 | « no previous file | src/compiler/simplified-lowering.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/machine-operator.h
diff --git a/src/compiler/machine-operator.h b/src/compiler/machine-operator.h
index 9119ed6576fbaf3b39d0b97a2e928c85b75bda90..62d1ef0ffd0fa85323a471751cb97aed050e5879 100644
--- a/src/compiler/machine-operator.h
+++ b/src/compiler/machine-operator.h
@@ -60,6 +60,7 @@ class MachineOperatorBuilder {
#define UNOP(name) SIMPLE(name, Operator::kPure, 1, 1)
#define WORD_SIZE(x) return is64() ? Word64##x() : Word32##x()
+#define INT_SIZE(x) return is64() ? Int64##x() : Int32##x()
Operator* Load(MachineType rep) { // load [base + index]
OP1(Load, MachineType, rep, Operator::kNoWrite, 2, 1);
@@ -121,6 +122,11 @@ class MachineOperatorBuilder {
Operator* Int64LessThan() { BINOP(Int64LessThan); }
Operator* Int64LessThanOrEqual() { BINOP(Int64LessThanOrEqual); }
+ // Signed comparison of word-sized integer values, translates to int32/int64
+ // comparisons depending on the word-size of the machine.
+ Operator* IntLessThan() { INT_SIZE(LessThan); }
+ Operator* IntLessThanOrEqual() { INT_SIZE(LessThanOrEqual); }
+
// Convert representation of integers between float64 and int32/uint32.
// The precise rounding mode and handling of out of range inputs are *not*
// defined for these operators, since they are intended only for use with
@@ -157,6 +163,7 @@ class MachineOperatorBuilder {
inline MachineType word() const { return word_; }
#undef WORD_SIZE
+#undef INT_SIZE
#undef UNOP
#undef BINOP
#undef OP1
« no previous file with comments | « no previous file | src/compiler/simplified-lowering.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698