Add rsqrt and log to lho_ops.td.
PiperOrigin-RevId: 291923512 Change-Id: I17007c579044571e846f764852532c966cc00ce6
This commit is contained in:
parent
d75abdfd35
commit
59dfa21817
@ -88,8 +88,12 @@ def LHLO_CosOp: LHLO_UnaryElementwiseOp<"cos">, BASE_HLO_CosOp;
|
||||
|
||||
def LHLO_ExpOp: LHLO_UnaryElementwiseOp<"exp">, BASE_HLO_ExpOp;
|
||||
|
||||
def LHLO_LogOp: LHLO_UnaryElementwiseOp<"log">, BASE_HLO_LogOp;
|
||||
|
||||
def LHLO_NegOp: LHLO_UnaryElementwiseOp<"neg">, BASE_HLO_NegOp;
|
||||
|
||||
def LHLO_RsqrtOp: LHLO_UnaryElementwiseOp<"rsqrt">, BASE_HLO_RsqrtOp;
|
||||
|
||||
def LHLO_SignOp: LHLO_UnaryElementwiseOp<"sign">, BASE_HLO_SignOp;
|
||||
|
||||
def LHLO_TanhOp: LHLO_UnaryElementwiseOp<"tanh">, BASE_HLO_TanhOp;
|
||||
|
@ -40,6 +40,14 @@ func @exp_memref(%in: memref<10xf32>, %out: memref<10xf32>) -> () {
|
||||
|
||||
// -----
|
||||
|
||||
// CHECK-LABEL: func @log_memref
|
||||
func @log_memref(%in: memref<10xf32>, %out: memref<10xf32>) -> () {
|
||||
"xla_lhlo.log"(%in, %out) : (memref<10xf32>, memref<10xf32>) -> ()
|
||||
return
|
||||
}
|
||||
|
||||
// -----
|
||||
|
||||
// CHECK-LABEL: func @neg_memref
|
||||
func @neg_memref(%in: memref<10xf32>, %out: memref<10xf32>) -> () {
|
||||
"xla_lhlo.neg"(%in, %out) : (memref<10xf32>, memref<10xf32>) -> ()
|
||||
@ -48,6 +56,14 @@ func @neg_memref(%in: memref<10xf32>, %out: memref<10xf32>) -> () {
|
||||
|
||||
// -----
|
||||
|
||||
// CHECK-LABEL: func @rsqrt_memref
|
||||
func @rsqrt_memref(%in: memref<10xf32>, %out: memref<10xf32>) -> () {
|
||||
"xla_lhlo.rsqrt"(%in, %out) : (memref<10xf32>, memref<10xf32>) -> ()
|
||||
return
|
||||
}
|
||||
|
||||
// -----
|
||||
|
||||
// CHECK-LABEL: func @sign_memref
|
||||
func @sign_memref(%in: memref<10xf32>, %out: memref<10xf32>) -> () {
|
||||
"xla_lhlo.sign"(%in, %out) : (memref<10xf32>, memref<10xf32>) -> ()
|
||||
|
Loading…
x
Reference in New Issue
Block a user