[mlir] Add additional traits to EqualOp and NotEqualOp.

This matches the traits of the other binary ops.

Differential Revision: https://reviews.llvm.org/D102916
This commit is contained in:
Adrian Kuegel 2021-05-21 15:00:56 +02:00
parent 35a7c4b4b1
commit 28844212fe
1 changed files with 6 additions and 2 deletions

View File

@ -152,7 +152,9 @@ def ImOp : Complex_Op<"im",
//===----------------------------------------------------------------------===//
def EqualOp : Complex_Op<"eq",
[NoSideEffect, AllTypesMatch<["lhs", "rhs"]>]> {
[NoSideEffect, AllTypesMatch<["lhs", "rhs"]>,
DeclareOpInterfaceMethods<VectorUnrollOpInterface>] #
ElementwiseMappable.traits> {
let summary = "computes whether two complex values are equal";
let description = [{
The `eq` op takes two complex numbers and returns whether they are equal.
@ -194,7 +196,9 @@ def MulOp : ComplexArithmeticOp<"mul"> {
//===----------------------------------------------------------------------===//
def NotEqualOp : Complex_Op<"neq",
[NoSideEffect, AllTypesMatch<["lhs", "rhs"]>]> {
[NoSideEffect, AllTypesMatch<["lhs", "rhs"]>,
DeclareOpInterfaceMethods<VectorUnrollOpInterface>] #
ElementwiseMappable.traits> {
let summary = "computes whether two complex values are not equal";
let description = [{
The `neq` op takes two complex numbers and returns whether they are not