[clang] [Clang] Add timeout for GPU detection utilities (PR #94751)

2024-06-07 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 closed https://github.com/llvm/llvm-project/pull/94751 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [OpenMP] Fix passing target id features to AMDGPU offloading (PR #94765)

2024-06-07 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 created https://github.com/llvm/llvm-project/pull/94765 Summary: AMDGPU supports a `target-id` feature which is used to qualify targets with different incompatible features. These are both rules and target features. Currently, we pass `-target-cpu` twice when offloadin

[clang] [OpenMP] Fix passing target id features to AMDGPU offloading (PR #94765)

2024-06-07 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 closed https://github.com/llvm/llvm-project/pull/94765 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Add timeout for GPU detection utilities (PR #94751)

2024-06-07 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > Ooh... I think I know exactly what may be causing this. I've observed this a few times. For my case it's usually when some application hangs on the GPU and no one notices, then these tools hang forever and it takes awhile to notice. Figured an error is friendlier since I highl

[clang] [llvm] [clang][Driver] Add HIPAMD Driver support for AMDGCN flavoured SPIR-V (PR #95061)

2024-06-10 Thread Joseph Huber via cfe-commits
@@ -128,12 +128,13 @@ enum class CudaArch { GFX12_GENERIC, GFX1200, GFX1201, + AMDGCNSPIRV, Generic, // A processor model named 'generic' if the target backend defines a // public one. LAST, CudaDefault = CudaArch::SM_52, - HIPDefault = CudaArch::

[clang] [llvm] [clang][Driver] Add HIPAMD Driver support for AMDGCN flavoured SPIR-V (PR #95061)

2024-06-10 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 edited https://github.com/llvm/llvm-project/pull/95061 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [clang][Driver] Add HIPAMD Driver support for AMDGCN flavoured SPIR-V (PR #95061)

2024-06-10 Thread Joseph Huber via cfe-commits
@@ -128,12 +128,13 @@ enum class CudaArch { GFX12_GENERIC, GFX1200, GFX1201, + AMDGCNSPIRV, Generic, // A processor model named 'generic' if the target backend defines a // public one. LAST, CudaDefault = CudaArch::SM_52, - HIPDefault = CudaArch::

[clang] [Clang] Forward -rpath flag to the correct format in CPU offloading (PR #95763)

2024-06-18 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 edited https://github.com/llvm/llvm-project/pull/95763 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Forward -rpath flag to the correct format in CPU offloading (PR #95763)

2024-06-18 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 commented: I thought that clang accepted `-rpath `? I see that format when I try CPU offloading. https://github.com/llvm/llvm-project/pull/95763 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/

[clang] [Clang] Forward -rpath flag to the correct format in CPU offloading (PR #95763)

2024-06-18 Thread Joseph Huber via cfe-commits
jhuber6 wrote: What is this? https://github.com/llvm/llvm-project/pull/95763 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Forward -rpath flag to the correct format in CPU offloading (PR #95763)

2024-06-18 Thread Joseph Huber via cfe-commits
jhuber6 wrote: The tests use an option that causes nothing to actually run, so it only uses the filename. https://github.com/llvm/llvm-project/pull/95763 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https:

[clang] [Clang] Forward -rpath flag to the correct format in CPU offloading (PR #95763)

2024-06-18 Thread Joseph Huber via cfe-commits
jhuber6 wrote: I remember intentionally using the clang argument format instead of `-Wl,-rpath,` because the `-Wl` format would try to forward it to things like `nvlink` which don't support it. https://github.com/llvm/llvm-project/pull/95763 ___ cfe-

[clang] [Clang] Forward -rpath flag to the correct format in CPU offloading (PR #95763)

2024-06-18 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > > I thought that clang accepted `-rpath `? I see that format when I try > > CPU offloading. > > Yeah, but when running `--target=x86_64` and underlying gcc command is issued > and complains about `-rpath ` Oh, I see. When using `-fopenmp-targets=x86_64` it goes through the de

[clang] [Clang] Forward -rpath flag to the correct format in CPU offloading (PR #95763)

2024-06-18 Thread Joseph Huber via cfe-commits
jhuber6 wrote: If you really need this, perhaps you can check if the Triple will invoke the fallback toolchain or something? Would be a lack of vendor in the Triple. https://github.com/llvm/llvm-project/pull/95763 ___ cfe-commits mailing list cfe-comm

[clang] [llvm] [clang][Driver] Add HIPAMD Driver support for AMDGCN flavoured SPIR-V (PR #95061)

2024-06-18 Thread Joseph Huber via cfe-commits
@@ -907,7 +907,8 @@ void CodeGenModule::Release() { if (Context.getTargetInfo().getTriple().isWasm()) EmitMainVoidAlias(); - if (getTriple().isAMDGPU()) { + if (getTriple().isAMDGPU() || + (getTriple().isSPIRV() && getTriple().getVendor() == llvm::Triple::AMD)) {

[clang] [llvm] [clang][Driver] Add HIPAMD Driver support for AMDGCN flavoured SPIR-V (PR #95061)

2024-06-18 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 approved this pull request. LG overall, the growing number of "Is gpu target and some vendor" in the Driver is concerning. https://github.com/llvm/llvm-project/pull/95061 ___ cfe-commits mailing list cfe-commits@lists.llvm.o

[clang] [llvm] [clang][Driver] Add HIPAMD Driver support for AMDGCN flavoured SPIR-V (PR #95061)

2024-06-18 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 edited https://github.com/llvm/llvm-project/pull/95061 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libc] [llvm] [NVPTX] Implement variadic functions using IR lowering (PR #96015)

2024-06-18 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 created https://github.com/llvm/llvm-project/pull/96015 Summary: This patch implements support for variadic functions for NVPTX targets. The implementation here mainly follows what was done to implement it for AMDGPU in https://github.com/llvm/llvm-project/pull/93362.

[clang] [libc] [llvm] [NVPTX] Implement variadic functions using IR lowering (PR #96015)

2024-06-18 Thread Joseph Huber via cfe-commits
@@ -203,8 +203,15 @@ ABIArgInfo NVPTXABIInfo::classifyArgumentType(QualType Ty) const { void NVPTXABIInfo::computeInfo(CGFunctionInfo &FI) const { if (!getCXXABI().classifyReturnType(FI)) FI.getReturnInfo() = classifyReturnType(FI.getReturnType()); - for (auto &I : FI.a

[clang] [libc] [llvm] [NVPTX] Implement variadic functions using IR lowering (PR #96015)

2024-06-18 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/96015 >From bf6f8852621f4a5ac58e6d062d7c78e5eb639c1a Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Mon, 17 Jun 2024 15:32:31 -0500 Subject: [PATCH] [NVPTX] Implement variadic functions using IR lowering Summary: T

[clang] [libc] [llvm] [NVPTX] Implement variadic functions using IR lowering (PR #96015)

2024-06-19 Thread Joseph Huber via cfe-commits
@@ -17,6 +17,8 @@ #define MODULE_PASS(NAME, CREATE_PASS) #endif MODULE_PASS("generic-to-nvvm", GenericToNVVMPass()) +MODULE_PASS("expand-variadics", jhuber6 wrote: Couldn't remember if adding it to `addIRPasses` applied to all uses. I remember something like

[clang] [libc] [llvm] [NVPTX] Implement variadic functions using IR lowering (PR #96015)

2024-06-19 Thread Joseph Huber via cfe-commits
@@ -938,6 +938,37 @@ struct Amdgpu final : public VariadicABIInfo { } }; +struct NVPTX final : public VariadicABIInfo { + + bool enableForTarget() override { return true; } + + bool vaListPassedInSSARegister() override { return true; } + + Type *vaListType(LLVMContext &Ct

[clang] [libc] [llvm] [NVPTX] Implement variadic functions using IR lowering (PR #96015)

2024-06-19 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > With the possible exception of some alignment handling this looks about as > I'd expect it to. Ideally we'd get some feedback from nvptx-associated people > but fixing libc is a good sign Yep, I believe @Artem-B is on vacation, so hopefully @AlexMaclean can chime in. This sho

[clang] [libc] [llvm] [NVPTX] Implement variadic functions using IR lowering (PR #96015)

2024-06-19 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/96015 >From a05b24a06429c1ad6c4988f232442d53010e79a9 Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Mon, 17 Jun 2024 15:32:31 -0500 Subject: [PATCH] [NVPTX] Implement variadic functions using IR lowering Summary: T

[clang] [libc] [llvm] [NVPTX] Implement variadic functions using IR lowering (PR #96015)

2024-06-19 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/96015 >From 0cae8db24812b2ab5539cc581fbc461af072b5fd Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Mon, 17 Jun 2024 15:32:31 -0500 Subject: [PATCH] [NVPTX] Implement variadic functions using IR lowering Summary: T

[clang] [compiler-rt] [libcxx] [libunwind] [llvm] [openmp] [cmake] switch to CMake's native `check_{compiler,linker}_flag` (PR #96171)

2024-06-20 Thread Joseph Huber via cfe-commits
jhuber6 wrote: Here's a radical question, do we really want to use CMake's support for this? I remember a discussion recently about the increasingly large amount of time spent in the CMake configuration step, and most of that time is spent during these flag checks which pretty much all compile

[clang] [libc] [llvm] [NVPTX] Implement variadic functions using IR lowering (PR #96015)

2024-06-21 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/96015 >From 8bd49caa9fa93fd3d0812e0a4315f8ff4956056a Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Mon, 17 Jun 2024 15:32:31 -0500 Subject: [PATCH] [NVPTX] Implement variadic functions using IR lowering Summary: T

[clang] [OpenMP] clang/Driver/Options.td - fix typo in fopenmp-force-usm HelpText (PR #93599)

2024-05-28 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 approved this pull request. https://github.com/llvm/llvm-project/pull/93599 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [OpenMP] Remove dependency on `libffi` from offloading runtime (PR #91264)

2024-05-29 Thread Joseph Huber via cfe-commits
jhuber6 wrote: ping https://github.com/llvm/llvm-project/pull/91264 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver] Remove a bunch of unnecessary REQUIRES constraints (PR #94055)

2024-05-31 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 approved this pull request. I've wondered about these as well, there might also be some OpenMP tests that have `requries powerpc-registered-target` or similar that could be removed. I guess we'll see what the CI thinks with this patch. https://github.com/llvm/llvm-

[clang] [libc] [llvm] [AMDGPU] Implement variadic functions by IR lowering (PR #93362)

2024-06-03 Thread Joseph Huber via cfe-commits
jhuber6 wrote: I can confirm that it passes the tests against the `libc` targets, namely basic `stdarg.h` implementations and `sprintf`. https://github.com/llvm/llvm-project/pull/93362 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://li

[clang] [clang] Fix name conflict with `sys/mac.h` on AIX (PR #88644)

2024-04-15 Thread Joseph Huber via cfe-commits
@@ -50,6 +50,10 @@ const char *CudaVersionToString(CudaVersion V); // Input is "Major.Minor" CudaVersion CudaStringToVersion(const llvm::Twine &S); +// We have a name conflict with sys/mac.h on AIX +#ifdef SM_32 +#undef SM_32 +#endif jhuber6 wrote: We already

[clang] [clang] Fix name conflict with `sys/mac.h` on AIX (PR #88644)

2024-04-15 Thread Joseph Huber via cfe-commits
@@ -50,6 +50,10 @@ const char *CudaVersionToString(CudaVersion V); // Input is "Major.Minor" CudaVersion CudaStringToVersion(const llvm::Twine &S); +// We have a name conflict with sys/mac.h on AIX +#ifdef SM_32 +#undef SM_32 +#endif jhuber6 wrote: We could a

[clang] [clang] Fix name conflict with `sys/mac.h` on AIX (PR #88644)

2024-04-15 Thread Joseph Huber via cfe-commits
@@ -50,6 +50,10 @@ const char *CudaVersionToString(CudaVersion V); // Input is "Major.Minor" CudaVersion CudaStringToVersion(const llvm::Twine &S); +// We have a name conflict with sys/mac.h on AIX +#ifdef SM_32 +#undef SM_32 +#endif jhuber6 wrote: I mean, mo

[clang] [clang] Fix name conflict with `sys/mac.h` on AIX (PR #88644)

2024-04-15 Thread Joseph Huber via cfe-commits
@@ -50,6 +50,10 @@ const char *CudaVersionToString(CudaVersion V); // Input is "Major.Minor" CudaVersion CudaStringToVersion(const llvm::Twine &S); +// We have a name conflict with sys/mac.h on AIX +#ifdef SM_32 +#undef SM_32 +#endif jhuber6 wrote: Just namin

[clang] [clang] Fix name conflict with `sys/mac.h` on AIX (PR #88644)

2024-04-15 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 edited https://github.com/llvm/llvm-project/pull/88644 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CUDA] Rename SM_32 to _SM_32 to work around AIX headers (PR #88779)

2024-04-15 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 created https://github.com/llvm/llvm-project/pull/88779 Summary: AIX headers define this, so we need to work around it. In the future this will be removed but for now we should just rename it to avoid these issues. >From 0020d59172d819cbe95820f00ffdeb0712f5f2b8 Mon S

[clang] [clang] Fix name conflict with `sys/mac.h` on AIX (PR #88644)

2024-04-15 Thread Joseph Huber via cfe-commits
@@ -50,6 +50,10 @@ const char *CudaVersionToString(CudaVersion V); // Input is "Major.Minor" CudaVersion CudaStringToVersion(const llvm::Twine &S); +// We have a name conflict with sys/mac.h on AIX +#ifdef SM_32 +#undef SM_32 +#endif jhuber6 wrote: Good point

[clang] [CUDA] Rename SM_32 to _SM_32 to work around AIX headers (PR #88779)

2024-04-15 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/88779 >From 78662e53fd1309d1e75eb144a2759c580800fd0d Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Mon, 15 Apr 2024 14:12:15 -0500 Subject: [PATCH] [CUDA] Rename SM_32 to _SM_32 to work around AIX headers Summary:

[clang] [CUDA] Rename SM_32 to SM_32_ to work around AIX headers (PR #88779)

2024-04-15 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 edited https://github.com/llvm/llvm-project/pull/88779 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix name conflict with `sys/mac.h` on AIX (PR #88644)

2024-04-15 Thread Joseph Huber via cfe-commits
@@ -50,6 +50,10 @@ const char *CudaVersionToString(CudaVersion V); // Input is "Major.Minor" CudaVersion CudaStringToVersion(const llvm::Twine &S); +// We have a name conflict with sys/mac.h on AIX +#ifdef SM_32 +#undef SM_32 +#endif jhuber6 wrote: Done in ht

[clang] [CUDA] Rename SM_32 to SM_32_ to work around AIX headers (PR #88779)

2024-04-15 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/88779 >From 5440db2ad12cc7f47cf7338a1f963c753b0a9f78 Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Mon, 15 Apr 2024 14:12:15 -0500 Subject: [PATCH] [CUDA] Rename SM_32 to _SM_32 to work around AIX headers Summary:

[clang] [CUDA] Rename SM_32 to SM_32_ to work around AIX headers (PR #88779)

2024-04-15 Thread Joseph Huber via cfe-commits
@@ -3466,7 +3466,7 @@ void CGOpenMPRuntimeGPU::processRequiresDirective( case CudaArch::SM_20: case CudaArch::SM_21: case CudaArch::SM_30: - case CudaArch::SM_32: + case CudaArch::_SM_32: jhuber6 wrote: Thanks, for some reason my LS

[clang] [CUDA] Rename SM_32 to SM_32_ to work around AIX headers (PR #88779)

2024-04-15 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/88779 >From dbf6a86930207a4baa787c4387ab83d30524b2aa Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Mon, 15 Apr 2024 14:12:15 -0500 Subject: [PATCH] [CUDA] Rename SM_32 to _SM_32 to work around AIX headers Summary:

[clang] [CUDA] Rename SM_32 to SM_32_ to work around AIX headers (PR #88779)

2024-04-15 Thread Joseph Huber via cfe-commits
@@ -86,7 +88,7 @@ static const CudaArchToStringMap arch_names[] = { // clang-format off {CudaArch::UNUSED, "", ""}, SM2(20, "compute_20"), SM2(21, "compute_20"), // Fermi -SM(30), SM(32), SM(35), SM(37), // Kepler +SM(30), SM3(32, "compute_32"), SM(35), SM(

[clang] [llvm] [OpenMP] Remove 'minncta' attributes from NVPTX kernels (PR #88398)

2024-04-15 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 closed https://github.com/llvm/llvm-project/pull/88398 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [ClangOffloadBundler] Add file size to header (PR #88827)

2024-04-15 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 commented: Isn't this ABI breaking since we're changing the size of the struct? Shouldn't that necessitate a new version? Also unrelated, I wonder if there's a future where we can use the ClangOffloadPackager format in the HIP runtime. https://github.com/llvm/llvm-p

[clang] [CUDA] Rename SM_32 to SM_32_ to work around AIX headers (PR #88779)

2024-04-16 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 closed https://github.com/llvm/llvm-project/pull/88779 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [ClangOffloadBundler] Add file size to header (PR #88827)

2024-04-16 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > > Isn't this ABI breaking since we're changing the size of the struct? > > Shouldn't that necessitate a new version? > > Also unrelated, I wonder if there's a future where we can use the > > ClangOffloadPackager format in the HIP runtime. > > I think you are right. Although th

[clang] [ClangOffloadBundler] Add file size to header (PR #88827)

2024-04-16 Thread Joseph Huber via cfe-commits
jhuber6 wrote: Seems the documentation builder is complaining, maybe something wrong with the .rst file. https://github.com/llvm/llvm-project/pull/88827 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/lis

[clang] [llvm] [WIP] Expand variadic functions in IR (PR #89007)

2024-04-16 Thread Joseph Huber via cfe-commits
@@ -0,0 +1,1056 @@ +//===-- ExpandVariadicsPass.cpp *- C++ -*-=// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apach

[clang] [Driver] Ensure ToolChain::LibraryPaths is not empty for non-Darwin (PR #87866)

2024-04-17 Thread Joseph Huber via cfe-commits
jhuber6 wrote: It's definitely not ideal that this prints a non-existent path if the per-target runtime directory configuration is off. Couldn't we just do a trivial filesystem check to make sure it exists before appending it? https://github.com/llvm/llvm-project/pull/87866 ___

[clang] [llvm] [Libomptarget] Statically link all plugin runtimes (PR #87009)

2024-04-22 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/87009 >From 50099312ab7c60b8cfce5473a4c154f8d917dc41 Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Wed, 27 Mar 2024 15:27:16 -0500 Subject: [PATCH 1/3] [Libomptarget] Rename `libomptarget.rtl.x86_64` to `libomptar

[clang] 624d322 - [Clang] Fix 'clang-nvlink-wrapper' not working w/o CUDA

2024-07-22 Thread Joseph Huber via cfe-commits
Author: Joseph Huber Date: 2024-07-22T18:57:54-05:00 New Revision: 624d3221d1159bff98964d77c1b76e04a367d9d4 URL: https://github.com/llvm/llvm-project/commit/624d3221d1159bff98964d77c1b76e04a367d9d4 DIFF: https://github.com/llvm/llvm-project/commit/624d3221d1159bff98964d77c1b76e04a367d9d4.diff

[clang] [Clang] Introduce 'clang-nvlink-wrapper' to work around 'nvlink' (PR #96561)

2024-07-22 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > clang/test/CMakeLists.txt CLANG_TEST_DEPS also needs an update. ` > > The test might fail due to `/tmp/Rel/bin/clang-nvlink-wrapper: error: Unable > to find 'nvlink' in path` Also noticed that one, just pushed a fix a minute ago. Sorry for the mess. https://github.com/llvm/ll

[clang] [Clang] Introduce 'clang-nvlink-wrapper' to work around 'nvlink' (PR #96561)

2024-07-22 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > @jhuber6 , there is still few failed bot because of these changes > > * https://lab.llvm.org/buildbot/#/builders/193/builds/1224 > > * https://lab.llvm.org/buildbot/#/builders/2/builds/2790 > > > would you fix the problem or revert the changes? Looks like it's compla

[clang] [OpenMP] Defaultmap: fixes scalar issue, adds all variable category (PR #99315)

2024-07-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 approved this pull request. Looks reasonable, there seem to be a few unrelated changes though. https://github.com/llvm/llvm-project/pull/99315 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi

[clang] [LinkerWrapper] Pass all files to the device linker (PR #97573)

2024-07-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/97573 >From aae059e1389bebe86ceb3aea159d95ca6d0823ea Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Wed, 3 Jul 2024 08:18:23 -0500 Subject: [PATCH] [LinkerWrapper] Pass all files to the device linker Summary: The l

[clang] [LinkerWrapper] Pass all files to the device linker (PR #97573)

2024-07-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 closed https://github.com/llvm/llvm-project/pull/97573 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Make the GPU toolchains implicitly link `-lm` and `-lc` (PR #98170)

2024-07-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/98170 >From 1b488f77309922f8b4a43a2a7a8191c88d9e6996 Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Tue, 9 Jul 2024 10:15:35 -0500 Subject: [PATCH] [Clang] Make the GPU toolchains implicitly link `-lm` and `-lc` S

[clang] [Clang] Make the GPU toolchains implicitly link `-lm` and `-lc` (PR #98170)

2024-07-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/98170 >From 7aefe11bb8b5be6f4fbb1b174dc2606d6fdd31a4 Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Tue, 9 Jul 2024 10:15:35 -0500 Subject: [PATCH 1/2] [Clang] Make the GPU toolchains implicitly link `-lm` and `-lc

[clang] [Clang] Make the GPU toolchains implicitly link `-lm` and `-lc` (PR #98170)

2024-07-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/98170 >From 7aefe11bb8b5be6f4fbb1b174dc2606d6fdd31a4 Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Tue, 9 Jul 2024 10:15:35 -0500 Subject: [PATCH 1/2] [Clang] Make the GPU toolchains implicitly link `-lm` and `-lc

[clang] [Clang] Add 'CLANG_ALLOW_IMPLICIT_RPATH' to enable toolchain use of -rpath (PR #82004)

2024-07-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 closed https://github.com/llvm/llvm-project/pull/82004 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AMDGPU] Introduce 'amdgpu_num_workgroups_{xyz}' builtin (PR #83927)

2024-07-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 closed https://github.com/llvm/llvm-project/pull/83927 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Add 'CLANG_ALLOW_IMPLICIT_RPATH' to enable toolchain use of -rpath (PR #82004)

2024-07-23 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > What's the context for closing this? Community did not want a new CMake config option and I wasn't planning on moving forward with this, so I closed it to clean up my list of open PRs. https://github.com/llvm/llvm-project/pull/82004

[clang] [Clang] Introduce 'clang-nvlink-wrapper' to work around 'nvlink' (PR #96561)

2024-07-23 Thread Joseph Huber via cfe-commits
@@ -0,0 +1,781 @@ +//===-- clang-nvlink-wrapper/ClangNVLinkWrapper.cpp - NVIDIA linker util --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang] [Clang] Introduce 'clang-nvlink-wrapper' to work around 'nvlink' (PR #96561)

2024-07-23 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > Why do we need a new binary for this, instead of having something like `clang > -cc1_nvlink` that calls a custom mode within clang? > > And if there's a good reason for that, could clang-linker-wrapper and > clang-nvlink-wrapper at least be the same binary? Sorry, missed this

[clang] [Clang] Correctly forward `--cuda-path` to the nvlink wrapper (PR #100170)

2024-07-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/100170 >From 69878cc8a39b483a646fb142b418952e34693241 Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Tue, 23 Jul 2024 12:37:12 -0500 Subject: [PATCH] [Clang] Correctly forward `--cuda-path` to the nvlink wrapper Su

[clang] [Clang] Correctly forward `--cuda-path` to the nvlink wrapper (PR #100170)

2024-07-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 closed https://github.com/llvm/llvm-project/pull/100170 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 7d388ae - Revert "[Clang] Correctly forward `--cuda-path` to the nvlink wrapper (#100170)"

2024-07-23 Thread Joseph Huber via cfe-commits
Author: Joseph Huber Date: 2024-07-23T14:51:40-05:00 New Revision: 7d388aeabb34cd954aa57e4321ad3aa9f382c557 URL: https://github.com/llvm/llvm-project/commit/7d388aeabb34cd954aa57e4321ad3aa9f382c557 DIFF: https://github.com/llvm/llvm-project/commit/7d388aeabb34cd954aa57e4321ad3aa9f382c557.diff

[clang] adbe247 - Reapply "[Clang] Correctly forward `--cuda-path` to the nvlink wrapper (#100170)"

2024-07-23 Thread Joseph Huber via cfe-commits
Author: Joseph Huber Date: 2024-07-23T14:52:30-05:00 New Revision: adbe247701826014c608bb0a3289de70ca60889e URL: https://github.com/llvm/llvm-project/commit/adbe247701826014c608bb0a3289de70ca60889e DIFF: https://github.com/llvm/llvm-project/commit/adbe247701826014c608bb0a3289de70ca60889e.diff

[clang] cb0ead7 - [Clang] Add back in REQUIRES lines that were accidentally removed

2024-07-23 Thread Joseph Huber via cfe-commits
Author: Joseph Huber Date: 2024-07-23T15:12:03-05:00 New Revision: cb0ead7888e5e1067dde10213ffb340cbd7419dc URL: https://github.com/llvm/llvm-project/commit/cb0ead7888e5e1067dde10213ffb340cbd7419dc DIFF: https://github.com/llvm/llvm-project/commit/cb0ead7888e5e1067dde10213ffb340cbd7419dc.diff

[clang] [Clang] Make the GPU toolchains implicitly link `-lm` and `-lc` (PR #98170)

2024-07-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/98170 >From 6ffbe94071a1b99e289f806aa145aaa871793b2a Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Tue, 9 Jul 2024 10:15:35 -0500 Subject: [PATCH 1/2] [Clang] Make the GPU toolchains implicitly link `-lm` and `-lc

[clang] 541a631 - [Clang] Mark test XFAIL until a fix is merged

2024-07-23 Thread Joseph Huber via cfe-commits
Author: Joseph Huber Date: 2024-07-23T16:20:56-05:00 New Revision: 541a631237569e4c23ffba137cbeb5ad8d419286 URL: https://github.com/llvm/llvm-project/commit/541a631237569e4c23ffba137cbeb5ad8d419286 DIFF: https://github.com/llvm/llvm-project/commit/541a631237569e4c23ffba137cbeb5ad8d419286.diff

[clang] [Clang] Make the GPU toolchains implicitly link `-lm` and `-lc` (PR #98170)

2024-07-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/98170 >From 6ffbe94071a1b99e289f806aa145aaa871793b2a Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Tue, 9 Jul 2024 10:15:35 -0500 Subject: [PATCH 1/2] [Clang] Make the GPU toolchains implicitly link `-lm` and `-lc

[clang] [llvm] [CUDA] Add a pseudo GPU sm_next which allows overriding for SM/PTX version. (PR #100247)

2024-07-23 Thread Joseph Huber via cfe-commits
@@ -96,6 +96,7 @@ static const OffloadArchToStringMap arch_names[] = { SM(89), // Ada Lovelace SM(90), // Hopper SM(90a), // Hopper +SM(next),// Placeholder for a n

[clang] [LinkerWrapper] Fix `-Xoffload-linker a=b` in offloading (PR #100270)

2024-07-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 created https://github.com/llvm/llvm-project/pull/100270 Summary: We have the `-Xoffload-linker=triple=arg` syntax that split the argument meant only for a single toolchain. However this borke if it was an `a=b` type argument. Make it only treat it like a triple if it'

[clang] [Clang] Make the GPU toolchains implicitly link `-lm` and `-lc` (PR #98170)

2024-07-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/98170 >From 69811ec62c70a55b398f6cd71dd4f73162bb64d1 Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Tue, 9 Jul 2024 10:15:35 -0500 Subject: [PATCH 1/2] [Clang] Make the GPU toolchains implicitly link `-lm` and `-lc

[clang] [llvm] [CUDA] Add a pseudo GPU sm_next which allows overriding for SM/PTX version. (PR #100247)

2024-07-23 Thread Joseph Huber via cfe-commits
@@ -96,6 +96,7 @@ static const OffloadArchToStringMap arch_names[] = { SM(89), // Ada Lovelace SM(90), // Hopper SM(90a), // Hopper +SM(next),// Placeholder for a n

[clang] [llvm] [CUDA] Add a pseudo GPU sm_next which allows overriding for SM/PTX version. (PR #100247)

2024-07-23 Thread Joseph Huber via cfe-commits
@@ -648,6 +658,13 @@ void NVPTX::getNVPTXTargetFeatures(const Driver &D, const llvm::Triple &Triple, Features.push_back(Args.MakeArgString(PtxFeature)); return; } + // Add --cuda-next-ptx to the list of features, but carry on to add the + // default PTX feature for

[clang] [Clang] Make the GPU toolchains implicitly link `-lm` and `-lc` (PR #98170)

2024-07-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 closed https://github.com/llvm/llvm-project/pull/98170 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [CUDA] Add a pseudo GPU sm_next which allows overriding for SM/PTX version. (PR #100247)

2024-07-23 Thread Joseph Huber via cfe-commits
@@ -26,24 +27,38 @@ static cl::opt NoF16Math("nvptx-no-f16-math", cl::Hidden, cl::desc("NVPTX Specific: Disable generation of f16 math ops."), cl::init(false)); +static cl::opt +NextSM("nvptx-next-sm", cl::Hidden, + cl::desc("NVPTX

[clang] [LinkerWrapper] Fix `-Xoffload-linker a=b` in offloading (PR #100270)

2024-07-23 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > I think LLVM generally doesn't follow the convention that `-a x` and > `--abc=x`? `cl::opt` options are arbitrary, but this isn't about convention really, it's for things like `-Xoffload-linker -Wl,-plugin-opt=blah` not being passed correctly. https://github.com/llvm/llvm-pr

[clang] [clang][CUDA] Assume unknown emission status for skipped function definitions (PR #100124)

2024-07-24 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 approved this pull request. https://github.com/llvm/llvm-project/pull/100124 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][OpenMP] Propoagate debug location to OMPIRBuilder reduction codegen (PR #100358)

2024-07-24 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 closed https://github.com/llvm/llvm-project/pull/100358 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [Flang][Driver] Introduce -fopenmp-targets offloading option (PR #100152)

2024-07-24 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > I'm struggling to fix the buildbot issue triggered by the new test in > omp-driver-offload-amdgpu.f90. It was originally in omp-driver-offload.f90, I > only moved it to a new file hoping that adding a "REQUIRES: > amdgpu-registered-target" would address it. It seems like it do

[clang] [LinkerWrapper] Fix `-Xoffload-linker a=b` in offloading (PR #100270)

2024-07-24 Thread Joseph Huber via cfe-commits
@@ -1214,7 +1214,13 @@ DerivedArgList getLinkerArgs(ArrayRef Input, // Forward '-Xoffload-linker' options to the appropriate backend. for (StringRef Arg : Args.getAllArgValues(OPT_device_linker_args_EQ)) { auto [Triple, Value] = Arg.split('='); -if (Value.empty()) +

[clang] [LinkerWrapper] Fix `-Xoffload-linker a=b` in offloading (PR #100270)

2024-07-24 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/100270 >From f4299a69493a05e9c0cddbf11dc93bc5619b39e2 Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Tue, 23 Jul 2024 17:59:09 -0500 Subject: [PATCH 1/2] [LinkerWrapper] Fix `-Xoffload-linker a=b` in offloading Sum

[clang] [LinkerWrapper] Fix `-Xoffload-linker a=b` in offloading (PR #100270)

2024-07-24 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 closed https://github.com/llvm/llvm-project/pull/100270 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [Flang][Driver] Introduce -fopenmp-targets offloading option (PR #100152)

2024-07-24 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > I reproduced this locally. The output is: > > ``` > $ /home/meinersbur/build/llvm-project/release/bin/flang-new -S -### > /c/Users/meinersbur/src/llvm-project/flang/test/Driver/omp-driver-offload-amdgpu.f90 > -o > /home/meinersbur/build/llvm-project/release/tools/flang/test/D

[clang] [LinkerWrapper] Forward `-mllvm` and `--offload-opt` arguments to device (PR #100424)

2024-07-24 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 created https://github.com/llvm/llvm-project/pull/100424 Summary: Previously we could parse these internally as they would be used by the embedded LTO job. Now, this LTO is passed to the linker utilities which means these need to be forwarded. So this can now either be

[clang] [LinkerWrapper] Forward `-mllvm` and `--offload-opt` arguments to device (PR #100424)

2024-07-24 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/100424 >From 800ae50b1e296583d809478b9beb8b8a8cd50eef Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Wed, 24 Jul 2024 11:44:22 -0500 Subject: [PATCH] [LinkerWrapper] Forward `-mllvm` and `--offload-opt` arguments t

[clang] [libc] [llvm] [NVPTX] Implement variadic functions using IR lowering (PR #96015)

2024-07-24 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > The change to `NVPTXTargetInfo::getBuiltinVaListKind()` in > `clang/lib/Basic/Targets/NVPTX.h` caused a regression in Intel's downstream > Clang-based compiler when compiling SYCL code with device compilation > targeting NVPTX. CUDA might be similarly impacted, but I haven't v

[clang] [NVPTX] Restore old va_list builtin type (PR #100438)

2024-07-24 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 created https://github.com/llvm/llvm-project/pull/100438 Summary: This was changed to `void *` from `char *` unintentionally, put it back. >From 068b877f538017c14c60bacf09263d12c1b9d9af Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Wed, 24 Jul 2024 12:49:36 -050

[clang] [NVPTX] Restore old va_list builtin type (PR #100438)

2024-07-24 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 closed https://github.com/llvm/llvm-project/pull/100438 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NVPTX] Restore old va_list builtin type (PR #100438)

2024-07-24 Thread Joseph Huber via cfe-commits
jhuber6 wrote: @tahonermann Feel free to backport this if you need to. https://github.com/llvm/llvm-project/pull/100438 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [Flang][Driver] Introduce -fopenmp-targets offloading option (PR #100152)

2024-07-25 Thread Joseph Huber via cfe-commits
jhuber6 wrote: We could probably also add something like `-Xarch_device_ ` in lieu of `-Xopenmp-target= ` since the `=` format isn't really standard in this area. https://github.com/llvm/llvm-project/pull/100152 ___ cfe-commits mailing list cfe-commi

[clang] [NVPTX] Correctly forward the PTX feature to the nvlink wrapper (PR #100607)

2024-07-25 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 created https://github.com/llvm/llvm-project/pull/100607 Summary: This is necessary for LTO when the user specifies it or has a CUDA version that supports a sufficiently high version. Previously it would default. >From 1156979b150f9ae778cf28adb7adcb812c1ceffb Mon Sep

[clang] [NVPTX] Correctly forward the PTX feature to the nvlink wrapper (PR #100607)

2024-07-25 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 edited https://github.com/llvm/llvm-project/pull/100607 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NVPTX] Correctly forward the PTX feature to the nvlink wrapper (PR #100607)

2024-07-25 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > The patch seems to change only the test file. Should there be more changes in > the patch? Whoops, don't know where it went. https://github.com/llvm/llvm-project/pull/100607 ___ cfe-commits mailing list cfe-commits@lists.llvm.org htt

<    8   9   10   11   12   13   14   15   16   17   >