mirror of
https://github.com/zebrajr/tensorflow.git
synced 2026-01-15 12:15:41 +00:00
Remove mlir_runner_utils from deps of libcuda-runtime-wrappers.so.
The runtime wrappers do not use any symbols from the runner utils. The cmake LLVM build links mlir_runner_utils as archive and because no symbols are used, it is skipped. Bazel however links the individual object files, and so it included symbols from mlir_runner_utils. This change makes the bazel build consistent with the cmake build. Move vulkan/cuda-runner runtime wrapper dependencies to lit package. PiperOrigin-RevId: 354933556 Change-Id: I6078ace3f854a90d2d74d499dad4c2a645b39e4f
This commit is contained in:
committed by
TensorFlower Gardener
parent
7c12f19b14
commit
1d02afc81b
23
third_party/mlir/BUILD
vendored
23
third_party/mlir/BUILD
vendored
@@ -3923,28 +3923,20 @@ cc_binary(
|
||||
],
|
||||
)
|
||||
|
||||
cc_library(
|
||||
name = "tools/libcuda-runtime-wrappers",
|
||||
cc_binary(
|
||||
name = "tools/libcuda-runtime-wrappers.so",
|
||||
srcs = ["tools/mlir-cuda-runner/cuda-runtime-wrappers.cpp"],
|
||||
compatible_with = ["//buildenv/target:prod"],
|
||||
linkshared = True,
|
||||
deps = [
|
||||
":mlir_c_runner_utils",
|
||||
"//third_party/gpus/cuda:cuda_headers",
|
||||
"//third_party/gpus/cuda:cuda_runtime",
|
||||
"//third_party/gpus/cuda:libcuda",
|
||||
# Note: for headers only, the archive itself should not be linked.
|
||||
# See https://reviews.llvm.org/D95613 for details.
|
||||
"@llvm-project//llvm:Support",
|
||||
],
|
||||
)
|
||||
|
||||
cc_binary(
|
||||
name = "tools/libcuda-runtime-wrappers.so",
|
||||
linkshared = True,
|
||||
deps = [
|
||||
":mlir_runner_utils",
|
||||
":tools/libcuda-runtime-wrappers",
|
||||
],
|
||||
)
|
||||
|
||||
cc_library(
|
||||
name = "VulkanRuntime",
|
||||
srcs = ["tools/mlir-vulkan-runner/VulkanRuntime.cpp"],
|
||||
@@ -3975,7 +3967,6 @@ cc_binary(
|
||||
cc_binary(
|
||||
name = "mlir-cuda-runner",
|
||||
srcs = ["tools/mlir-cuda-runner/mlir-cuda-runner.cpp"],
|
||||
data = [":tools/libcuda-runtime-wrappers.so"],
|
||||
deps = [
|
||||
":AllPassesAndDialectsNoRegistration",
|
||||
":ExecutionEngineUtils",
|
||||
@@ -4003,10 +3994,6 @@ cc_binary(
|
||||
cc_binary(
|
||||
name = "mlir-vulkan-runner",
|
||||
srcs = ["tools/mlir-vulkan-runner/mlir-vulkan-runner.cpp"],
|
||||
data = [
|
||||
":tools/libvulkan-runtime-wrappers.so",
|
||||
"@llvm-project//mlir/test/mlir-cpu-runner:libmlir_runner_utils.so",
|
||||
],
|
||||
deps = [
|
||||
":AllPassesAndDialectsNoRegistration",
|
||||
":ExecutionEngineUtils",
|
||||
|
||||
Reference in New Issue
Block a user