Optimizing: Clean up Equal/NotEqual constant folding for nulls.
Change-Id: I17766395092ec61df61ef0b9ae4c37fd38164a3b
diff --git a/compiler/optimizing/nodes.h b/compiler/optimizing/nodes.h
index 7ea6176..a7bd31e 100644
--- a/compiler/optimizing/nodes.h
+++ b/compiler/optimizing/nodes.h
@@ -2692,7 +2692,7 @@
}
HConstant* Evaluate(HNullConstant* x ATTRIBUTE_UNUSED,
HNullConstant* y ATTRIBUTE_UNUSED) const OVERRIDE {
- return GetBlock()->GetGraph()->GetConstant(GetType(), 1);
+ return GetBlock()->GetGraph()->GetIntConstant(1);
}
DECLARE_INSTRUCTION(Equal);
@@ -2728,7 +2728,7 @@
}
HConstant* Evaluate(HNullConstant* x ATTRIBUTE_UNUSED,
HNullConstant* y ATTRIBUTE_UNUSED) const OVERRIDE {
- return GetBlock()->GetGraph()->GetConstant(GetType(), 0);
+ return GetBlock()->GetGraph()->GetIntConstant(0);
}
DECLARE_INSTRUCTION(NotEqual);