Skip to content

Commit

Permalink
🩹 Fix *_nvptx toolchains after bf16e6a (#261)
Browse files Browse the repository at this point in the history
  • Loading branch information
aaronmondal authored Jan 2, 2025
1 parent 0f32482 commit 981d1f8
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions ll/args.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,11 @@ def compile_object_args(
"cuda_nvptx",
"hip_nvptx",
]:
# Enable the use of libc++ for the clang-based device compilation.
# This is only used with the clang-based device compilation. The
# cuda_nvptx_nvcc toolchain uses libstdc++ from Nix.
args.add("-D_ALLOW_UNSUPPORTED_LIBCPP")

args.add("-Wno-unknown-cuda-version") # Will always be unknown.
args.add("-xcuda")
if toolchain.LL_CUDA_TOOLKIT != "":
Expand Down Expand Up @@ -528,8 +533,8 @@ def link_executable_args(ctx, in_files, out_file, mode):
args.add(toolchain.LL_CUDA_TOOLKIT, format = "-L%s/lib/stubs")

args.add("-lcuda")
args.add("-lcudart_static")
args.add("-lcupti_static")
args.add("-lcudart")
args.add("-lcupti")
if ctx.attr.compilation_mode == "hip_amdgpu":
args.add(toolchain.hip_runtime[0].dirname, format = "-L%s")
args.add(toolchain.hip_runtime[0].basename, format = "-l:%s")
Expand Down

0 comments on commit 981d1f8

Please sign in to comment.