[clang] [SPARC][clang] Add -m(no-)v8plus flags handling (PR #98713)

2024-07-31 Thread via cfe-commits
https://github.com/koachan edited https://github.com/llvm/llvm-project/pull/98713 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libc] [Clang] Suppress missing architecture error when doing LTO (PR #100652)

2024-07-31 Thread Joseph Huber via cfe-commits
jhuber6 wrote: Ping, would like to remove the hacky code from `libc`. https://github.com/llvm/llvm-project/pull/100652 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Farzon Lotfi via cfe-commits
@@ -0,0 +1,73 @@ +// RUN: %clang_cc1 -finclude-default-header -x hlsl -triple \ +// RUN: dxil-pc-shadermodel6.3-library %s -fnative-half-type \ +// RUN: -emit-llvm -disable-llvm-passes -o - | FileCheck %s \ +// RUN: --check-prefixes=CHECK,NATIVE_HALF +// RUN: %clang_cc1 -fi

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Farzon Lotfi via cfe-commits
@@ -0,0 +1,31 @@ +// RUN: %clang_cc1 -finclude-default-header -triple dxil-pc-shadermodel6.6-library %s -fnative-half-type -emit-llvm -disable-llvm-passes -verify -verify-ignore-unexpected + +void test_too_few_arg() +{ + return __builtin_hlsl_elementwise_length();

[clang] [Driver] Pass correct alignment for -falign-functions with no argument (PR #101257)

2024-07-31 Thread Paul T Robinson via cfe-commits
https://github.com/pogo59 updated https://github.com/llvm/llvm-project/pull/101257 >From a95ab9bfb7be8da6c4ebe0d207beff5a0a72bb9d Mon Sep 17 00:00:00 2001 From: Paul Robinson Date: Tue, 30 Jul 2024 15:17:14 -0700 Subject: [PATCH 1/2] [Driver] Pass correct alignment for -falign-functions with n

[clang] [Clang] Remove __is_nullptr (PR #99038)

2024-07-31 Thread Nikolas Klauser via cfe-commits
https://github.com/philnik777 updated https://github.com/llvm/llvm-project/pull/99038 >From fbc9ebb3900e69f2485111cfdc6b7a7dfd3e6ebe Mon Sep 17 00:00:00 2001 From: Nikolas Klauser Date: Tue, 16 Jul 2024 14:53:30 +0200 Subject: [PATCH 1/2] [Clang] Remove __is_nullptr --- clang/docs/LanguageExt

[clang] [Driver] Pass correct alignment for -falign-functions with no argument (PR #101257)

2024-07-31 Thread Paul T Robinson via cfe-commits
pogo59 wrote: The driver can't really be poking down into LLVM's TargetLowering; at best it could be querying Clang's TargetInfo, which knows a lot about data alignment but does not currently have any knowledge of code alignment. So, I've reverted the change and instead fixed the incorrect com

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Joshua Batista via cfe-commits
@@ -0,0 +1,107 @@ +; RUN: opt -S -dxil-intrinsic-expansion < %s | FileCheck %s --check-prefixes=CHECK,EXPCHECK +; RUN: opt -S -dxil-op-lower < %s | FileCheck %s --check-prefixes=CHECK,DOPCHECK + +; ModuleID = 'D:\llvm-project\clang\test\CodeGenHLSL\builtins\length.hlsl' +sou

[clang] [Driver] Pass correct alignment for -falign-functions with no argument (PR #101257)

2024-07-31 Thread Saleem Abdulrasool via cfe-commits
https://github.com/compnerd approved this pull request. https://github.com/llvm/llvm-project/pull/101257 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Joshua Batista via cfe-commits
@@ -0,0 +1,107 @@ +; RUN: opt -S -dxil-intrinsic-expansion < %s | FileCheck %s --check-prefixes=CHECK,EXPCHECK +; RUN: opt -S -dxil-op-lower < %s | FileCheck %s --check-prefixes=CHECK,DOPCHECK + +; ModuleID = 'D:\llvm-project\clang\test\CodeGenHLSL\builtins\length.hlsl' +sou

[clang] [Driver] Pass correct alignment for -falign-functions with no argument (PR #101257)

2024-07-31 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay approved this pull request. LGTM. The patch title/description need to be changed to ensure "Squash and merge" gets the right message (the git commit message is ignored). https://github.com/llvm/llvm-project/pull/101257 ___

[clang] [Driver] Correct comment on default for -falign-functions (PR #101257)

2024-07-31 Thread Paul T Robinson via cfe-commits
https://github.com/pogo59 edited https://github.com/llvm/llvm-project/pull/101257 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver] Correct comment on default for -falign-functions (PR #101257)

2024-07-31 Thread Paul T Robinson via cfe-commits
https://github.com/pogo59 edited https://github.com/llvm/llvm-project/pull/101257 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] d0b4b6b - [Driver] Correct comment on default for -falign-functions (#101257)

2024-07-31 Thread via cfe-commits
Author: Paul T Robinson Date: 2024-07-31T14:15:30-04:00 New Revision: d0b4b6b12dea662a9316e2f83277288be37be666 URL: https://github.com/llvm/llvm-project/commit/d0b4b6b12dea662a9316e2f83277288be37be666 DIFF: https://github.com/llvm/llvm-project/commit/d0b4b6b12dea662a9316e2f83277288be37be666.dif

[clang] [Driver] Correct comment on default for -falign-functions (PR #101257)

2024-07-31 Thread Paul T Robinson via cfe-commits
https://github.com/pogo59 closed https://github.com/llvm/llvm-project/pull/101257 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Farzon Lotfi via cfe-commits
@@ -0,0 +1,107 @@ +; RUN: opt -S -dxil-intrinsic-expansion < %s | FileCheck %s --check-prefixes=CHECK,EXPCHECK +; RUN: opt -S -dxil-op-lower < %s | FileCheck %s --check-prefixes=CHECK,DOPCHECK + +; ModuleID = 'D:\llvm-project\clang\test\CodeGenHLSL\builtins\length.hlsl' +sou

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl edited https://github.com/llvm/llvm-project/pull/101256 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [SPARC][clang] Add -m(no-)v8plus flags handling (PR #98713)

2024-07-31 Thread Sergei Barannikov via cfe-commits
@@ -6077,6 +6077,10 @@ def mvis3 : Flag<["-"], "mvis3">, Group; def mno_vis3 : Flag<["-"], "mno-vis3">, Group; def mhard_quad_float : Flag<["-"], "mhard-quad-float">, Group; def msoft_quad_float : Flag<["-"], "msoft-quad-float">, Group; +def mv8plus : Flag<["-"], "mv8plus">,

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl edited https://github.com/llvm/llvm-project/pull/101256 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][Tests][NFC] Add CWG882 test (Defining `main` as deleted) (PR #101382)

2024-07-31 Thread Mital Ashok via cfe-commits
https://github.com/MitalAshok created https://github.com/llvm/llvm-project/pull/101382 https://cplusplus.github.io/CWG/issues/882.html This was implemented for Clang 3.5 by b63b6ee9a00ef0710d899df6cfda78a1b8bd762a >From 9dcbd0779bf379bbf62bf52247ef46de82cb4877 Mon Sep 17 00:00:00 2001 From: Mi

[clang] [clang][Tests][NFC] Add CWG882 test (Defining `main` as deleted) (PR #101382)

2024-07-31 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Mital Ashok (MitalAshok) Changes https://cplusplus.github.io/CWG/issues/882.html This was implemented for Clang 3.5 by b63b6ee9a00ef0710d899df6cfda78a1b8bd762a --- Full diff: https://github.com/llvm/llvm-project/pull/101382.diff 2 Files

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 updated https://github.com/llvm/llvm-project/pull/101256 >From 7027cf254ae1b6acfdfbbf5dbeda3c4d6a4b3c43 Mon Sep 17 00:00:00 2001 From: Joshua Batista Date: Fri, 26 Jul 2024 15:41:01 -0700 Subject: [PATCH 1/5] first attempt --- clang/docs/LanguageExtensions.rst

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 updated https://github.com/llvm/llvm-project/pull/101256 >From 7027cf254ae1b6acfdfbbf5dbeda3c4d6a4b3c43 Mon Sep 17 00:00:00 2001 From: Joshua Batista Date: Fri, 26 Jul 2024 15:41:01 -0700 Subject: [PATCH 1/6] first attempt --- clang/docs/LanguageExtensions.rst

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Farzon Lotfi via cfe-commits
@@ -0,0 +1,10 @@ +; RUN: not opt -S -dxil-op-lower -mtriple=dxil-pc-shadermodel6.3-library %s 2>&1 | FileCheck %s + +; DXIL operation length does not support double overload type +; CHECK: LLVM ERROR: Invalid Overload + +define noundef double @test_length_double2(<2 x double> nou

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl edited https://github.com/llvm/llvm-project/pull/101256 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 updated https://github.com/llvm/llvm-project/pull/101256 >From 7027cf254ae1b6acfdfbbf5dbeda3c4d6a4b3c43 Mon Sep 17 00:00:00 2001 From: Joshua Batista Date: Fri, 26 Jul 2024 15:41:01 -0700 Subject: [PATCH 1/7] first attempt --- clang/docs/LanguageExtensions.rst

[clang] [lldb] [HLSL] Implement intangible AST type (PR #97362)

2024-07-31 Thread Xiang Li via cfe-commits
@@ -1390,7 +1390,8 @@ void ASTContext::InitBuiltinTypes(const TargetInfo &Target, #include "clang/Basic/HLSLIntangibleTypes.def" } - if (Target.hasAArch64SVETypes()) { + if (Target.hasAArch64SVETypes() || python3kgae wrote: Is this expected change for in

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Farzon Lotfi via cfe-commits
@@ -0,0 +1,131 @@ +; RUN: opt -S -dxil-intrinsic-expansion < %s | FileCheck %s --check-prefixes=CHECK,EXPCHECK +; RUN: opt -S -dxil-op-lower -mtriple=dxil-pc-shadermodel6.3-library < %s | FileCheck %s --check-prefixes=CHECK,DOPCHECK + +declare half @llvm.fabs.f16(half) --

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl approved this pull request. https://github.com/llvm/llvm-project/pull/101256 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Farzon Lotfi via cfe-commits
farzonl wrote: Nice work LGTM! https://github.com/llvm/llvm-project/pull/101256 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libunwind] [RISCV] Allow libunwind to build for rv32e (PR #98855)

2024-07-31 Thread via cfe-commits
ArcaneNibble wrote: ping? https://github.com/llvm/llvm-project/pull/98855 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [RISCV] Allow YAML file to control multilib selection (PR #98856)

2024-07-31 Thread via cfe-commits
ArcaneNibble wrote: ping? https://github.com/llvm/llvm-project/pull/98856 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Implement output parameter (PR #101083)

2024-07-31 Thread Chris B via cfe-commits
https://github.com/llvm-beanz updated https://github.com/llvm/llvm-project/pull/101083 >From e8ec3e24e0061714b5dc440b1b92086965809483 Mon Sep 17 00:00:00 2001 From: Chris Bieneman Date: Mon, 29 Jul 2024 16:05:11 -0500 Subject: [PATCH 1/7] [HLSL] Implement output parameter HLSL output parameter

[clang] [Clang][SemaCXX] Fix bug where unexpanded lambda captures where assumed to have size 1 (PR #101385)

2024-07-31 Thread Mital Ashok via cfe-commits
https://github.com/MitalAshok created https://github.com/llvm/llvm-project/pull/101385 Fixes #63677 >From 555373715bc2eb025d6580129cead087f7f45ed1 Mon Sep 17 00:00:00 2001 From: Mital Ashok Date: Fri, 7 Jul 2023 14:31:03 +0100 Subject: [PATCH] [Clang][SemaCXX] Fix bug where unexpanded lambda c

[clang] [Clang][SemaCXX] Fix bug where unexpanded lambda captures where assumed to have size 1 (PR #101385)

2024-07-31 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Mital Ashok (MitalAshok) Changes Fixes #63677 --- Full diff: https://github.com/llvm/llvm-project/pull/101385.diff 4 Files Affected: - (modified) clang/docs/ReleaseNotes.rst (+1) - (modified) clang/lib/Sema/SemaTemplateInstantiate.cpp

[clang] [Clang][SemaCXX] Fix bug where unexpanded lambda captures where assumed to have size 1 (PR #101385)

2024-07-31 Thread Mital Ashok via cfe-commits
MitalAshok wrote: Revived from https://reviews.llvm.org/D154716 This probably needs a fresh review, I've just rebased onto main. The problem still exists on main: https://godbolt.org/z/vPTb4qEnd CC @cor3ntin @shafik (as people who reviewed on the phabricator) https://github.com/llvm/llvm-proj

[clang-tools-extra] [clang-doc] uncomment unsupported (PR #101387)

2024-07-31 Thread via cfe-commits
https://github.com/PeterChou1 created https://github.com/llvm/llvm-project/pull/101387 pr to test flaky test >From 3ec4d5b9e5bc24bfb466d65fd9c45c51fa6d3e94 Mon Sep 17 00:00:00 2001 From: PeterChou1 Date: Wed, 31 Jul 2024 14:52:11 -0400 Subject: [PATCH] [clang-doc] uncomment unsupported --- c

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 updated https://github.com/llvm/llvm-project/pull/101256 >From 7027cf254ae1b6acfdfbbf5dbeda3c4d6a4b3c43 Mon Sep 17 00:00:00 2001 From: Joshua Batista Date: Fri, 26 Jul 2024 15:41:01 -0700 Subject: [PATCH 1/8] first attempt --- clang/docs/LanguageExtensions.rst

[clang-tools-extra] [clang-doc] uncomment unsupported (PR #101387)

2024-07-31 Thread via cfe-commits
https://github.com/PeterChou1 updated https://github.com/llvm/llvm-project/pull/101387 >From 3ec4d5b9e5bc24bfb466d65fd9c45c51fa6d3e94 Mon Sep 17 00:00:00 2001 From: PeterChou1 Date: Wed, 31 Jul 2024 14:52:11 -0400 Subject: [PATCH] [clang-doc] uncomment unsupported --- clang-tools-extra/test/c

[clang-tools-extra] [clang-doc] fix flaky test in clang-doc (PR #101387)

2024-07-31 Thread via cfe-commits
https://github.com/PeterChou1 edited https://github.com/llvm/llvm-project/pull/101387 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lldb] [HLSL] Implement intangible AST type (PR #97362)

2024-07-31 Thread Helena Kotas via cfe-commits
@@ -1390,7 +1390,8 @@ void ASTContext::InitBuiltinTypes(const TargetInfo &Target, #include "clang/Basic/HLSLIntangibleTypes.def" } - if (Target.hasAArch64SVETypes()) { + if (Target.hasAArch64SVETypes() || hekota wrote: I don't see this change in this PR

[clang] [lldb] [HLSL] Implement intangible AST type (PR #97362)

2024-07-31 Thread Helena Kotas via cfe-commits
@@ -23,7 +23,7 @@ export module b; import a; export int b(); -// CHECK: https://github.com/llvm/llvm-project/pull/97362 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commi

[clang] [clang][NFC] Add CWG882 test (Defining `main` as deleted) (PR #101382)

2024-07-31 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll edited https://github.com/llvm/llvm-project/pull/101382 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][NFC] Add CWG882 test (Defining `main` as deleted) (PR #101382)

2024-07-31 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll requested changes to this pull request. https://github.com/llvm/llvm-project/pull/101382 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][NFC] Add CWG882 test (Defining `main` as deleted) (PR #101382)

2024-07-31 Thread Vlad Serebrennikov via cfe-commits
@@ -30,3 +30,8 @@ void g(int i) { } #endif } // namespace cwg873 + +// cwg882: 3.5 +int main() = delete; +// expected-error@-1 {{'main' is not allowed to be deleted}} +// cxx98-error@-2 {{deleted function definitions are a C++11 extension}} Endilll wrote: `del

[clang] [lldb] [HLSL] Implement intangible AST type (PR #97362)

2024-07-31 Thread Helena Kotas via cfe-commits
@@ -115,6 +116,18 @@ GlobalVariable *replaceBuffer(CGHLSLRuntime::Buffer &Buf) { } // namespace +llvm::Type *CGHLSLRuntime::convertHLSLSpecificType(const Type *T) { + assert(T->isHLSLSpecificType() && "Not an HLSL specific type!"); + + // Check if the target has a specific

[clang] [clang][LoongArch] Align global symbol by size (PR #101309)

2024-07-31 Thread Nikita Popov via cfe-commits
nikic wrote: I think for your use case you want to implement the shouldAlignPointerArgs() hook. It exists to allow raising GV/Alloca alignment for objects used inside memcpy and similar. Check out the ARM backend for an example. https://github.com/llvm/llvm-project/pull/101309

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 edited https://github.com/llvm/llvm-project/pull/101256 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 edited https://github.com/llvm/llvm-project/pull/101256 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Add length HLSL function to DirectX Backend (PR #101256)

2024-07-31 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 edited https://github.com/llvm/llvm-project/pull/101256 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [PPC] Implement BCD assist builtins (PR #101390)

2024-07-31 Thread Lei Huang via cfe-commits
https://github.com/lei137 created https://github.com/llvm/llvm-project/pull/101390 Implement BCD assist builtins for XL and GCC compatibility. GCC compat: ``` unsigned int __builtin_cdtbcd (unsigned int); unsigned int __builtin_cbcdtd (unsigned int); unsigned int __builtin_addg6s (unsigned int,

[clang] [llvm] [PPC] Implement BCD assist builtins (PR #101390)

2024-07-31 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-llvm-ir @llvm/pr-subscribers-clang Author: Lei Huang (lei137) Changes Implement BCD assist builtins for XL and GCC compatibility. GCC compat: ``` unsigned int __builtin_cdtbcd (unsigned int); unsigned int __builtin_cbcdtd (unsigned int); unsigned int __

[clang] [llvm] [PPC] Implement BCD assist builtins (PR #101390)

2024-07-31 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-powerpc Author: Lei Huang (lei137) Changes Implement BCD assist builtins for XL and GCC compatibility. GCC compat: ``` unsigned int __builtin_cdtbcd (unsigned int); unsigned int __builtin_cbcdtd (unsigned int); unsigned int __builtin_addg6s (uns

[clang] Fix amdgpu-arch for dll name on Windows (PR #101350)

2024-07-31 Thread Yaxun Liu via cfe-commits
https://github.com/yxsamliu updated https://github.com/llvm/llvm-project/pull/101350 >From e7c39dbcb05d8fa9232a68c90b0ec4fc4d2a126b Mon Sep 17 00:00:00 2001 From: "Yaxun (Sam) Liu" Date: Wed, 31 Jul 2024 09:23:05 -0400 Subject: [PATCH] Fix amdgpu-arch for dll name on Windows Recently HIP runti

[clang] Fix amdgpu-arch for dll name on Windows (PR #101350)

2024-07-31 Thread Yaxun Liu via cfe-commits
@@ -31,16 +43,108 @@ typedef hipError_t (*hipGetDeviceCount_t)(int *); typedef hipError_t (*hipDeviceGet_t)(int *, int); typedef hipError_t (*hipGetDeviceProperties_t)(hipDeviceProp_t *, int); -int printGPUsByHIP() { +extern cl::opt Verbose; + #ifdef _WIN32 - constexpr const

[clang] [clang][NFC] Add CWG882 test (Defining `main` as deleted) (PR #101382)

2024-07-31 Thread Mital Ashok via cfe-commits
https://github.com/MitalAshok updated https://github.com/llvm/llvm-project/pull/101382 >From 9dcbd0779bf379bbf62bf52247ef46de82cb4877 Mon Sep 17 00:00:00 2001 From: Mital Ashok Date: Wed, 31 Jul 2024 19:18:09 +0100 Subject: [PATCH 1/2] [clang][Tests][NFC] Add CWG882 test (Defining `main` as de

[clang] [libc] [Clang] Suppress missing architecture error when doing LTO (PR #100652)

2024-07-31 Thread Yaxun Liu via cfe-commits
https://github.com/yxsamliu approved this pull request. https://github.com/llvm/llvm-project/pull/100652 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [PPC] Disable vsx and altivec when -msoft-float is used (PR #100450)

2024-07-31 Thread Zaara Syeda via cfe-commits
https://github.com/syzaara updated https://github.com/llvm/llvm-project/pull/100450 >From eac208b559feb3ccdfbd1d2ee6bcdd20db32f6a7 Mon Sep 17 00:00:00 2001 From: Zaara Syeda Date: Wed, 24 Jul 2024 14:58:53 -0400 Subject: [PATCH 1/3] [PPC] Disable vsx and altivec when -msoft-float is used ---

[clang] [PPC] Disable vsx and altivec when -msoft-float is used (PR #100450)

2024-07-31 Thread Zaara Syeda via cfe-commits
https://github.com/syzaara edited https://github.com/llvm/llvm-project/pull/100450 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libcxx] [Clang] Add __common_type builtin (PR #99473)

2024-07-31 Thread Nikolas Klauser via cfe-commits
https://github.com/philnik777 commented: > How much of a performance difference are you measuring with this change? That depends heavily on what you're looking at. For `common_type`s with a lot of builtin types, I've seen a 10x improvement. When it's basically just combining specializations I'

[clang] [libcxx] [Clang] Add __common_type builtin (PR #99473)

2024-07-31 Thread Nikolas Klauser via cfe-commits
@@ -3058,6 +3058,133 @@ void Sema::NoteAllFoundTemplates(TemplateName Name) { } } +static QualType commonTypeImpl(Sema &S, TemplateName BaseTemplate, + SourceLocation TemplateLoc, + ArrayRef Ts) { + auto lookUpComm

[clang] [libcxx] [Clang] Add __common_type builtin (PR #99473)

2024-07-31 Thread Nikolas Klauser via cfe-commits
@@ -3058,6 +3058,133 @@ void Sema::NoteAllFoundTemplates(TemplateName Name) { } } +static QualType commonTypeImpl(Sema &S, TemplateName BaseTemplate, + SourceLocation TemplateLoc, + ArrayRef Ts) { + auto lookUpComm

[clang] [libcxx] [Clang] Add __common_type builtin (PR #99473)

2024-07-31 Thread Nikolas Klauser via cfe-commits
https://github.com/philnik777 updated https://github.com/llvm/llvm-project/pull/99473 >From d6903daf0da6979822b8981ea3641455ff6d06f8 Mon Sep 17 00:00:00 2001 From: Nikolas Klauser Date: Tue, 16 Jul 2024 14:48:10 +0200 Subject: [PATCH 1/5] [Clang] Add __common_type builtin --- clang/include/cl

[clang] [libcxx] [Clang] Add __common_type builtin (PR #99473)

2024-07-31 Thread Nikolas Klauser via cfe-commits
https://github.com/philnik777 edited https://github.com/llvm/llvm-project/pull/99473 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libcxx] [Clang] Add __common_type builtin (PR #99473)

2024-07-31 Thread Nikolas Klauser via cfe-commits
@@ -3058,6 +3058,133 @@ void Sema::NoteAllFoundTemplates(TemplateName Name) { } } +static QualType commonTypeImpl(Sema &S, TemplateName BaseTemplate, + SourceLocation TemplateLoc, + ArrayRef Ts) { + auto lookUpComm

[clang] [clang] create class-type injected NTTP with correct value kind (PR #101395)

2024-07-31 Thread Matheus Izvekov via cfe-commits
https://github.com/mizvekov created https://github.com/llvm/llvm-project/pull/101395 A template parameter object is an lvalue, which was not being respected for injected parameters. Fixes GH101394 >From 2d6d367408277b912c3db09cbbc7398c247c32c5 Mon Sep 17 00:00:00 2001 From: Matheus Izvekov D

[clang] [clang] create class-type injected NTTP with correct value kind (PR #101395)

2024-07-31 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Matheus Izvekov (mizvekov) Changes A template parameter object is an lvalue, which was not being respected for injected parameters. Fixes GH101394 --- Full diff: https://github.com/llvm/llvm-project/pull/101395.diff 4 Files Affected:

[clang] [clang][NFC] Add CWG882 test (Defining `main` as deleted) (PR #101382)

2024-07-31 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll approved this pull request. https://github.com/llvm/llvm-project/pull/101382 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][NFC] Add CWG882 test (Defining `main` as deleted) (PR #101382)

2024-07-31 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: Do you want this to be merged once CI passes? https://github.com/llvm/llvm-project/pull/101382 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [OpenMP]Generate implicit default mapper for mapping array section. (PR #101101)

2024-07-31 Thread via cfe-commits
https://github.com/jyu2-git updated https://github.com/llvm/llvm-project/pull/101101 >From 1f6c326c6b93ebdbb9f4b35adfc903409ab67620 Mon Sep 17 00:00:00 2001 From: Jennifer Yu Date: Mon, 29 Jul 2024 14:18:48 -0700 Subject: [PATCH 1/4] Generate implicit default mapper for mapping array section.

[clang] [llvm] [OpenMP]Generate implicit default mapper for mapping array section. (PR #101101)

2024-07-31 Thread via cfe-commits
@@ -5556,6 +5556,7 @@ class OMPMappableExprListClause : public OMPVarListClause, MapperIdInfo = MapperId; } +public: jyu2-git wrote: Thanks Alexey! I changed! Instead generate implicit mapper during map creation. https://github.com/llvm/llvm-projec

[clang] [llvm] [OpenMP]Generate implicit default mapper for mapping array section. (PR #101101)

2024-07-31 Thread via cfe-commits
https://github.com/jyu2-git updated https://github.com/llvm/llvm-project/pull/101101 >From 1f6c326c6b93ebdbb9f4b35adfc903409ab67620 Mon Sep 17 00:00:00 2001 From: Jennifer Yu Date: Mon, 29 Jul 2024 14:18:48 -0700 Subject: [PATCH 1/5] Generate implicit default mapper for mapping array section.

[clang] [clang] create class-type injected NTTP with correct value kind (PR #101395)

2024-07-31 Thread Matheus Izvekov via cfe-commits
https://github.com/mizvekov edited https://github.com/llvm/llvm-project/pull/101395 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-doc] fix flaky test in clang-doc (PR #101387)

2024-07-31 Thread Paul Kirth via cfe-commits
ilovepi wrote: This isn't fixing anything. Its re-enabling it. I'd also suggest adding people from that bug as reviewers to help you get this re-enabled. https://github.com/llvm/llvm-project/pull/101387 ___ cfe-commits mailing list cfe-commits@lists.l

[clang] [Clang] [NFC] Fix potential dereferencing of nullptr (PR #101405)

2024-07-31 Thread via cfe-commits
https://github.com/smanna12 created https://github.com/llvm/llvm-project/pull/101405 This patch replaces getAs<> with castAs<> and dyn_cast<> with cast<>. >From acd513e3abcc5eb028db99409b73aa2fcfd8b47f Mon Sep 17 00:00:00 2001 From: "Manna, Soumi" Date: Wed, 31 Jul 2024 13:21:09 -0700 Subject:

[clang] [Clang] [NFC] Fix potential dereferencing of nullptr (PR #101405)

2024-07-31 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-codegen Author: None (smanna12) Changes This patch replaces getAs<> with castAs<> and dyn_cast<> with cast<>. --- Full diff: https://github.com/llvm/llvm-project/pull/101405.diff 2 Files Affected: - (modified) clang/lib/AST/ASTContext.cpp (+2-

[clang] [clang] Implement type/address discrimination of type_info vtable. (PR #99726)

2024-07-31 Thread Daniil Kovalev via cfe-commits
@@ -0,0 +1,87 @@ +// RUN: %clang_cc1 -DENABLE_TID=0 -I%S -std=c++11 -triple=arm64e-apple-darwin \ +// RUN: -fptrauth-calls -fptrauth-intrinsics \ +// RUN: -fptrauth-vtable-pointer-type-discrimination \ +// RUN: -fptrauth-vtable-pointer-address-discrimination \ +// RUN: %s

[clang-tools-extra] [clang-doc] fix flaky test in clang-doc (PR #101387)

2024-07-31 Thread via cfe-commits
PeterChou1 wrote: > This isn't fixing anything. Its re-enabling it. I'd also suggest adding > people from that bug as reviewers to help you get this re-enabled. This was just meant as an experiment to check what was failing in the CI pipeline https://github.com/llvm/llvm-project/pull/101387 _

[clang] [llvm] [OpenMP]Generate implicit default mapper for mapping array section. (PR #101101)

2024-07-31 Thread via cfe-commits
https://github.com/jyu2-git edited https://github.com/llvm/llvm-project/pull/101101 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-doc] fix flaky test in clang-doc (PR #101387)

2024-07-31 Thread via cfe-commits
https://github.com/PeterChou1 edited https://github.com/llvm/llvm-project/pull/101387 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [compiler-rt] [lldb] [llvm] [Support] Remove terminfo dependency (PR #92865)

2024-07-31 Thread Bernhard Kaindl via cfe-commits
bernhardkaindl wrote: @JDevlieghere, you wrote: > No objections in the context of LLDB. We don't use terminfo directly > (although I think editline does, but that isn't affected by this) and if we > want the TUI we depend on curses anyway. You truly use `libtinfo` directly in LLDB: ```py # g

[clang] [Clang][Sema][OpenMP] Allow `num_teams` to accept multiple expressions (PR #99732)

2024-07-31 Thread Shilei Tian via cfe-commits
https://github.com/shiltian updated https://github.com/llvm/llvm-project/pull/99732 >From 0906b80d32e802865238f74101b23a2ea494f835 Mon Sep 17 00:00:00 2001 From: Shilei Tian Date: Fri, 19 Jul 2024 22:07:06 -0400 Subject: [PATCH] [Clang][OpenMP] Allow `num_teams` to accept multiple expressions

[clang] [Clang][Sema][OpenMP] Allow `num_teams` to accept multiple expressions (PR #99732)

2024-07-31 Thread Shilei Tian via cfe-commits
https://github.com/shiltian edited https://github.com/llvm/llvm-project/pull/99732 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][Sema][OpenMP] Allow `num_teams` to accept multiple expressions (PR #99732)

2024-07-31 Thread Shilei Tian via cfe-commits
@@ -13004,13 +13004,34 @@ StmtResult SemaOpenMP::ActOnOpenMPTargetUpdateDirective( Clauses, AStmt); } +// This checks whether num_teams clause only has one expression. +static bool checkNumTeamsClauseSingleExpr(SemaBase &SemaRef,

[clang] [Clang][Sema][OpenMP] Allow `num_teams` to accept multiple expressions (PR #99732)

2024-07-31 Thread Shilei Tian via cfe-commits
https://github.com/shiltian updated https://github.com/llvm/llvm-project/pull/99732 >From fefe6d36301f93097e73725876e89235a279225d Mon Sep 17 00:00:00 2001 From: Shilei Tian Date: Fri, 19 Jul 2024 22:07:06 -0400 Subject: [PATCH] [Clang][OpenMP] Allow `num_teams` to accept multiple expressions

[clang] [compiler-rt] [lldb] [llvm] [Support] Remove terminfo dependency (PR #92865)

2024-07-31 Thread Jonas Devlieghere via cfe-commits
JDevlieghere wrote: What I said was that, to the best of my knowledge, we don't have places in LLDB that rely on `terminfo` but not on `ncruses`. I think that statement still holds true. The assumption behind it was that `ncurses` provides a superset of the functionality provided by `terminfo`

[clang] [NFC][Clang] Clean up VisitUnaryPlus by removing unused FP feature check (PR #101412)

2024-07-31 Thread via cfe-commits
https://github.com/smanna12 created https://github.com/llvm/llvm-project/pull/101412 This commit removes an unnecessary call to `E->hasStoredFPFeatures()` within the `VisitUnaryPlus` function. The method's return value was not being used, leading to a redundant operation. The removal of this l

[clang] [NFC][Clang] Clean up VisitUnaryPlus by removing unused FP feature check (PR #101412)

2024-07-31 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-codegen Author: None (smanna12) Changes This commit removes an unnecessary call to `E->hasStoredFPFeatures()` within the `VisitUnaryPlus` function. The method's return value was not being used, leading to a redundant operation. The removal of thi

[clang] [HIP] Fix __clang_hip_cmath.hip for ambiguity (PR #101341)

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

[clang] [clang] Make serialized diagnostics more reliable (PR #100681)

2024-07-31 Thread Michael Spencer via cfe-commits
Bigcheese wrote: > Could we simplify this even further by removing > `DiagnosticConsumer::finish()` entirely, moving the code in > `SDiagsWriter::finish()` to `SDiagsWriter::~SDiagsWriter()` and ensuring the > **destructor** gets called even with `-disable-free`? This is doable, but I'm not s

[clang] [clang][CodeGen] The linux kernel expects initializers to FULLY initialize variables, structs and unions including padding (PR #97121)

2024-07-31 Thread John McCall via cfe-commits
https://github.com/rjmccall commented: Is this really all that's required? It looks like you're just filling in explicit zero padding when emitting constant initializers. That should steer clear of any possibility that LLVM would treat the padding as `undef` for optimization purposes (surely

[clang] [clang][CodeGen] The linux kernel expects initializers to FULLY initialize variables, structs and unions including padding (PR #97121)

2024-07-31 Thread John McCall via cfe-commits
https://github.com/rjmccall edited https://github.com/llvm/llvm-project/pull/97121 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][CodeGen] The linux kernel expects initializers to FULLY initialize variables, structs and unions including padding (PR #97121)

2024-07-31 Thread John McCall via cfe-commits
@@ -361,6 +368,13 @@ CodeGenFunction::AddInitializerToStaticVarDecl(const VarDecl &D, } return GV; } + if (!getLangOpts().CPlusPlus) { +// In C, when an initializer is given, the Linux kernel relies on clang to +// zero-initialize all members not explicitly

[clang] [clang][CodeGen] The linux kernel expects initializers to FULLY initialize variables, structs and unions including padding (PR #97121)

2024-07-31 Thread John McCall via cfe-commits
@@ -361,6 +368,13 @@ CodeGenFunction::AddInitializerToStaticVarDecl(const VarDecl &D, } return GV; } + if (!getLangOpts().CPlusPlus) { +// In C, when an initializer is given, the Linux kernel relies on clang to +// zero-initialize all members not explicitly

[clang] [Clang] [NFC] Fix potential dereferencing of nullptr (PR #101405)

2024-07-31 Thread via cfe-commits
smanna12 wrote: Thanks @tahonermann for reviews! https://github.com/llvm/llvm-project/pull/101405 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang] Clean up VisitUnaryPlus by removing unused FP feature check (PR #101412)

2024-07-31 Thread Zahira Ammarguellat via cfe-commits
https://github.com/zahiraam approved this pull request. LGTM. This is dead code. Thanks Soumi! https://github.com/llvm/llvm-project/pull/101412 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-

[clang] [llvm] [LV] Support generating masks for switch terminators. (PR #99808)

2024-07-31 Thread Kolya Panchenko via cfe-commits
@@ -6,9 +6,43 @@ define void @switch_default_to_latch_common_dest(ptr %start, ptr %end) { ; IC1-LABEL: define void @switch_default_to_latch_common_dest( ; IC1-SAME: ptr [[START:%.*]], ptr [[END:%.*]]) #[[ATTR0:[0-9]+]] { ; IC1-NEXT: [[ENTRY:.*]]: +; IC1-NEXT:[[START2:%.*]

[clang] [llvm] [LV] Support generating masks for switch terminators. (PR #99808)

2024-07-31 Thread Kolya Panchenko via cfe-commits
https://github.com/nikolaypanchenko edited https://github.com/llvm/llvm-project/pull/99808 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [LV] Support generating masks for switch terminators. (PR #99808)

2024-07-31 Thread Kolya Panchenko via cfe-commits
https://github.com/nikolaypanchenko commented: Add tests for vplan printing ? https://github.com/llvm/llvm-project/pull/99808 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [LV] Support generating masks for switch terminators. (PR #99808)

2024-07-31 Thread Kolya Panchenko via cfe-commits
@@ -7763,6 +7763,41 @@ VPValue *VPRecipeBuilder::createEdgeMask(BasicBlock *Src, BasicBlock *Dst) { VPValue *SrcMask = getBlockInMask(Src); + if (auto *SI = dyn_cast(Src->getTerminator())) { +// Create mask where the terminator in Src is a switch. We need to handle 2

<    1   2   3   4   5   >