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

Unified Diff: test/cctest/compiler/test-js-typed-lowering.cc

Issue 2228983002: [turbofan] Simplify BinaryOperationHints and CompareOperationHints. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix compile for realz Created 4 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 | « src/ic/ic-state.h ('k') | test/unittests/compiler/js-typed-lowering-unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/compiler/test-js-typed-lowering.cc
diff --git a/test/cctest/compiler/test-js-typed-lowering.cc b/test/cctest/compiler/test-js-typed-lowering.cc
index 039533f849057b2dcb757e14152a857ac1ab9fba..88cd6c663c1aaf379025012d54351151ed4f694a 100644
--- a/test/cctest/compiler/test-js-typed-lowering.cc
+++ b/test/cctest/compiler/test-js-typed-lowering.cc
@@ -51,8 +51,8 @@ class JSTypedLoweringTester : public HandleAndZoneScope {
Typer typer;
Node* context_node;
JSTypedLowering::Flags flags;
- BinaryOperationHints const binop_hints = BinaryOperationHints::Any();
- CompareOperationHints const compare_hints = CompareOperationHints::Any();
+ BinaryOperationHint const binop_hints = BinaryOperationHint::kAny;
+ CompareOperationHint const compare_hints = CompareOperationHint::kAny;
Node* Parameter(Type* t, int32_t index = 0) {
Node* n = graph.NewNode(common.Parameter(index), graph.start());
@@ -247,7 +247,7 @@ TEST(AddNumber1) {
for (size_t i = 0; i < arraysize(kNumberTypes); ++i) {
Node* p0 = R.Parameter(kNumberTypes[i], 0);
Node* p1 = R.Parameter(kNumberTypes[i], 1);
- Node* add = R.Binop(R.javascript.Add(BinaryOperationHints::Any()), p0, p1);
+ Node* add = R.Binop(R.javascript.Add(BinaryOperationHint::kAny), p0, p1);
Node* r = R.reduce(add);
R.CheckBinop(IrOpcode::kNumberAdd, r);
@@ -575,13 +575,13 @@ TEST(StringComparison) {
JSTypedLoweringTester R;
const Operator* ops[] = {
- R.javascript.LessThan(CompareOperationHints::Any()),
+ R.javascript.LessThan(CompareOperationHint::kAny),
R.simplified.StringLessThan(),
- R.javascript.LessThanOrEqual(CompareOperationHints::Any()),
+ R.javascript.LessThanOrEqual(CompareOperationHint::kAny),
R.simplified.StringLessThanOrEqual(),
- R.javascript.GreaterThan(CompareOperationHints::Any()),
+ R.javascript.GreaterThan(CompareOperationHint::kAny),
R.simplified.StringLessThan(),
- R.javascript.GreaterThanOrEqual(CompareOperationHints::Any()),
+ R.javascript.GreaterThanOrEqual(CompareOperationHint::kAny),
R.simplified.StringLessThanOrEqual()};
for (size_t i = 0; i < arraysize(kStringTypes); i++) {
@@ -623,13 +623,13 @@ TEST(NumberComparison) {
JSTypedLoweringTester R;
const Operator* ops[] = {
- R.javascript.LessThan(CompareOperationHints::Any()),
+ R.javascript.LessThan(CompareOperationHint::kAny),
R.simplified.NumberLessThan(),
- R.javascript.LessThanOrEqual(CompareOperationHints::Any()),
+ R.javascript.LessThanOrEqual(CompareOperationHint::kAny),
R.simplified.NumberLessThanOrEqual(),
- R.javascript.GreaterThan(CompareOperationHints::Any()),
+ R.javascript.GreaterThan(CompareOperationHint::kAny),
R.simplified.NumberLessThan(),
- R.javascript.GreaterThanOrEqual(CompareOperationHints::Any()),
+ R.javascript.GreaterThanOrEqual(CompareOperationHint::kAny),
R.simplified.NumberLessThanOrEqual()};
Node* const p0 = R.Parameter(Type::Number(), 0);
@@ -665,7 +665,7 @@ TEST(MixedComparison1) {
Node* p1 = R.Parameter(types[j], 1);
{
const Operator* less_than =
- R.javascript.LessThan(CompareOperationHints::Any());
+ R.javascript.LessThan(CompareOperationHint::kAny);
Node* cmp = R.Binop(less_than, p0, p1);
Node* r = R.reduce(cmp);
if (types[i]->Is(Type::String()) && types[j]->Is(Type::String())) {
@@ -811,8 +811,8 @@ void CheckEqualityReduction(JSTypedLoweringTester* R, bool strict, Node* l,
{
const Operator* op =
- strict ? R->javascript.StrictEqual(CompareOperationHints::Any())
- : R->javascript.Equal(CompareOperationHints::Any());
+ strict ? R->javascript.StrictEqual(CompareOperationHint::kAny)
+ : R->javascript.Equal(CompareOperationHint::kAny);
Node* eq = R->Binop(op, p0, p1);
Node* r = R->reduce(eq);
R->CheckBinop(expected, r);
@@ -820,8 +820,8 @@ void CheckEqualityReduction(JSTypedLoweringTester* R, bool strict, Node* l,
{
const Operator* op =
- strict ? R->javascript.StrictNotEqual(CompareOperationHints::Any())
- : R->javascript.NotEqual(CompareOperationHints::Any());
+ strict ? R->javascript.StrictNotEqual(CompareOperationHint::kAny)
+ : R->javascript.NotEqual(CompareOperationHint::kAny);
Node* ne = R->Binop(op, p0, p1);
Node* n = R->reduce(ne);
CHECK_EQ(IrOpcode::kBooleanNot, n->opcode());
« no previous file with comments | « src/ic/ic-state.h ('k') | test/unittests/compiler/js-typed-lowering-unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698