From 316912363d644bf1b370313b451ad394017a30fc Mon Sep 17 00:00:00 2001 From: Alex Date: Fri, 22 Nov 2024 10:50:47 -0800 Subject: [PATCH] PR #19660: [ROCm] switch rocm build to clang Imported from GitHub PR https://github.com/openxla/xla/pull/19660 This PR switches the default rocm build to clang as the gcc config is broken at the moment. Copybara import of the project: -- ea48f7c480d110eab3f133ed6ea8989da0e1e724 by Alexandros Theodoridis : [ROCm] switch rocm build to clang -- 2743fabafd6a358c05e858781064e7fa2e389c78 by Alexandros Theodoridis : Remove explicit clang path from the bazelrc rocm config -- 202dea0a80602cafdbee6067d8f20dc3055c6bbb by Alexandros Theodoridis : Address review comments Merging this change closes #19660 PiperOrigin-RevId: 699222609 --- .bazelrc | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.bazelrc b/.bazelrc index 6d52daa04..4e4c82d67 100644 --- a/.bazelrc +++ b/.bazelrc @@ -292,6 +292,14 @@ build:rocm --define=using_rocm_hipcc=true build:rocm --define=tensorflow_mkldnn_contraction_kernel=0 build:rocm --repo_env TF_NEED_ROCM=1 +build:rocm_clang_official --config=rocm +build:rocm_clang_official --action_env=CLANG_COMPILER_PATH="/usr/lib/llvm-18/bin/clang" +build:rocm_clang_official --action_env=TF_ROCM_CLANG="1" +build:rocm_clang_official --linkopt="-fuse-ld=lld" +build:rocm_clang_official --host_linkopt="-fuse-ld=lld" + +build:rocm_ci --config=rocm_clang_official + build:sycl --crosstool_top=@local_config_sycl//crosstool:toolchain build:sycl --define=using_sycl=true build:sycl --define=tensorflow_mkldnn_contraction_kernel=0