Enable the generated version of real and imag kernels.

PiperOrigin-RevId: 354959909
Change-Id: I94ca2f41ccc8450649585b1fdc25cb4f0aa2e025
This commit is contained in:
Stephan Herhut 2021-02-01 09:44:01 -08:00 committed by TensorFlower Gardener
parent c71186f7f5
commit 30f2b5fa02
5 changed files with 8 additions and 6 deletions

View File

@ -19,7 +19,9 @@ limitations under the License.
namespace tensorflow {
namespace functor {
#if !defined(MLIR_GENERATED_GPU_KERNELS_ENABLED)
DEFINE_UNARY2(get_imag, complex64, complex128);
#endif
} // namespace functor
} // namespace tensorflow

View File

@ -19,7 +19,9 @@ limitations under the License.
namespace tensorflow {
namespace functor {
#if !defined(MLIR_GENERATED_GPU_KERNELS_ENABLED)
DEFINE_UNARY2(get_real, complex64, complex128);
#endif
} // namespace functor
} // namespace tensorflow

View File

@ -27,8 +27,7 @@ REGISTER_COMPLEX(CPU, float, complex64);
REGISTER_COMPLEX(CPU, double, complex128);
#if GOOGLE_CUDA || TENSORFLOW_USE_ROCM
#if !defined(MLIR_GENERATED_GPU_KERNELS_ENABLED) || \
!defined(MLIR_GENERATED_EXPERIMENTAL_GPU_KERNELS_ENABLED)
#if !defined(MLIR_GENERATED_GPU_KERNELS_ENABLED)
REGISTER_COMPLEX(GPU, float, complex64);
REGISTER_COMPLEX(GPU, double, complex128);
#endif

View File

@ -28,8 +28,7 @@ REGISTER_COMPLEX(CPU, float, complex64);
REGISTER_COMPLEX(CPU, double, complex128);
#if GOOGLE_CUDA || TENSORFLOW_USE_ROCM
#if !defined(MLIR_GENERATED_GPU_KERNELS_ENABLED) || \
!defined(MLIR_GENERATED_EXPERIMENTAL_GPU_KERNELS_ENABLED)
#if !defined(MLIR_GENERATED_GPU_KERNELS_ENABLED)
REGISTER_COMPLEX(GPU, float, complex64);
REGISTER_COMPLEX(GPU, double, complex128);
#endif

View File

@ -50,6 +50,8 @@ filegroup(
"gpu_op_erf.cc",
"gpu_op_erfc.cc",
"gpu_op_floor.cc",
"gpu_op_imag.cc",
"gpu_op_real.cc",
"gpu_op_sqrt.cc",
"gpu_op_square.cc",
"gpu_op_tan.cc",
@ -67,7 +69,6 @@ filegroup(
"gpu_op_asinh.cc",
"gpu_op_exp.cc",
"gpu_op_expm1.cc",
"gpu_op_imag.cc",
"gpu_op_invert.cc",
"gpu_op_is_finite.cc",
"gpu_op_is_inf.cc",
@ -77,7 +78,6 @@ filegroup(
"gpu_op_log1p.cc",
"gpu_op_logical_not.cc",
"gpu_op_neg.cc",
"gpu_op_real.cc",
"gpu_op_rsqrt.cc",
"gpu_op_sign.cc",
"gpu_op_sin.cc",