[all-commits] [llvm/llvm-project] 861764: [NVPTX] Fix NVPTX output name in the driver with `...

Joseph Huber via All-commits all-commits at lists.llvm.org
Wed Feb 15 05:40:52 PST 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 861764b1c5f7fc31601655f01d84407d42013c30
      https://github.com/llvm/llvm-project/commit/861764b1c5f7fc31601655f01d84407d42013c30
  Author: Joseph Huber <jhuber6 at vols.utk.edu>
  Date:   2023-02-15 (Wed, 15 Feb 2023)

  Changed paths:
    M clang/lib/Driver/ToolChains/Cuda.cpp
    M clang/test/Driver/cuda-cross-compiling.c

  Log Message:
  -----------
  [NVPTX] Fix NVPTX output name in the driver with `-save-temps`

Summary:
Currently, OpenMP and direct compilation uses an NVPTX toolchain to
directly invoke the CUDA tools from Clang to do the assembling and
linking of NVPTX codes. This breaks under `-save-temps` because of a
workaround. The `nvlink` linker does not accept `.o` files, so we need
to be selective when we output these. The previous logic keyed off of
presense in the temp files and wasn't a great solution. Change this to
just query the input args for `-c` to see if we stop at the assembler.

Fixes https://github.com/llvm/llvm-project/issues/60767




More information about the All-commits mailing list