Home
last modified time | relevance | path

Searched refs:chlo (Results 1 – 25 of 29) sorted by relevance

12

/external/tensorflow/tensorflow/compiler/mlir/hlo/tests/
Dchlo_legalize_to_hlo_broadcasts.mlir1 // RUN: mlir-hlo-opt -chlo-legalize-to-hlo="broadcast-only=true" -cse -split-input-file -verify-dia…
8 %0 = chlo.broadcast_add %arg0, %arg1 : (tensor<4xf32>, tensor<4xf32>) -> tensor<4xf32>
29 %0 = chlo.broadcast_add %arg0, %arg1 : (tensor<?xf32>, tensor<?x?xf32>) -> tensor<?x?xf32>
50 …%0 = chlo.broadcast_complex %arg0, %arg1 : (tensor<?xf32>, tensor<?x?xf32>) -> tensor<?x?xcomplex<…
71 …%0 = chlo.broadcast_compare %arg0, %arg1 {comparison_direction = "EQ"} : (tensor<?xf32>, tensor<?x…
80 …%0 = chlo.broadcast_add %arg0, %arg1 {broadcast_dimensions = dense<1> : tensor<1xi64>} : (tensor<1…
89 …%0 = chlo.broadcast_add %arg0, %arg1 {broadcast_dimensions = dense<[]> : tensor<0xi64>} : (tensor<…
98 …%0 = chlo.broadcast_add %arg0, %arg1 {broadcast_dimensions = dense<[1, 2]> : tensor<2xi64>} : (ten…
107 …%0 = chlo.broadcast_add %arg0, %arg1 {broadcast_dimensions = dense<2> : tensor<1xi64>} : (tensor<1…
117 %0 = chlo.broadcast_and %arg0, %arg1 : (tensor<4xi1>, tensor<4xi1>) -> tensor<4xi1>
[all …]
Dchlo_infer_shape_type_methods.mlir13 %0 = chlo.broadcast_add %arg0, %arg1 : (tensor<?xf32>, tensor<?xf32>) -> tensor<?xf32>
21 …%0 = chlo.broadcast_complex %arg0, %arg1 : (tensor<?xf32>, tensor<?x?xf32>) -> tensor<?x?xcomplex<…
30 …%0 = chlo.broadcast_compare %arg0, %arg1 {comparison_direction = "EQ"} : (tensor<?xf32>, tensor<?x…
39 %0 = chlo.broadcast_add %arg0, %arg1 : (tensor<?xf32>, tensor<?xf32>) -> tensor<?xf32>
48 %0 = chlo.broadcast_add %arg0, %arg1 : (tensor<?xf32>, tensor<?x3xf32>) -> tensor<?x3xf32>
Dhlo-transform-unranked.mlir93 // CHECK: %[[FLAT_B:.*]] = chlo.tan %[[FLAT_A]] : tensor<?xf32> -> tensor<?xf32>
96 %result = chlo.tan %a : tensor<*xf32> -> tensor<*xf32>
103 %0 = chlo.broadcast_add %arg0, %arg1 : (tensor<f32>, tensor<*xf32>)
118 // CHECK-NEXT: %[[BROADCASTED_RESULT:.*]] = chlo.broadcast_add %[[ARG_0]], %[[RESHAPED]] …
127 %0 = chlo.broadcast_add %arg0, %arg1 : (tensor<*xf32>, tensor<f32>)
142 // CHECK-NEXT: %[[BROADCASTED_RESULT:.*]] = chlo.broadcast_add %[[RESHAPED]], %[[ARG_1]] …
152 %0 = chlo.broadcast_add %arg0, %arg1 : (tensor<*xf32>, tensor<*xf32>)
171 // CHECK-NEXT: %[[LHS_SCALAR_RESULT:.*]] = chlo.broadcast_add %[[SCALAR_LHS]], %[[RESHA…
184 // CHECK-NEXT: %[[RHS_SCALAR_RESULT:.*]] = chlo.broadcast_add %[[RESHAPED_LHS]], %[[S…
216 // CHECK-NEXT: %[[RESULT_RANK_1:.*]] = chlo.broadcast_add %[[RESHAPED_LHS_1]], %[…
[all …]
Dchlo_legalize_to_mhlo.mlir1 // RUN: mlir-hlo-opt --chlo-legalize-to-hlo --split-input-file %s | FileCheck %s
8 %result = "chlo.asinh"(%arg) : (tensor<bf16>) -> tensor<bf16>
17 %result = "chlo.asinh"(%arg) : (tensor<f16>) -> tensor<f16>
26 %result = "chlo.asinh"(%arg) : (tensor<f32>) -> tensor<f32>
74 %result = "chlo.asinh"(%arg) : (tensor<f64>) -> tensor<f64>
83 %result = "chlo.constant_like"(%arg) { value = 3.2 : f32 }
97 %result = "chlo.constant_like"(%arg) { value = 3.2 : f32 }
109 %1 = "chlo.conj"(%arg0) : (tensor<3xcomplex<f32>>) -> tensor<3xcomplex<f32>>
276 %1 = "chlo.erf"(%arg) : (tensor<f64>) -> tensor<f64>
328 %1 = "chlo.erf"(%arg) : (tensor<f32>) -> tensor<f32>
[all …]
/external/tensorflow/tensorflow/compiler/mlir/hlo/lib/Dialect/mhlo/transforms/
Dchlo_legalize_to_hlo_pass.cc47 conversionTarget.addIllegalDialect<chlo::HloClientDialect>(); in runOnFunction()
56 chlo::PopulateChloBroadcastingPatterns(&getContext(), in runOnFunction()
58 conversionTarget.addLegalOp<chlo::ZetaOp, chlo::PolygammaOp>(); in runOnFunction()
60 chlo::PopulateLegalizeChloToHloPatterns(&getContext(), in runOnFunction()
Dchlo_legalize_to_hlo.cc44 namespace chlo { namespace
85 Value poly = chlo::getConstantLike(rewriter, loc, 0.0, x); in MaterializePolynomialApproximation()
89 loc, x.getType(), poly, chlo::getConstantLike(rewriter, loc, c, x)); in MaterializePolynomialApproximation()
156 Value eight = chlo::getConstantLike(rewriter, loc, 8.0, x); in MaterializeErfcApproximationF64ForMagnituteGEOne()
164 loc, z, chlo::getConstantLike(rewriter, loc, -kMaxlog, x), kLT); in MaterializeErfcApproximationF64ForMagnituteGEOne()
165 Value zero = chlo::getConstantLike(rewriter, loc, 0.0, x); in MaterializeErfcApproximationF64ForMagnituteGEOne()
174 Value two = chlo::getConstantLike(rewriter, loc, 2.0, x); in MaterializeErfcApproximationF64ForMagnituteGEOne()
222 Value one = chlo::getConstantLike(rewriter, loc, 1.0, x); in MaterializeErfApproximationF64()
249 Value one = chlo::getConstantLike(rewriter, loc, 1.0, x); in MaterializeErfcApproximationF64()
295 Value one = chlo::getConstantLike(rewriter, loc, 1.0, x); in MaterializeErfcApproximationF32ForMagnitudeGEOne()
[all …]
Dtransform_unranked_hlo.cc481 #define ADD_LEGAL_CHLO(op) AddLegalOpOnRankedTensor<chlo::op>(&target) in runOnFunction()
489 target.addDynamicallyLegalDialect<chlo::HloClientDialect>( in runOnFunction()
512 #define MAP_CHLO(op) ElementwiseOpConversion<chlo::op> in PopulateTransformUnrankedHloPatterns()
526 chlo::PopulateForBroadcastingBinaryOp< in PopulateTransformUnrankedHloPatterns()
528 chlo::PopulateForBroadcastingBinaryOp< in PopulateTransformUnrankedHloPatterns()
/external/tensorflow/tensorflow/compiler/mlir/hlo/include/mlir-hlo/Dialect/mhlo/IR/
Dhlo_utils.td31 "chlo::getConstantLike($_builder, $_loc, " # value # ", $0)">;
34 "chlo::getConstantLikeMaxFiniteValue($_builder, $_loc, $0)">;
37 "chlo::getConstantLikeInfValue($_builder, $_loc, $0, /*negative=*/false)">;
40 "chlo::getConstantLikeInfValue($_builder, $_loc, $0, /*negative=*/true)">;
Dchlo_ops.h33 namespace chlo {
54 namespace chlo {
DCMakeLists.txt27 add_mlir_hlo_dialect(chlo_ops chlo)
Dchlo_ops.td25 // chlo ops to canonical mhlo ops.
39 let name = "chlo";
40 let cppNamespace = "::mlir::chlo";
69 // These correspond to operations in the chlo and mhlo dialects without the
/external/tensorflow/tensorflow/compiler/mlir/tools/kernel_gen/tests/
Dtf-legalize-to-lmhlo.mlir1 // RUN: tf-opt %s --xla-legalize-tf='legalize-chlo=false' | \
2 // RUN: mlir-hlo-opt --transform-unranked-hlo --chlo-legalize-to-hlo --hlo-legalize-to-linalg | \
/external/tensorflow/tensorflow/compiler/mlir/tensorflow/tests/
Dlegalize_hlo.mlir12 …%0 = "chlo.broadcast_add"(%arg0, %arg1) {broadcast_dimensions = dense<3> : tensor<1xi64>} : (tenso…
23 …%0 = "chlo.broadcast_add"(%arg0, %arg1) {broadcast_dimensions = dense<3> : tensor<1xi64>} : (tenso…
34 …%0 = "chlo.broadcast_add"(%arg0, %arg1) {broadcast_dimensions = dense<3> : tensor<1xi64>} : (tenso…
57 …%0 = "chlo.broadcast_add"(%arg0, %arg1) {broadcast_dimensions = dense<1> : tensor<1xi64>} : (tenso…
68 …%0 = "chlo.broadcast_add"(%arg0, %arg1) {broadcast_dimensions = dense<[1, 2, 3]> : tensor<3xi64>} …
73 // CHECK: chlo.broadcast_add
75 …%0 = "chlo.broadcast_add"(%arg0, %arg1) {broadcast_dimensions = dense<[0, 1, 2]> : tensor<3xi64>} …
96 …%0 = "chlo.broadcast_divide"(%arg0, %arg1) {broadcast_dimensions = dense<1> : tensor<1xi64>} : (te…
118 …%0 = "chlo.broadcast_divide"(%arg0, %arg1) {broadcast_dimensions = dense<1> : tensor<1xi64>} : (te…
161 …%0 = "chlo.broadcast_multiply"(%arg0, %arg1) {broadcast_dimensions = dense<1> : tensor<1xi64>} : (…
[all …]
/external/tensorflow/tensorflow/compiler/mlir/xla/tests/
Dlegalize-tf.mlir1 // RUN: tf-opt "-xla-legalize-tf=allow-partial-conversion legalize-chlo=false" %s | FILECHECK_OPTS=…
2 // RUN: tf-opt "-xla-legalize-tf=allow-partial-conversion legalize-chlo=true" -verify-diagnostics %…
4 // 1. Through FILECHECK_OPTS="" FileCheck with chlo legalization disabled since verifying
5 // that the chlo ops emit produces more useful tests.
6 // 2. With chlo legalization enabled, verifying diagnostics to pick up any
47 // CHECK: chlo.broadcast_multiply %[[VAR]], {{.*}} : (tensor<8xf32>, tensor<f32>) -> tensor<8xf32>
79 // CHECK: chlo.broadcast_multiply %[[VAR]], {{.*}} : (tensor<8xf32>, tensor<f32>) -> tensor<8xf32>
100 // CHECK: %[[CORRECTED_VAR:.*]] = chlo.broadcast_multiply %[[BATCH_VAR]], %[[FACTOR]]
105 // CHECK: %[[ALPHA_MUL_OLD_MEAN:.*]] = chlo.broadcast_multiply %[[ALPHA]], %arg3
106 // CHECK: %[[BETA_MUL_BATCH_MEAN:.*]] = chlo.broadcast_multiply %[[BETA]], %[[BATCH_MEAN]]
[all …]
Dlegalize-tf-binary-elementwise.mlir1 // Note that binary elementwise tests are run with chlo legalization enabled
4 // RUN: tf-opt "-xla-legalize-tf=allow-partial-conversion legalize-chlo=true" -canonicalize %s | Fi…
5 // RUN: tf-opt "-xla-legalize-tf=allow-partial-conversion legalize-chlo=false" %s | FileCheck --che…
64 // CHLO: chlo.broadcast_add %arg0, %arg1
268 // CHLO: chlo.broadcast_compare %arg0, %arg1 {comparison_direction = "EQ"}
328 // CHLO: chlo.broadcast_compare %arg0, %arg1 {comparison_direction = "GT"}
/external/tensorflow/tensorflow/compiler/mlir/hlo/lib/Dialect/mhlo/IR/
Dinit.cc24 registry.insert<mlir::chlo::HloClientDialect, in registerAllMhloDialects()
Dchlo_ops.cc29 namespace chlo { namespace
383 namespace chlo { namespace
/external/tensorflow/tensorflow/compiler/mlir/hlo/tools/mlir-hlo-opt/
Dmlir-hlo-opt.cpp33 registry.insert<mlir::chlo::HloClientDialect>(); in main()
/external/tensorflow/tensorflow/compiler/mlir/hlo/include/mlir-hlo/Dialect/mhlo/transforms/
Drewriters.h100 namespace chlo {
Dmhlo_passes.td18 def ChloLegalizeToHloPass : FunctionPass<"chlo-legalize-to-hlo"> {
23 /*default=*/"false", "Only lower broadcasting chlo to non-broadcasting equivalents">,
Dmap_chlo_to_hlo_op.h26 namespace chlo {
/external/tensorflow/tensorflow/compiler/mlir/xla/transforms/
Dlegalize_tf.cc76 registry.insert<chlo::HloClientDialect, mhlo::MhloDialect, in getDependentDialects()
713 auto plus_one = builder->create<chlo::BroadcastAddOp>( in CreateWhile32()
1868 auto add_op = rewriter.create<chlo::BroadcastAddOp>( in matchAndRewrite()
2002 Value corrected_variance = rewriter.create<chlo::BroadcastMulOp>( in matchAndRewrite()
2022 auto alpha_mul_old_mean = rewriter.create<chlo::BroadcastMulOp>( in matchAndRewrite()
2025 auto beta_mul_batch_mean = rewriter.create<chlo::BroadcastMulOp>( in matchAndRewrite()
2028 batch_mean = rewriter.create<chlo::BroadcastAddOp>( in matchAndRewrite()
2033 auto alpha_mul_old_variance = rewriter.create<chlo::BroadcastMulOp>( in matchAndRewrite()
2036 auto beta_mul_batch_variance = rewriter.create<chlo::BroadcastMulOp>( in matchAndRewrite()
2039 corrected_variance = rewriter.create<chlo::BroadcastAddOp>( in matchAndRewrite()
[all …]
/external/tensorflow/tensorflow/compiler/mlir/hlo/
DREADME.md104 * `chlo`: the "client" HLO dialect, intended to be closer to the frontend
115 ### HLO Client Dialect: `chlo`.
145 The `chlo` dialect started originally as mapping to the XLA client Builder APIs.
196 * Legalization from `chlo` dialect or conversion from XLA HLO.
/external/tensorflow/tensorflow/compiler/mlir/tensorflow/transforms/
Dlegalize_hlo_patterns.td47 // Note that these are legalized from chlo.broadcast_* ops, since those are
180 // Note that these are legalized from chlo.broadcast_* ops, since those are
/external/tensorflow/tensorflow/compiler/mlir/tools/kernel_gen/
Dkernel_creator.cc437 registry.insert<mlir::chlo::HloClientDialect, mlir::mhlo::MhloDialect>(); in GenerateKernelForTfCode()

12