[PATCH] D157750: Properly handle -fsplit-machine-functions for fatbinary compilation
Artem Belevich via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Aug 17 10:29:14 PDT 2023
tra added inline comments.
================
Comment at: clang/test/Driver/fsplit-machine-functions-with-cuda-nvptx.c:16
+// causes a warning.
+// RUN: %clang --target=x86_64-unknown-linux-gnu -nogpulib -nogpuinc \
+// RUN: --cuda-gpu-arch=sm_70 -x cuda -fsplit-machine-functions -S %s 2>&1 \
----------------
Hahnfeld wrote:
> steelannelida wrote:
> > Unfortunately these commands fail in our sandbox due to writing files to readonly directories:
> >
> > `unable to open output file 'fsplit-machine-functions-with-cuda-nvptx.s': 'Permission denied'`
> >
> > Could you please specify the output files via `%t` substitutions? I'm not sure how to do this for cuda compilation.
> IIRC the file names are generated based on what you specify with `-o`. Did you try this already?
The problem is that in this case we didn't pass any -o at all here, so the compiler tries to write into the current directory.
We need `-o %t.s` or `-o /dev/null` here.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D157750/new/
https://reviews.llvm.org/D157750
More information about the cfe-commits
mailing list