Fully remove unranked kernels for now.

PiperOrigin-RevId: 342614495
Change-Id: I3a67871d9f88e3d1a03961b7f5d36cc2616b703a
This commit is contained in:
Tres Popp 2020-11-16 05:20:29 -08:00 committed by TensorFlower Gardener
parent 3202f5d14f
commit 516f4a121c

View File

@ -82,10 +82,8 @@ cc_library(
tf_kernel_library( tf_kernel_library(
name = "cwise_unary_op", name = "cwise_unary_op",
srcs = [":unary_kernel_srcs"], srcs = [":unary_kernel_srcs"],
# TODO(herhut): Remove no_rocm once kernels build again.
tags = [ tags = [
"manual", "manual",
"no_rocm",
], ],
deps = if_mlir_unranked_kernels_enabled( deps = if_mlir_unranked_kernels_enabled(
if_false = [ if_false = [
@ -116,27 +114,24 @@ tf_kernel_library(
), ),
) )
tf_kernel_library( # TODO(herhut): Uncomment once unranked kernels build again.
name = "cwise_binary_op", # tf_kernel_library(
srcs = ["unranked_gpu_add.cc"], # name = "cwise_binary_op",
# TODO(herhut): Remove no_rocm once kernels build again. # srcs = ["unranked_gpu_add.cc"],
tags = [ # tags = [
"manual", # "manual",
"no_rocm", # ],
], # deps = [
deps = [ # ":addv2_unranked_kernels",
":addv2_unranked_kernels", # ":unranked_op_gpu_base",
":unranked_op_gpu_base", # "//third_party/eigen3",
"//third_party/eigen3", # ],
], # )
)
tf_kernel_library( tf_kernel_library(
name = "cwise_op", name = "cwise_op",
srcs = [], srcs = [],
# TODO(herhut): Remove manual once kernels build again.
tags = [ tags = [
"manual",
"no_rocm", "no_rocm",
], ],
# Technically these libraries don't need --config=cuda or --config=rocm, # Technically these libraries don't need --config=cuda or --config=rocm,
@ -145,7 +140,8 @@ tf_kernel_library(
":cwise_unary_op", ":cwise_unary_op",
]) + if_mlir_unranked_kernels_enabled( ]) + if_mlir_unranked_kernels_enabled(
[ [
":cwise_binary_op", # TODO(herhut): Uncomment once it builds again.
# ":cwise_binary_op",
], ],
), ),
) )
@ -192,26 +188,27 @@ tf_cuda_cc_test(
], ],
) )
tf_cuda_cc_test( # TODO(herhut): Uncomment once unranked kernels build again.
name = "gpu_add_test", # tf_cuda_cc_test(
size = "small", # name = "gpu_add_test",
srcs = if_mlir_generated_gpu_kernels_enabled(["gpu_add_test.cc"]), # size = "small",
tags = tf_cuda_tests_tags() + [ # srcs = if_mlir_generated_gpu_kernels_enabled(["gpu_add_test.cc"]),
"no_cuda_asan", # b/173033461 # tags = tf_cuda_tests_tags() + [
], # "no_cuda_asan", # b/173033461
deps = [ # ],
"//tensorflow/core:framework", # deps = [
"//tensorflow/core:framework_internal", # "//tensorflow/core:framework",
"//tensorflow/core:tensorflow", # "//tensorflow/core:framework_internal",
"//tensorflow/core:test", # "//tensorflow/core:tensorflow",
"//tensorflow/core:test_main", # "//tensorflow/core:test",
"//tensorflow/core:testlib", # "//tensorflow/core:test_main",
"//tensorflow/core/common_runtime:device", # "//tensorflow/core:testlib",
"//tensorflow/core/common_runtime:device_factory", # "//tensorflow/core/common_runtime:device",
"//tensorflow/core/kernels:cwise_op", # "//tensorflow/core/common_runtime:device_factory",
"//tensorflow/core/kernels:ops_testutil", # "//tensorflow/core/kernels:cwise_op",
], # "//tensorflow/core/kernels:ops_testutil",
) # ],
# )
# TODO(b/160731748): Re-enable when it works again. # TODO(b/160731748): Re-enable when it works again.
# gen_kernel_library( # gen_kernel_library(
# name = "bias_add", # name = "bias_add",
@ -314,19 +311,20 @@ gen_kernel_library(
unroll_factors = "4", unroll_factors = "4",
) )
gen_kernel_library( # TODO(herhut): Uncomment once it builds again.
name = "addv2", # gen_kernel_library(
generate_ranked = False, # name = "addv2",
generate_unranked = True, # generate_ranked = False,
tile_size = "256", # generate_unranked = True,
types = [ # tile_size = "256",
"f16", # types = [
"f32", # "f16",
"f64", # "f32",
"i64", # "f64",
], # "i64",
unroll_factors = "4", # ],
) # unroll_factors = "4",
# )
[ [
gen_kernel_library( gen_kernel_library(