[clang] [llvm] [openmp] [OpenMP] Use generic IR for the OpenMP DeviceRTL (PR #119091)

2024-12-08 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > First I will always consider NVVM reflect a giant hack. NVVM reflect cannot > actually deal with the full range of wavesize issues. It is an incompatible > ABI and the code should never be intermixed It's a hack, but still better than whatever it is AMD does currently. https:

[clang] [llvm] [openmp] [OpenMP] Use generic IR for the OpenMP DeviceRTL (PR #119091)

2024-12-08 Thread Matt Arsenault via cfe-commits
arsenm wrote: > > This probably should retain separate wave32/wave64 builds. Additionally, > > should have extension points for subtarget specific implementations > > That's what Shilei was talking about since we have `__nvvm_reflect` for that > for NVPTX. First I will always consider NVVM re

[clang] [llvm] [openmp] [OpenMP] Use generic IR for the OpenMP DeviceRTL (PR #119091)

2024-12-08 Thread Shilei Tian via cfe-commits
shiltian wrote: > This probably should retain separate wave32/wave64 builds. Additionally, > should have extension points for subtarget specific implementations Does wave32/wave64 affect the lowering from front end source code to middle end IR, if we don't use certain functions, such as wave l

[clang] [llvm] [openmp] [OpenMP] Use generic IR for the OpenMP DeviceRTL (PR #119091)

2024-12-08 Thread Michał Górny via cfe-commits
@@ -288,18 +258,11 @@ function(compileDeviceRTLLibrary target_cpu target_name target_triple) endif() endfunction() -# Generate a Bitcode library for all the gpu architectures the user requested. -add_custom_target(omptarget.devicertl.nvptx) add_custom_target(omptarget.devi

[clang] [clang] constexpr built-in elementwise add_sat/sub_sat functions. (PR #119082)

2024-12-08 Thread via cfe-commits
https://github.com/c8ef updated https://github.com/llvm/llvm-project/pull/119082 >From 2af0eb663a106b712a3c9eb2028dc35014884708 Mon Sep 17 00:00:00 2001 From: c8ef Date: Sun, 8 Dec 2024 01:11:51 +0800 Subject: [PATCH 1/4] constexpr elementwise add_sat --- clang/docs/LanguageExtensions.rst

[clang] [llvm] Reimplement constrained 'trunc' using operand bundles (PR #118253)

2024-12-08 Thread Matt Arsenault via cfe-commits
arsenm wrote: > Two, we can add a "readnone_fp_intrinsic" attribute, which would mean the > intrinsic is readnone unless there's an operand bundle indicating otherwise. I think this needs to be more refined to FP mode read/write and errno read/write. Basically a mirror of memory() for argument

[clang] [clang] constexpr built-in elementwise add_sat/sub_sat functions. (PR #119082)

2024-12-08 Thread Simon Pilgrim via cfe-commits
https://github.com/RKSimon approved this pull request. LGTM cheers https://github.com/llvm/llvm-project/pull/119082 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [openmp] [OpenMP] Use generic IR for the OpenMP DeviceRTL (PR #119091)

2024-12-08 Thread Michał Górny via cfe-commits
@@ -288,18 +258,11 @@ function(compileDeviceRTLLibrary target_cpu target_name target_triple) endif() endfunction() -# Generate a Bitcode library for all the gpu architectures the user requested. -add_custom_target(omptarget.devicertl.nvptx) add_custom_target(omptarget.devi

[clang] [clang] constexpr built-in elementwise add_sat/sub_sat functions. (PR #119082)

2024-12-08 Thread Simon Pilgrim via cfe-commits
https://github.com/RKSimon edited https://github.com/llvm/llvm-project/pull/119082 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [PAC][ELF][AArch64] Support signed personality function pointer (PR #113148)

2024-12-08 Thread Daniil Kovalev via cfe-commits
kovdan01 wrote: @MaskRay Please let me know if latest changes fix your previous comments and if this could be merged. https://github.com/llvm/llvm-project/pull/113148 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-b

[clang] [clang] constexpr built-in elementwise add_sat/sub_sat functions. (PR #119082)

2024-12-08 Thread Simon Pilgrim via cfe-commits
@@ -822,3 +822,19 @@ static_assert(__builtin_elementwise_bitreverse(0x12345678) == 0x1E6A2C48); static_assert(__builtin_elementwise_bitreverse(0x0123456789ABCDEFULL) == 0xF7B3D591E6A2C480); static_assert(__builtin_bit_cast(unsigned, __builtin_elementwise_bitreverse((vector4ch

[clang] [clang] constexpr built-in elementwise add_sat/sub_sat functions. (PR #119082)

2024-12-08 Thread Simon Pilgrim via cfe-commits
https://github.com/RKSimon edited https://github.com/llvm/llvm-project/pull/119082 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [openmp] [OpenMP] Use generic IR for the OpenMP DeviceRTL (PR #119091)

2024-12-08 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > This probably should retain separate wave32/wave64 builds. Additionally, > should have extension points for subtarget specific implementations That's what Shilei was talking about since we have `__nvvm_reflect` for that for NVPTX. https://github.com/llvm/llvm-project/pull/119

[clang] [llvm] [openmp] [OpenMP] Use generic IR for the OpenMP DeviceRTL (PR #119091)

2024-12-08 Thread Matt Arsenault via cfe-commits
arsenm wrote: This probably should retain separate wave32/wave64 builds. Additionally, should have extension points for subtarget specific implementations https://github.com/llvm/llvm-project/pull/119091 ___ cfe-commits mailing list cfe-commits@lists

[clang] [llvm] [llvm][opt][Transforms][SPIR-V] Enable `InferAddressSpaces` for SPIR-V (PR #110897)

2024-12-08 Thread Matt Arsenault via cfe-commits
@@ -178,6 +266,9 @@ void SPIRVPassConfig::addIRPasses() { addPass(createSPIRVStructurizerPass()); } + if (TM.getOptLevel() > CodeGenOptLevel::None) +addPass(createInferAddressSpacesPass(AddressSpace::Generic)); arsenm wrote: I remember we had some

[clang] [llvm] [llvm][opt][Transforms][SPIR-V] Enable `InferAddressSpaces` for SPIR-V (PR #110897)

2024-12-08 Thread Matt Arsenault via cfe-commits
@@ -92,6 +98,65 @@ SPIRVTargetMachine::SPIRVTargetMachine(const Target &T, const Triple &TT, setRequiresStructuredCFG(false); } +enum AddressSpace { + Function = storageClassToAddressSpace(SPIRV::StorageClass::Function), + CrossWorkgroup = + storageClassToAddressSpac

[clang] [llvm] [llvm][opt][Transforms][SPIR-V] Enable `InferAddressSpaces` for SPIR-V (PR #110897)

2024-12-08 Thread Matt Arsenault via cfe-commits
@@ -92,6 +98,65 @@ SPIRVTargetMachine::SPIRVTargetMachine(const Target &T, const Triple &TT, setRequiresStructuredCFG(false); } +enum AddressSpace { + Function = storageClassToAddressSpace(SPIRV::StorageClass::Function), + CrossWorkgroup = + storageClassToAddressSpac

[clang] [clang] Fix cast for injected types in case name lookup for dependent bases (PR #119024)

2024-12-08 Thread via cfe-commits
https://github.com/cor3ntin approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/119024 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

<    1   2