Rename Broadcastable to ResultBroadcastableShape
NFC renaming change to reflect upstream change which documents clearer that the constraint is not just on operands but on result too. PiperOrigin-RevId: 291179337 Change-Id: Ia9339a68aec7c6c2984e41dee5b4cbcd9728f581
This commit is contained in:
		
							parent
							
								
									649a04fbe9
								
							
						
					
					
						commit
						fae39def8e
					
				@ -360,7 +360,7 @@ an output element, this operation computes \\(y = |x|\\).
 | 
			
		||||
  let hasFolder = 1;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TFL_AddOp : TFL_Op<"add", [Broadcastable, NoSideEffect, Commutative]> {
 | 
			
		||||
def TFL_AddOp : TFL_Op<"add", [ResultsBroadcastableShape, NoSideEffect, Commutative]> {
 | 
			
		||||
  let summary = "Addition operator";
 | 
			
		||||
 | 
			
		||||
  let description = [{
 | 
			
		||||
@ -763,9 +763,9 @@ def TFL_GatherNdOp : TFL_Op<"gather_nd", [NoSideEffect]> {
 | 
			
		||||
  );
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
// Same type check of lhs and rhs is handled by the Broadcastable trait.
 | 
			
		||||
// Same type check of lhs and rhs is handled by the ResultsBroadcastableShape trait.
 | 
			
		||||
def TFL_LessEqualOp : TFL_Op<"less_equal", [
 | 
			
		||||
    Broadcastable, NoSideEffect, NoQuantizableResult]> {
 | 
			
		||||
    ResultsBroadcastableShape, NoSideEffect, NoQuantizableResult]> {
 | 
			
		||||
  let summary = "Less_equal operator";
 | 
			
		||||
 | 
			
		||||
  let description = [{
 | 
			
		||||
@ -821,7 +821,7 @@ convolutional neural networks (NIPS 2012)](http://papers.nips.cc/paper/4824-imag
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TFL_GreaterEqualOp : TFL_Op<"greater_equal", [
 | 
			
		||||
    Broadcastable, NoSideEffect, NoQuantizableResult]> {
 | 
			
		||||
    ResultsBroadcastableShape, NoSideEffect, NoQuantizableResult]> {
 | 
			
		||||
  let summary = "Greater_equal operator";
 | 
			
		||||
 | 
			
		||||
  let description = [{
 | 
			
		||||
@ -982,7 +982,7 @@ larger than 0.
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TFL_NotEqualOp : TFL_Op<"not_equal", [
 | 
			
		||||
    Broadcastable, Commutative, NoSideEffect, NoQuantizableResult]> {
 | 
			
		||||
    ResultsBroadcastableShape, Commutative, NoSideEffect, NoQuantizableResult]> {
 | 
			
		||||
  let summary = "Not_equal operator";
 | 
			
		||||
 | 
			
		||||
  let description = [{
 | 
			
		||||
@ -1009,7 +1009,7 @@ def TFL_NotEqualOp : TFL_Op<"not_equal", [
 | 
			
		||||
  let printer = [{ return mlir::impl::printOneResultOp(getOperation(), p); }];
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TFL_DivOp : TFL_Op<"div", [Broadcastable, NoSideEffect]> {
 | 
			
		||||
def TFL_DivOp : TFL_Op<"div", [ResultsBroadcastableShape, NoSideEffect]> {
 | 
			
		||||
  let summary = "Division operator";
 | 
			
		||||
 | 
			
		||||
  let description = [{
 | 
			
		||||
@ -1068,7 +1068,7 @@ def TFL_EmbeddingLookupOp: TFL_Op<"embedding_lookup",
 | 
			
		||||
  let results = (outs TensorOf<[F32, I8, TFL_Uint8]>:$output);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TFL_EqualOp: TFL_Op<"equal", [Commutative, Broadcastable,
 | 
			
		||||
def TFL_EqualOp: TFL_Op<"equal", [Commutative, ResultsBroadcastableShape,
 | 
			
		||||
    NoQuantizableResult,
 | 
			
		||||
    PredOpTrait<"Operands have same value type", TCopVTEtIsSameAs<0, 1>>]> {
 | 
			
		||||
  let summary = "Equal operator";
 | 
			
		||||
@ -1212,7 +1212,7 @@ def TFL_FloorOp: TFL_Op<"floor", [NoSideEffect, SameOperandsAndResultType]> {
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TFL_FloorDivOp : TFL_Op<"floor_div", [
 | 
			
		||||
    Broadcastable, NoSideEffect, BinaryOpSameElementTypeConstraint]> {
 | 
			
		||||
    ResultsBroadcastableShape, NoSideEffect, BinaryOpSameElementTypeConstraint]> {
 | 
			
		||||
  let summary = "Floor div operator";
 | 
			
		||||
 | 
			
		||||
  let description = [{
 | 
			
		||||
@ -1231,7 +1231,7 @@ def TFL_FloorDivOp : TFL_Op<"floor_div", [
 | 
			
		||||
  let printer = [{ return mlir::impl::printOneResultOp(getOperation(), p); }];
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TFL_FloorModOp : TFL_Op<"floor_mod", [Broadcastable, NoSideEffect]> {
 | 
			
		||||
def TFL_FloorModOp : TFL_Op<"floor_mod", [ResultsBroadcastableShape, NoSideEffect]> {
 | 
			
		||||
  let summary = "Division reminder";
 | 
			
		||||
 | 
			
		||||
  let description = [{
 | 
			
		||||
@ -1248,7 +1248,7 @@ def TFL_FloorModOp : TFL_Op<"floor_mod", [Broadcastable, NoSideEffect]> {
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TFL_GreaterOp : TFL_Op<"greater", [
 | 
			
		||||
    Broadcastable, NoSideEffect, NoQuantizableResult]> {
 | 
			
		||||
    ResultsBroadcastableShape, NoSideEffect, NoQuantizableResult]> {
 | 
			
		||||
  let summary = "Greater operator";
 | 
			
		||||
 | 
			
		||||
  let description = [{
 | 
			
		||||
@ -1330,7 +1330,7 @@ def TFL_LeakyReluOp: TFL_Op<"leaky_relu", [NoSideEffect, SameOperandsAndResultTy
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TFL_LessOp : TFL_Op<"less", [
 | 
			
		||||
    Broadcastable, NoSideEffect, NoQuantizableResult]> {
 | 
			
		||||
    ResultsBroadcastableShape, NoSideEffect, NoQuantizableResult]> {
 | 
			
		||||
  let summary = "Less operator";
 | 
			
		||||
 | 
			
		||||
  let description = [{
 | 
			
		||||
@ -1555,7 +1555,7 @@ def TFL_MaxUnpooling2DOp :
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TFL_MaximumOp : TFL_Op<"maximum", [
 | 
			
		||||
    Broadcastable, NoSideEffect, Commutative, SameOperandsAndResultsScale,
 | 
			
		||||
    ResultsBroadcastableShape, NoSideEffect, Commutative, SameOperandsAndResultsScale,
 | 
			
		||||
    TFL_OperandHasRankLessThan<0, 4>, TFL_OperandHasRankLessThan<1, 4>]> {
 | 
			
		||||
  let summary = "Max operator";
 | 
			
		||||
  let description = [{
 | 
			
		||||
@ -1752,7 +1752,7 @@ def TFL_ReduceProdOp: TFL_Op<"reduce_prod", [NoSideEffect]> {
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TFL_MinimumOp : TFL_Op<"minimum", [
 | 
			
		||||
    Broadcastable, NoSideEffect, Commutative, SameOperandsAndResultsScale,
 | 
			
		||||
    ResultsBroadcastableShape, NoSideEffect, Commutative, SameOperandsAndResultsScale,
 | 
			
		||||
    TFL_OperandHasRankLessThan<0, 4>, TFL_OperandHasRankLessThan<1, 4>]> {
 | 
			
		||||
  let summary = "Min operator";
 | 
			
		||||
  let description = [{
 | 
			
		||||
@ -1773,7 +1773,7 @@ def TFL_MinimumOp : TFL_Op<"minimum", [
 | 
			
		||||
  let hasOptions = 0;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TFL_MulOp : TFL_Op<"mul", [Broadcastable, NoSideEffect, Commutative]> {
 | 
			
		||||
def TFL_MulOp : TFL_Op<"mul", [ResultsBroadcastableShape, NoSideEffect, Commutative]> {
 | 
			
		||||
  let summary = "Multiplication operator";
 | 
			
		||||
 | 
			
		||||
  let description = [{
 | 
			
		||||
@ -1948,7 +1948,7 @@ def TFL_PadV2Op : TFL_Op<"padv2", [
 | 
			
		||||
  let hasOptions = 1;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TFL_PowOp : TFL_Op<"pow", [Broadcastable, NoSideEffect, NoQuantizableResult]> {
 | 
			
		||||
def TFL_PowOp : TFL_Op<"pow", [ResultsBroadcastableShape, NoSideEffect, NoQuantizableResult]> {
 | 
			
		||||
  let summary = "Power operator";
 | 
			
		||||
 | 
			
		||||
  let description = [{
 | 
			
		||||
@ -2317,7 +2317,7 @@ def TFL_SquareOp: TFL_Op<"square", [
 | 
			
		||||
  let hasFolder = 1;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TFL_SubOp : TFL_Op<"sub", [Broadcastable, NoSideEffect]> {
 | 
			
		||||
def TFL_SubOp : TFL_Op<"sub", [ResultsBroadcastableShape, NoSideEffect]> {
 | 
			
		||||
  let summary = "Subtraction operator";
 | 
			
		||||
 | 
			
		||||
  let description = [{
 | 
			
		||||
@ -2345,7 +2345,7 @@ def TFL_SubOp : TFL_Op<"sub", [Broadcastable, NoSideEffect]> {
 | 
			
		||||
// TODO(jpienaar): Expand the kernel implementation to support all types besides
 | 
			
		||||
// I32 and F32.
 | 
			
		||||
def TFL_SquaredDifferenceOp : TFL_Op<"squared_difference", [
 | 
			
		||||
    Broadcastable, NoSideEffect, NoQuantizableResult]> {
 | 
			
		||||
    ResultsBroadcastableShape, NoSideEffect, NoQuantizableResult]> {
 | 
			
		||||
  let summary = "Squared difference operator";
 | 
			
		||||
 | 
			
		||||
  let description = [{
 | 
			
		||||
 | 
			
		||||
@ -49,7 +49,7 @@ an output element, this operation computes \\(y = |x|\\).
 | 
			
		||||
  TF_DerivedOperandTypeAttr T = TF_DerivedOperandTypeAttr<0>;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_AddOp : TF_Op<"Add", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_AddOp : TF_Op<"Add", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
               WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Returns x + y element-wise.";
 | 
			
		||||
 | 
			
		||||
@ -98,7 +98,7 @@ Inputs must be of same size and shape.
 | 
			
		||||
  let hasFolder = 1;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_AddV2Op : TF_Op<"AddV2", [Broadcastable, Commutative, NoSideEffect]>,
 | 
			
		||||
def TF_AddV2Op : TF_Op<"AddV2", [ResultsBroadcastableShape, Commutative, NoSideEffect]>,
 | 
			
		||||
                 WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Returns x + y element-wise.";
 | 
			
		||||
 | 
			
		||||
@ -582,7 +582,7 @@ endian orderings will give different results.
 | 
			
		||||
  let hasCanonicalizer = 1;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_BitwiseOrOp : TF_Op<"BitwiseOr", [Broadcastable, Commutative, NoSideEffect]>,
 | 
			
		||||
def TF_BitwiseOrOp : TF_Op<"BitwiseOr", [ResultsBroadcastableShape, Commutative, NoSideEffect]>,
 | 
			
		||||
                     WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Elementwise computes the bitwise OR of `x` and `y`.";
 | 
			
		||||
 | 
			
		||||
@ -743,7 +743,7 @@ that are not a number (NaN) or infinity (Inf). Otherwise, passes `tensor` as-is.
 | 
			
		||||
  TF_DerivedOperandTypeAttr T = TF_DerivedOperandTypeAttr<0>;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_ComplexOp : TF_Op<"Complex", [Broadcastable, NoSideEffect]> {
 | 
			
		||||
def TF_ComplexOp : TF_Op<"Complex", [ResultsBroadcastableShape, NoSideEffect]> {
 | 
			
		||||
  let summary = "Converts two real numbers to a complex number.";
 | 
			
		||||
 | 
			
		||||
  let description = [{
 | 
			
		||||
@ -1259,7 +1259,7 @@ horizontal and vertices strides, `strides = [1, stride, stride, 1]`.
 | 
			
		||||
  TF_DerivedOperandTypeAttr T = TF_DerivedOperandTypeAttr<0>;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_DivOp : TF_Op<"Div", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_DivOp : TF_Op<"Div", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
               WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Returns x / y element-wise.";
 | 
			
		||||
 | 
			
		||||
@ -1282,7 +1282,7 @@ def TF_DivOp : TF_Op<"Div", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
  let hasCanonicalizer = 1;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_DivNoNanOp : TF_Op<"DivNoNan", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_DivNoNanOp : TF_Op<"DivNoNan", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
                    WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Returns 0 if the denominator is zero.";
 | 
			
		||||
 | 
			
		||||
@ -1844,7 +1844,7 @@ def TF_FloorOp : TF_Op<"Floor", [NoSideEffect, SameOperandsAndResultType]> {
 | 
			
		||||
  TF_DerivedOperandTypeAttr T = TF_DerivedOperandTypeAttr<0>;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_FloorDivOp : TF_Op<"FloorDiv", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_FloorDivOp : TF_Op<"FloorDiv", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
                    WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Returns x // y element-wise.";
 | 
			
		||||
 | 
			
		||||
@ -1865,7 +1865,7 @@ def TF_FloorDivOp : TF_Op<"FloorDiv", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
  TF_DerivedOperandTypeAttr T = TF_DerivedOperandTypeAttr<0>;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_FloorModOp : TF_Op<"FloorMod", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_FloorModOp : TF_Op<"FloorMod", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
                    WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = [{
 | 
			
		||||
Returns element-wise remainder of division. When `x < 0` xor `y < 0` is
 | 
			
		||||
@ -2282,7 +2282,7 @@ See also `tf.batch_gather` and `tf.gather_nd`.
 | 
			
		||||
  }];
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_GreaterOp : TF_Op<"Greater", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_GreaterOp : TF_Op<"Greater", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
                   WithBroadcastableCmpOpBuilder {
 | 
			
		||||
  let summary = "Returns the truth value of (x > y) element-wise.";
 | 
			
		||||
 | 
			
		||||
@ -2315,7 +2315,7 @@ tf.math.greater(x, y) ==> [False, False, True]
 | 
			
		||||
  TF_DerivedOperandTypeAttr T = TF_DerivedOperandTypeAttr<0>;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_GreaterEqualOp : TF_Op<"GreaterEqual", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_GreaterEqualOp : TF_Op<"GreaterEqual", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
                        WithBroadcastableCmpOpBuilder {
 | 
			
		||||
  let summary = "Returns the truth value of (x >= y) element-wise.";
 | 
			
		||||
 | 
			
		||||
@ -2646,7 +2646,7 @@ def TF_LeakyReluOp : TF_Op<"LeakyRelu", [NoSideEffect, SameOperandsAndResultType
 | 
			
		||||
  let hasFolder = 1;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_LeftShiftOp : TF_Op<"LeftShift", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_LeftShiftOp : TF_Op<"LeftShift", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
                     WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Elementwise computes the bitwise left-shift of `x` and `y`.";
 | 
			
		||||
 | 
			
		||||
@ -2695,7 +2695,7 @@ bitwise_ops.left_shift(lhs, rhs)
 | 
			
		||||
  TF_DerivedOperandTypeAttr T = TF_DerivedOperandTypeAttr<0>;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_LessOp : TF_Op<"Less", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_LessOp : TF_Op<"Less", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
                WithBroadcastableCmpOpBuilder {
 | 
			
		||||
  let summary = "Returns the truth value of (x < y) element-wise.";
 | 
			
		||||
 | 
			
		||||
@ -2728,7 +2728,7 @@ tf.math.less(x, y) ==> [False, True, True]
 | 
			
		||||
  TF_DerivedOperandTypeAttr T = TF_DerivedOperandTypeAttr<0>;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_LessEqualOp : TF_Op<"LessEqual", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_LessEqualOp : TF_Op<"LessEqual", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
                     WithBroadcastableCmpOpBuilder {
 | 
			
		||||
  let summary = "Returns the truth value of (x <= y) element-wise.";
 | 
			
		||||
 | 
			
		||||
@ -2833,7 +2833,7 @@ For each batch `i` and class `j` we have
 | 
			
		||||
  TF_DerivedOperandTypeAttr T = TF_DerivedOperandTypeAttr<0>;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_LogicalAndOp : TF_Op<"LogicalAnd", [Broadcastable, Commutative, NoSideEffect]>,
 | 
			
		||||
def TF_LogicalAndOp : TF_Op<"LogicalAnd", [ResultsBroadcastableShape, Commutative, NoSideEffect]>,
 | 
			
		||||
                      WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Returns the truth value of x AND y element-wise.";
 | 
			
		||||
 | 
			
		||||
@ -2869,7 +2869,7 @@ def TF_LogicalNotOp : TF_Op<"LogicalNot", [NoSideEffect, SameOperandsAndResultTy
 | 
			
		||||
  let hasCanonicalizer = 1;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_LogicalOrOp : TF_Op<"LogicalOr", [Broadcastable, Commutative, NoSideEffect]>,
 | 
			
		||||
def TF_LogicalOrOp : TF_Op<"LogicalOr", [ResultsBroadcastableShape, Commutative, NoSideEffect]>,
 | 
			
		||||
                     WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Returns the truth value of x OR y element-wise.";
 | 
			
		||||
 | 
			
		||||
@ -3485,7 +3485,7 @@ def TF_MaxPoolGradOp : TF_Op<"MaxPoolGrad", [NoSideEffect]> {
 | 
			
		||||
  }];
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_MaximumOp : TF_Op<"Maximum", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_MaximumOp : TF_Op<"Maximum", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
                   WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Returns the max of x and y (i.e. x > y ? x : y) element-wise.";
 | 
			
		||||
 | 
			
		||||
@ -3533,7 +3533,7 @@ retained with length 1.
 | 
			
		||||
  TF_DerivedOperandTypeAttr Tidx = TF_DerivedOperandTypeAttr<1>;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_MinimumOp : TF_Op<"Minimum", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_MinimumOp : TF_Op<"Minimum", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
                   WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Returns the min of x and y (i.e. x < y ? x : y) element-wise.";
 | 
			
		||||
 | 
			
		||||
@ -3651,7 +3651,7 @@ graph_def = foo.get_concrete_function(tf.TensorSpec([10], tf.float32), tf.Tensor
 | 
			
		||||
  TF_DerivedResultTypeListAttr Toutputs = TF_DerivedResultTypeListAttr<0>;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_MulOp : TF_Op<"Mul", [Broadcastable, Commutative, NoSideEffect]>,
 | 
			
		||||
def TF_MulOp : TF_Op<"Mul", [ResultsBroadcastableShape, Commutative, NoSideEffect]>,
 | 
			
		||||
               WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Returns x * y element-wise.";
 | 
			
		||||
 | 
			
		||||
@ -3672,7 +3672,7 @@ def TF_MulOp : TF_Op<"Mul", [Broadcastable, Commutative, NoSideEffect]>,
 | 
			
		||||
  TF_DerivedOperandTypeAttr T = TF_DerivedOperandTypeAttr<0>;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_MulNoNanOp : TF_Op<"MulNoNan", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_MulNoNanOp : TF_Op<"MulNoNan", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
                    WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = [{
 | 
			
		||||
Returns x * y element-wise. Returns zero if y is zero, even if x if infinite or NaN.
 | 
			
		||||
@ -4116,7 +4116,7 @@ pad(t, paddings) ==> [[0, 0, 0, 0, 0, 0]
 | 
			
		||||
  TF_DerivedOperandTypeAttr Tpaddings = TF_DerivedOperandTypeAttr<1>;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_PowOp : TF_Op<"Pow", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_PowOp : TF_Op<"Pow", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
               WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Computes the power of one value to another.";
 | 
			
		||||
 | 
			
		||||
@ -4531,7 +4531,7 @@ tf.real(input) ==> [-2.25, 3.25]
 | 
			
		||||
  TF_DerivedResultTypeAttr Tout = TF_DerivedResultTypeAttr<0>;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_RealDivOp : TF_Op<"RealDiv", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_RealDivOp : TF_Op<"RealDiv", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
                   WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Returns x / y element-wise for real types.";
 | 
			
		||||
 | 
			
		||||
@ -4981,7 +4981,7 @@ reverse(t, dims) ==> [[[[8, 9, 10, 11],
 | 
			
		||||
  TF_DerivedOperandTypeAttr Tidx = TF_DerivedOperandTypeAttr<1>;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_RightShiftOp : TF_Op<"RightShift", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_RightShiftOp : TF_Op<"RightShift", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
                      WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Elementwise computes the bitwise right-shift of `x` and `y`.";
 | 
			
		||||
 | 
			
		||||
@ -5938,7 +5938,7 @@ I.e., \\(y = x * x = x^2\\).
 | 
			
		||||
  let hasCanonicalizer = 1;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_SquaredDifferenceOp : TF_Op<"SquaredDifference", [Broadcastable, Commutative, NoSideEffect]>,
 | 
			
		||||
def TF_SquaredDifferenceOp : TF_Op<"SquaredDifference", [ResultsBroadcastableShape, Commutative, NoSideEffect]>,
 | 
			
		||||
                             WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Returns (x - y)(x - y) element-wise.";
 | 
			
		||||
 | 
			
		||||
@ -6211,7 +6211,7 @@ shape of `StridedSlice`'s `input`.
 | 
			
		||||
  }];
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_SubOp : TF_Op<"Sub", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_SubOp : TF_Op<"Sub", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
               WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Returns x - y element-wise.";
 | 
			
		||||
 | 
			
		||||
@ -6823,7 +6823,7 @@ The output `y` has the same rank as `x`. The shapes of `x` and `y` satisfy:
 | 
			
		||||
  let hasFolder = 1;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_TruncateDivOp : TF_Op<"TruncateDiv", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_TruncateDivOp : TF_Op<"TruncateDiv", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
                       WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Returns x / y element-wise for integer types.";
 | 
			
		||||
 | 
			
		||||
@ -7232,7 +7232,7 @@ where(input) ==> [[0, 0, 0],
 | 
			
		||||
  TF_DerivedOperandTypeAttr T = TF_DerivedOperandTypeAttr<0>;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def TF_XdivyOp : TF_Op<"Xdivy", [Broadcastable, NoSideEffect]>,
 | 
			
		||||
def TF_XdivyOp : TF_Op<"Xdivy", [ResultsBroadcastableShape, NoSideEffect]>,
 | 
			
		||||
                 WithBroadcastableBinOpBuilder {
 | 
			
		||||
  let summary = "Returns 0 if x == 0, and x / y otherwise, elementwise.";
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user