[clang] fb21343 - [C++20] [Modules] Don't skip pragma diagnostic mappings

2024-04-29 Thread Chuanqi Xu via cfe-commits
Author: Chuanqi Xu Date: 2024-04-30T13:50:20+08:00 New Revision: fb21343473e33e9a886b42d2fe95d1cec1cd0030 URL: https://github.com/llvm/llvm-project/commit/fb21343473e33e9a886b42d2fe95d1cec1cd0030 DIFF: https://github.com/llvm/llvm-project/commit/fb21343473e33e9a886b42d2fe95d1cec1cd0030.diff

[clang] 18268ac - [NFC] [C++20] [Modules] Use new class CXX20ModulesGenerator to generate module file for C++20 modules instead of PCHGenerator

2024-04-29 Thread Chuanqi Xu via cfe-commits
Author: Chuanqi Xu Date: 2024-04-30T13:30:31+08:00 New Revision: 18268ac0f48d93c2bcddb69732761971669c09ab URL: https://github.com/llvm/llvm-project/commit/18268ac0f48d93c2bcddb69732761971669c09ab DIFF: https://github.com/llvm/llvm-project/commit/18268ac0f48d93c2bcddb69732761971669c09ab.diff

[clang-tools-extra] [clang-tidy] fix false-negative for macros in `readability-math-missing-parentheses` (PR #90279)

2024-04-29 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL closed https://github.com/llvm/llvm-project/pull/90279 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] fbe4d99 - [clang-tidy] fix false-negative for macros in `readability-math-missing-parentheses` (#90279)

2024-04-29 Thread via cfe-commits
Author: Julian Schmidt Date: 2024-04-30T07:22:30+02:00 New Revision: fbe4d991323b026eb64cd3d0ee811854b54ca33f URL: https://github.com/llvm/llvm-project/commit/fbe4d991323b026eb64cd3d0ee811854b54ca33f DIFF:

[clang-tools-extra] [clang-tidy] Relax readability-const-return-type (PR #90560)

2024-04-29 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tidy @llvm/pr-subscribers-clang-tools-extra Author: Piotr Zegar (PiotrZSL) Changes >From now readability-const-return-type won't provide warnings for returning >const types, where const is not on top level. In such case const there is a

[clang-tools-extra] [clang-tidy] Relax readability-const-return-type (PR #90560)

2024-04-29 Thread Piotr Zegar via cfe-commits
https://github.com/PiotrZSL created https://github.com/llvm/llvm-project/pull/90560 >From now readability-const-return-type won't provide warnings for returning >const types, where const is not on top level. In such case const there is a >performance issue, but not a readability. Closes

[clang] [X86_64] Fix empty field error in vaarg of C++. (PR #90389)

2024-04-29 Thread Longsheng Mou via cfe-commits
https://github.com/CoTinker updated https://github.com/llvm/llvm-project/pull/90389 >From db18c52f8fd5f397324505bcb2e07343794e5dce Mon Sep 17 00:00:00 2001 From: Longsheng Mou Date: Sun, 28 Apr 2024 17:14:29 +0800 Subject: [PATCH] [X86_64] Fix empty field error in vaarg of C++. Such struct

[clang] [clang-tools-extra] [llvm] Add ``ignoringParenImpCasts`` in arguments of hasArgument (PR #89553)

2024-04-29 Thread Piotr Zegar via cfe-commits
@@ -0,0 +1,72 @@ +set(CMAKE_C_COMPILER "/usr/bin/cc") PiotrZSL wrote: Looks like simple mistake, plee remove that build directory from a change. https://github.com/llvm/llvm-project/pull/89553 ___ cfe-commits mailing

[clang] [clang-format] Fix a bug in annotating struct braces (PR #90555)

2024-04-29 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Author: Owen Pan (owenca) Changes Fixes #60040. --- Full diff: https://github.com/llvm/llvm-project/pull/90555.diff 2 Files Affected: - (modified) clang/lib/Format/UnwrappedLineParser.cpp (+4-1) - (modified)

[clang] [clang-format] Fix a bug in annotating struct braces (PR #90555)

2024-04-29 Thread Owen Pan via cfe-commits
https://github.com/owenca created https://github.com/llvm/llvm-project/pull/90555 Fixes #60040. >From 77d807d47d47ca9916edc03182e1952c27300a8a Mon Sep 17 00:00:00 2001 From: Owen Pan Date: Mon, 29 Apr 2024 21:11:28 -0700 Subject: [PATCH] [clang-format] Fix a bug in annotating struct braces

[clang] [CUDA] make kernel stub ICF-proof (PR #90155)

2024-04-29 Thread Yaxun Liu via cfe-commits
https://github.com/yxsamliu updated https://github.com/llvm/llvm-project/pull/90155 >From 7a741109a6769e2e91d77a82d9a44c7f9c212c48 Mon Sep 17 00:00:00 2001 From: "Yaxun (Sam) Liu" Date: Thu, 25 Apr 2024 22:23:26 -0400 Subject: [PATCH] [CUDA] make kernel stub ICF-proof MSVC linker may merge

[clang] [llvm] [RISCV] Teach .option arch to support experimental extensions. (PR #89727)

2024-04-29 Thread Yeting Kuo via cfe-commits
@@ -169,6 +169,9 @@ void riscv::getRISCVTargetFeatures(const Driver , const llvm::Triple , Features.push_back("-relax"); } + if (!Args.hasArg(options::OPT_menable_experimental_extensions)) +Features.push_back("+no-experimental-ext"); yetingk

[clang] [llvm] [RISCV] Teach .option arch to support experimental extensions. (PR #89727)

2024-04-29 Thread Yeting Kuo via cfe-commits
https://github.com/yetingk updated https://github.com/llvm/llvm-project/pull/89727 >From a43014cf3daa1b0fd9092bfe41da979205ba64aa Mon Sep 17 00:00:00 2001 From: Yeting Kuo Date: Tue, 23 Apr 2024 02:16:04 -0700 Subject: [PATCH 1/4] [RISCV] Teach .option arch to support experimental extensions.

[clang] [llvm] [mlir] [Clang][CodeGen] Start migrating away from assuming the Default AS is 0 (PR #88182)

2024-04-29 Thread Alexander Richardson via cfe-commits
@@ -0,0 +1,288 @@ +// RUN: %clang_cc1 %s -triple=spirv64-unknown-unknown -fsycl-is-device -std=c++11 -emit-llvm -o %t.ll -O1 -disable-llvm-passes -fms-extensions -fstrict-vtable-pointers +// FIXME: Assume load should not require -fstrict-vtable-pointers + +// RUN: FileCheck

[clang] [llvm] [mlir] [Clang][CodeGen] Start migrating away from assuming the Default AS is 0 (PR #88182)

2024-04-29 Thread Alexander Richardson via cfe-commits
https://github.com/arichardson commented: Spotted one more duplicate test, otherwise looks good to me with the reworded TODO comment suggestion. https://github.com/llvm/llvm-project/pull/88182 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [llvm] [mlir] [Clang][CodeGen] Start migrating away from assuming the Default AS is 0 (PR #88182)

2024-04-29 Thread Alexander Richardson via cfe-commits
@@ -1370,7 +1370,7 @@ let IntrProperties = [IntrNoMem, IntrSpeculatable, IntrWillReturn] in { // The result of eh.typeid.for depends on the enclosing function, but inside a // given function it is 'const' and may be CSE'd etc. -def int_eh_typeid_for :

[clang] [llvm] [mlir] [Clang][CodeGen] Start migrating away from assuming the Default AS is 0 (PR #88182)

2024-04-29 Thread Alexander Richardson via cfe-commits
@@ -0,0 +1,288 @@ +// RUN: %clang_cc1 %s -triple=spirv64-unknown-unknown -fsycl-is-device -std=c++11 -emit-llvm -o %t.ll -O1 -disable-llvm-passes -fms-extensions -fstrict-vtable-pointers +// FIXME: Assume load should not require -fstrict-vtable-pointers + +// RUN: FileCheck

[clang] [llvm] [mlir] [Clang][CodeGen] Start migrating away from assuming the Default AS is 0 (PR #88182)

2024-04-29 Thread Alexander Richardson via cfe-commits
https://github.com/arichardson edited https://github.com/llvm/llvm-project/pull/88182 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [mlir] [Clang][CodeGen] Start migrating away from assuming the Default AS is 0 (PR #88182)

2024-04-29 Thread Alexander Richardson via cfe-commits
@@ -0,0 +1,288 @@ +// RUN: %clang_cc1 %s -triple=spirv64-unknown-unknown -fsycl-is-device -std=c++11 -emit-llvm -o %t.ll -O1 -disable-llvm-passes -fms-extensions -fstrict-vtable-pointers arichardson wrote: This test should be merged with the existing

[clang] 38067c5 - [C++20] [Modules] [Reduced BMI] Avoid force writing static declarations

2024-04-29 Thread Chuanqi Xu via cfe-commits
Author: Chuanqi Xu Date: 2024-04-30T11:34:34+08:00 New Revision: 38067c50a9459caed2892e38b2ae5026a8bff8e2 URL: https://github.com/llvm/llvm-project/commit/38067c50a9459caed2892e38b2ae5026a8bff8e2 DIFF: https://github.com/llvm/llvm-project/commit/38067c50a9459caed2892e38b2ae5026a8bff8e2.diff

[clang] Skip over std namespace in WebKit checkers. (PR #90552)

2024-04-29 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Ryosuke Niwa (rniwa) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/90552.diff 4 Files Affected: - (modified) clang/lib/StaticAnalyzer/Checkers/WebKit/UncountedCallArgsChecker.cpp (+6) - (modified)

[clang] Skip over std namespace in WebKit checkers. (PR #90552)

2024-04-29 Thread Ryosuke Niwa via cfe-commits
https://github.com/rniwa created https://github.com/llvm/llvm-project/pull/90552 None >From fa7a6e376b07ae6262dd06920c87dc69705a646d Mon Sep 17 00:00:00 2001 From: Ryosuke Niwa Date: Mon, 29 Apr 2024 20:24:24 -0700 Subject: [PATCH] Skip over std namespace in WebKit checkers. ---

[clang] [Coroutines][Test] Specify target triple in coro-elide-thinlto (PR #90549)

2024-04-29 Thread Wei Wang via cfe-commits
https://github.com/apolloww updated https://github.com/llvm/llvm-project/pull/90549 >From 1fac46855bf6bb3feb2e8b7a0918e61c8468ea07 Mon Sep 17 00:00:00 2001 From: Wei Wang Date: Mon, 29 Apr 2024 20:01:29 -0700 Subject: [PATCH] fix build failure ---

[clang] [Coroutines][Test] Specify target triple in coro-elide-thinlto (PR #90549)

2024-04-29 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. https://github.com/llvm/llvm-project/pull/90549 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Coroutines][Test] Specify target triple in coro-elide-thinlto (PR #90549)

2024-04-29 Thread Wei Wang via cfe-commits
apolloww wrote: This should make Buildbot failure like https://lab.llvm.org/buildbot/#/builders/38/builds/19079 to go away ``` warning: linking module 'coro-elide-caller.o': Linking two modules of different target triples: 'coro-elide-callee.o' is 'x86_64-unknown-linux' whereas

[clang] [Coroutines][Test] Specify target triple in coro-elide-thinlto (PR #90549)

2024-04-29 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-coroutines @llvm/pr-subscribers-clang Author: Wei Wang (apolloww) Changes Resolve test failure on non-x86 linux host --- Full diff: https://github.com/llvm/llvm-project/pull/90549.diff 1 Files Affected: - (modified)

[clang] [Coroutines][Test] Specify target triple in coro-elide-thinlto (PR #90549)

2024-04-29 Thread Wei Wang via cfe-commits
https://github.com/apolloww created https://github.com/llvm/llvm-project/pull/90549 Resolve test failure on non-x86 linux host >From 4cdba5174c49682502e65d6f10224bb2bc54f346 Mon Sep 17 00:00:00 2001 From: Wei Wang Date: Mon, 29 Apr 2024 20:01:29 -0700 Subject: [PATCH] fix build failure ---

[clang] [CUDA] make kernel stub ICF-proof (PR #90155)

2024-04-29 Thread Yaxun Liu via cfe-commits
@@ -424,6 +424,34 @@ void CGNVCUDARuntime::emitDeviceStubBodyNew(CodeGenFunction , CGM.CreateRuntimeFunction(FTy, LaunchKernelName); CGF.EmitCall(FI, CGCallee::forDirect(cudaLaunchKernelFn), ReturnValueSlot(), LaunchKernelArgs); + + // To prevent CUDA

[clang] [Clang][Sema] Do not accept "vector _Complex" for AltiVec/ZVector (PR #90467)

2024-04-29 Thread Chen Zheng via cfe-commits
@@ -111,6 +111,20 @@ vector __bool long long v_bll4; // expected-error {{use of 'long long' with #endif __vector long double vv_ld3;// expected-error {{cannot use 'long double' with '__vector'}} vector long double v_ld4; // expected-error {{cannot

[clang] [Clang][Sema] Do not accept "vector _Complex" for AltiVec/ZVector (PR #90467)

2024-04-29 Thread Chen Zheng via cfe-commits
@@ -1191,6 +1191,10 @@ void DeclSpec::Finish(Sema , const PrintingPolicy ) { // Validate and finalize AltiVec vector declspec. if (TypeAltiVecVector) { +// Complex vector types are not supported. +if (TypeSpecComplex != TSC_unspecified) + S.Diag(TSCLoc,

[clang] [Clang][Sema] Do not accept "vector _Complex" for AltiVec/ZVector (PR #90467)

2024-04-29 Thread Chen Zheng via cfe-commits
https://github.com/chenzheng1030 commented: Thanks very much for taking care of PPC. https://github.com/llvm/llvm-project/pull/90467 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][Sema] Do not accept "vector _Complex" for AltiVec/ZVector (PR #90467)

2024-04-29 Thread Chen Zheng via cfe-commits
https://github.com/chenzheng1030 edited https://github.com/llvm/llvm-project/pull/90467 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CUDA] make kernel stub ICF-proof (PR #90155)

2024-04-29 Thread Yaxun Liu via cfe-commits
@@ -424,6 +424,34 @@ void CGNVCUDARuntime::emitDeviceStubBodyNew(CodeGenFunction , CGM.CreateRuntimeFunction(FTy, LaunchKernelName); CGF.EmitCall(FI, CGCallee::forDirect(cudaLaunchKernelFn), ReturnValueSlot(), LaunchKernelArgs); + + // To prevent CUDA

[clang] [CUDA] make kernel stub ICF-proof (PR #90155)

2024-04-29 Thread Yaxun Liu via cfe-commits
@@ -424,6 +424,34 @@ void CGNVCUDARuntime::emitDeviceStubBodyNew(CodeGenFunction , CGM.CreateRuntimeFunction(FTy, LaunchKernelName); CGF.EmitCall(FI, CGCallee::forDirect(cudaLaunchKernelFn), ReturnValueSlot(), LaunchKernelArgs); + + // To prevent CUDA

[clang] [clang] fix half && bfloat16 convert node expr codegen (PR #89051)

2024-04-29 Thread via cfe-commits
JinjinLi868 wrote: ping https://github.com/llvm/llvm-project/pull/89051 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][CodeGen] Fix MSVC ABI for classes with non static data members of reference type (PR #90547)

2024-04-29 Thread Max Winkler via cfe-commits
@@ -1144,11 +1167,13 @@ bool MicrosoftCXXABI::classifyReturnType(CGFunctionInfo ) const { if (!RD) return false; - bool isTrivialForABI = RD->canPassInRegisters() && - isTrivialForMSVC(RD, FI.getReturnType(), CGM); - // MSVC always returns

[clang] [clang][CodeGen] Fix MSVC ABI for classes with non static data members of reference type (PR #90547)

2024-04-29 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-codegen Author: Max Winkler (MaxEW707) Changes https://godbolt.org/z/verKj4cnj for reference. https://godbolt.org/z/z3W9v7o4n for reference. For global functions and static methods the MSVC ABI returns structs/classes with a reference type non

[clang] [clang][CodeGen] Fix MSVC ABI for classes with non static data members of reference type (PR #90547)

2024-04-29 Thread Max Winkler via cfe-commits
https://github.com/MaxEW707 created https://github.com/llvm/llvm-project/pull/90547 https://godbolt.org/z/verKj4cnj for reference. https://godbolt.org/z/z3W9v7o4n for reference. For global functions and static methods the MSVC ABI returns structs/classes with a reference type non static data

[clang] [llvm] [coro] Lower `llvm.coro.await.suspend.handle` to resume with tail call (PR #89751)

2024-04-29 Thread Chuanqi Xu via cfe-commits
@@ -1056,6 +1083,25 @@ void CoroCloner::create() { // Set up the new entry block. replaceEntryBlock(); + // Turn symmetric transfers into musttail calls. + for (CallInst *ResumeCall : Shape.SymmetricTransfers) { +ResumeCall = cast(VMap[ResumeCall]); +

[clang] [BoundsSafety] WIP: Make 'counted_by' work for pointer fields; late parsing for 'counted_by' on decl attr position (PR #87596)

2024-04-29 Thread Dan Liew via cfe-commits
https://github.com/delcypher updated https://github.com/llvm/llvm-project/pull/87596 >From 03266b74d973075eb5dfa27f32bb9c1bb75d73f9 Mon Sep 17 00:00:00 2001 From: Dan Liew Date: Mon, 29 Apr 2024 16:46:31 -0700 Subject: [PATCH 1/3] [BoundsSafety] Allow 'counted_by' attribute on pointers in

[clang] [Attributes] Support Attributes being declared as supporting an experimental late parsing mode "extension" (PR #88596)

2024-04-29 Thread Dan Liew via cfe-commits
https://github.com/delcypher closed https://github.com/llvm/llvm-project/pull/88596 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] b1867e1 - [Attributes] Support Attributes being declared as supporting an experimental late parsing mode "extension" (#88596)

2024-04-29 Thread via cfe-commits
Author: Dan Liew Date: 2024-04-29T18:37:47-07:00 New Revision: b1867e18c346e9621e14270bea2d1acb7d2a9ce0 URL: https://github.com/llvm/llvm-project/commit/b1867e18c346e9621e14270bea2d1acb7d2a9ce0 DIFF: https://github.com/llvm/llvm-project/commit/b1867e18c346e9621e14270bea2d1acb7d2a9ce0.diff

[clang] [Attributes] Support Attributes being declared as supporting an experimental late parsing mode "extension" (PR #88596)

2024-04-29 Thread Dan Liew via cfe-commits
delcypher wrote: @erichkeane Thanks for approving. I'll rebase, check this builds and then land this. @AaronBallman When you're back please let me know if there's any follow up changes you want. https://github.com/llvm/llvm-project/pull/88596 ___

[clang] [Attributes] Support Attributes being declared as supporting an experimental late parsing mode "extension" (PR #88596)

2024-04-29 Thread Dan Liew via cfe-commits
https://github.com/delcypher updated https://github.com/llvm/llvm-project/pull/88596 >From 07ab74ac8829e6c3e4365e1a87148d21800437d3 Mon Sep 17 00:00:00 2001 From: Dan Liew Date: Tue, 23 Apr 2024 14:57:46 -0700 Subject: [PATCH] [Attributes] Support Attributes being declared as supporting an

[clang] [BoundsSafety] WIP: Make 'counted_by' work for pointer fields; late parsing for 'counted_by' on decl attr position (PR #87596)

2024-04-29 Thread Dan Liew via cfe-commits
https://github.com/delcypher updated https://github.com/llvm/llvm-project/pull/87596 >From b859cf056df24daa85f3fd305ef56f32e0f266ed Mon Sep 17 00:00:00 2001 From: Dan Liew Date: Fri, 12 Apr 2024 17:36:19 -0700 Subject: [PATCH 1/4] [Attributes] Support Attributes being declared as supporting

[clang] [llvm] [x86] Add tan intrinsic part 4 (PR #90503)

2024-04-29 Thread Craig Topper via cfe-commits
@@ -654,6 +655,7 @@ X86TargetLowering::X86TargetLowering(const X86TargetMachine , setOperationAction(ISD::FSIN , VT, Expand); setOperationAction(ISD::FCOS , VT, Expand); setOperationAction(ISD::FSINCOS, VT, Expand); + setOperationAction(ISD::FTAN,

[clang] [Clang] Implement P2809: Trivial infinite loops are not Undefined Behavior (PR #90066)

2024-04-29 Thread via cfe-commits
yronglin wrote: I'd like to add the test case from the paper: ``` #include int main() { while (true) ; } void unreachable() { std::cout << "Hello world!" << std::endl; } ``` https://github.com/llvm/llvm-project/pull/90066 ___ cfe-commits

[clang] [llvm] Implement resource binding type prefix mismatch errors (PR #87578)

2024-04-29 Thread Tex Riddell via cfe-commits
@@ -44,7 +44,7 @@ void foo2() { // expected-warning@+1 {{'register' attribute only applies to cbuffer/tbuffer and external global variables}} extern RWBuffer U2 : register(u5); } -// FIXME: expect-error once fix https://github.com/llvm/llvm-project/issues/57886. +//

[clang] [llvm] [x86] Add tan intrinsic part 4 (PR #90503)

2024-04-29 Thread Farzon Lotfi via cfe-commits
@@ -674,6 +674,9 @@ # DEBUG-NEXT: .. opcode {{[0-9]+}} is aliased to {{[0-9]+}} # DEBUG-NEXT: .. the first uncovered type index: 1, OK # DEBUG-NEXT: .. the first uncovered imm index: 0, OK +# DEBUG-NEXT: G_FTAN (opcode {{[0-9]+}}): 1 type index, 0 imm indices

[clang] [llvm] Implement resource binding type prefix mismatch errors (PR #87578)

2024-04-29 Thread Joshua Batista via cfe-commits
@@ -44,7 +44,7 @@ void foo2() { // expected-warning@+1 {{'register' attribute only applies to cbuffer/tbuffer and external global variables}} extern RWBuffer U2 : register(u5); } -// FIXME: expect-error once fix https://github.com/llvm/llvm-project/issues/57886. +//

[clang] [Clang][objectsize] Generate object size calculation for sub-objects (PR #86858)

2024-04-29 Thread Bill Wendling via cfe-commits
bwendling wrote: Another ping... https://github.com/llvm/llvm-project/pull/86858 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Implement CWG2851: floating-point conversions in converted constant expressions (PR #90387)

2024-04-29 Thread Shafik Yaghmour via cfe-commits
@@ -67,6 +68,69 @@ void B::g() requires true; } // namespace cwg2847 +namespace cwg2851 { // cwg2851: 19 + +#if __cplusplus >= 202002L +template struct Val { static constexpr T value = v; }; + + +// Floating-point promotions + +static_assert(Val::value == 0.0L);

[clang] 1cb3371 - Ensure test writes objects to test temp dir

2024-04-29 Thread David Blaikie via cfe-commits
Author: David Blaikie Date: 2024-04-29T23:50:18Z New Revision: 1cb33713910501c6352d0eb2a15b7a15e6e18695 URL: https://github.com/llvm/llvm-project/commit/1cb33713910501c6352d0eb2a15b7a15e6e18695 DIFF: https://github.com/llvm/llvm-project/commit/1cb33713910501c6352d0eb2a15b7a15e6e18695.diff

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

2024-04-29 Thread Johannes Doerfert via cfe-commits
@@ -0,0 +1,1026 @@ +//===-- 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:

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

2024-04-29 Thread Johannes Doerfert via cfe-commits
@@ -0,0 +1,1026 @@ +//===-- 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:

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

2024-04-29 Thread Johannes Doerfert via cfe-commits
@@ -0,0 +1,1026 @@ +//===-- 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:

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

2024-04-29 Thread Johannes Doerfert via cfe-commits
@@ -0,0 +1,1026 @@ +//===-- 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:

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

2024-04-29 Thread Johannes Doerfert via cfe-commits
@@ -0,0 +1,1026 @@ +//===-- 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:

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

2024-04-29 Thread Johannes Doerfert via cfe-commits
@@ -0,0 +1,1026 @@ +//===-- 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:

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

2024-04-29 Thread Johannes Doerfert via cfe-commits
https://github.com/jdoerfert commented: I just read over this and left some comments. https://github.com/llvm/llvm-project/pull/89007 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

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

2024-04-29 Thread Johannes Doerfert via cfe-commits
https://github.com/jdoerfert edited https://github.com/llvm/llvm-project/pull/89007 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [SemaCXX] Implement CWG2351 `void{}` (PR #78060)

2024-04-29 Thread Richard Smith via cfe-commits
zygoloid wrote: > Note that the AST for the expression `T{}` looks like: > > ``` > // using T = int; > CXXFunctionalCastExpr 'T':'int' functional cast to T > `-InitListExpr 'T':'int' > // using T = const int; > CXXFunctionalCastExpr 'int' functional cast to T > `-InitListExpr 'int' > // using

[clang] [SemaCXX] Implement CWG2351 `void{}` (PR #78060)

2024-04-29 Thread Shafik Yaghmour via cfe-commits
shafik wrote: @MitalAshok ping https://github.com/llvm/llvm-project/pull/78060 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CUDA] make kernel stub ICF-proof (PR #90155)

2024-04-29 Thread Reid Kleckner via cfe-commits
@@ -424,6 +424,34 @@ void CGNVCUDARuntime::emitDeviceStubBodyNew(CodeGenFunction , CGM.CreateRuntimeFunction(FTy, LaunchKernelName); CGF.EmitCall(FI, CGCallee::forDirect(cudaLaunchKernelFn), ReturnValueSlot(), LaunchKernelArgs); + + // To prevent CUDA

[clang] [CUDA] make kernel stub ICF-proof (PR #90155)

2024-04-29 Thread Reid Kleckner via cfe-commits
@@ -424,6 +424,34 @@ void CGNVCUDARuntime::emitDeviceStubBodyNew(CodeGenFunction , CGM.CreateRuntimeFunction(FTy, LaunchKernelName); CGF.EmitCall(FI, CGCallee::forDirect(cudaLaunchKernelFn), ReturnValueSlot(), LaunchKernelArgs); + + // To prevent CUDA

[clang] [CUDA] make kernel stub ICF-proof (PR #90155)

2024-04-29 Thread Reid Kleckner via cfe-commits
@@ -424,6 +424,34 @@ void CGNVCUDARuntime::emitDeviceStubBodyNew(CodeGenFunction , CGM.CreateRuntimeFunction(FTy, LaunchKernelName); CGF.EmitCall(FI, CGCallee::forDirect(cudaLaunchKernelFn), ReturnValueSlot(), LaunchKernelArgs); + + // To prevent CUDA

[clang] Add support for builtin_verbose_trap (PR #79230)

2024-04-29 Thread Adrian Prantl via cfe-commits
@@ -27,6 +27,9 @@ namespace llvm { } } +// Prefix for __builtin_verbose_trap. +#define CLANG_VERBOSE_TRAP_PREFIX "__llvm_verbose_trap" adrian-prantl wrote: Does this have to be a macro or could it be a C++ constant?

[clang] [llvm] Implement resource binding type prefix mismatch errors (PR #87578)

2024-04-29 Thread Xiang Li via cfe-commits
@@ -44,7 +44,7 @@ void foo2() { // expected-warning@+1 {{'register' attribute only applies to cbuffer/tbuffer and external global variables}} extern RWBuffer U2 : register(u5); } -// FIXME: expect-error once fix https://github.com/llvm/llvm-project/issues/57886. +//

[clang] [llvm] Implement resource binding type prefix mismatch errors (PR #87578)

2024-04-29 Thread Xiang Li via cfe-commits
@@ -44,7 +44,7 @@ void foo2() { // expected-warning@+1 {{'register' attribute only applies to cbuffer/tbuffer and external global variables}} extern RWBuffer U2 : register(u5); } -// FIXME: expect-error once fix https://github.com/llvm/llvm-project/issues/57886. +//

[clang] [WebAssembly] Add preprocessor define for half-precision (PR #90528)

2024-04-29 Thread Thomas Lively via cfe-commits
https://github.com/tlively approved this pull request. https://github.com/llvm/llvm-project/pull/90528 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Handle trivial_abi attribute for Microsoft ABI. (PR #88857)

2024-04-29 Thread Reid Kleckner via cfe-commits
@@ -1105,6 +1105,11 @@ bool MicrosoftCXXABI::hasMostDerivedReturn(GlobalDecl GD) const { static bool isTrivialForMSVC(const CXXRecordDecl *RD, QualType Ty, CodeGenModule ) { + // If the record is marked with the trivial_abi attribute, we don't +

[clang] [llvm] Implement resource binding type prefix mismatch errors (PR #87578)

2024-04-29 Thread Joshua Batista via cfe-commits
@@ -44,7 +44,7 @@ void foo2() { // expected-warning@+1 {{'register' attribute only applies to cbuffer/tbuffer and external global variables}} extern RWBuffer U2 : register(u5); } -// FIXME: expect-error once fix https://github.com/llvm/llvm-project/issues/57886. +//

[clang] [WebAssembly] Add preprocessor define for half-precision (PR #90528)

2024-04-29 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-webassembly @llvm/pr-subscribers-clang Author: Heejin Ahn (aheejin) Changes This adds the preprocessor define for the half-precision feature and also adds preprocessor tests. --- Full diff: https://github.com/llvm/llvm-project/pull/90528.diff

[clang] [WebAssembly] Add preprocessor define for half-precision (PR #90528)

2024-04-29 Thread Heejin Ahn via cfe-commits
aheejin wrote: cc @brendandahl (I couldn't add you as a reviewer because you didn't pop up in the reviewers list) Also, this just adds the preprocessor directive, but I'm wondering whether you really meant to add this to bleeding-edge:

[clang] [OpenMP][TR12] change property of map-type modifier. (PR #90499)

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

[clang] [WebAssembly] Add preprocessor define for half-precision (PR #90528)

2024-04-29 Thread Heejin Ahn via cfe-commits
https://github.com/aheejin created https://github.com/llvm/llvm-project/pull/90528 This adds the preprocessor define for the half-precision feature and also adds preprocessor tests. >From 036d8a7486eab8ee2b434826c6ad5807daba2574 Mon Sep 17 00:00:00 2001 From: Heejin Ahn Date: Mon, 29 Apr

[clang] [clang-tools-extra] [llvm] Add ``ignoringParenImpCasts`` in arguments of hasArgument (PR #89553)

2024-04-29 Thread via cfe-commits
@@ -44,9 +44,10 @@ void StringFindStartswithCheck::registerMatchers(MatchFinder *Finder) { callee(cxxMethodDecl(hasName("find")).bind("findfun")), on(hasType(StringType)), // ... with some search expression ... - hasArgument(0, expr().bind("needle")), +

[clang] [clang-tools-extra] [llvm] Add ``ignoringParenImpCasts`` in arguments of hasArgument (PR #89553)

2024-04-29 Thread via cfe-commits
https://github.com/jkorous-apple requested changes to this pull request. Please start with removing all files that shouldn't be part of the PR. Then please remove changes that affect only format/whitespace. https://github.com/llvm/llvm-project/pull/89553

[clang] [clang-tools-extra] [llvm] Add ``ignoringParenImpCasts`` in arguments of hasArgument (PR #89553)

2024-04-29 Thread via cfe-commits
@@ -22,7 +22,7 @@ namespace clang::tidy::abseil { // - Make it work in macros if the outer and inner StrCats are both in the //argument. -void RedundantStrcatCallsCheck::registerMatchers(MatchFinder* Finder) { +void RedundantStrcatCallsCheck::registerMatchers(MatchFinder

[clang] [clang-tools-extra] [llvm] Add ``ignoringParenImpCasts`` in arguments of hasArgument (PR #89553)

2024-04-29 Thread via cfe-commits
@@ -0,0 +1,5 @@ +Script started on 2024-04-27 13:50:15+05:30 [TERM="xterm-256color" TTY="/dev/pts/0" COLUMNS="100" LINES="18"] jkorous-apple wrote: Please clean up the PR so it doesn't contain files that shouldn't be merged.

[clang] [clang-tools-extra] [llvm] Add ``ignoringParenImpCasts`` in arguments of hasArgument (PR #89553)

2024-04-29 Thread via cfe-commits
@@ -0,0 +1,72 @@ +set(CMAKE_C_COMPILER "/usr/bin/cc") jkorous-apple wrote: Also, why are we adding binaries? https://github.com/llvm/llvm-project/pull/89553 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [clang-tools-extra] [llvm] Add ``ignoringParenImpCasts`` in arguments of hasArgument (PR #89553)

2024-04-29 Thread via cfe-commits
@@ -0,0 +1,72 @@ +set(CMAKE_C_COMPILER "/usr/bin/cc") jkorous-apple wrote: Why does this PR touch any CMake files? Is it necessary for the intended change of behavior of one or two AST matchers? https://github.com/llvm/llvm-project/pull/89553

[clang] [clang-tools-extra] [llvm] Add ``ignoringParenImpCasts`` in arguments of hasArgument (PR #89553)

2024-04-29 Thread via cfe-commits
https://github.com/jkorous-apple edited https://github.com/llvm/llvm-project/pull/89553 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV] Teach .option arch to support experimental extensions. (PR #89727)

2024-04-29 Thread Craig Topper via cfe-commits
https://github.com/topperc edited https://github.com/llvm/llvm-project/pull/89727 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV] Teach .option arch to support experimental extensions. (PR #89727)

2024-04-29 Thread Craig Topper via cfe-commits
@@ -169,6 +169,9 @@ void riscv::getRISCVTargetFeatures(const Driver , const llvm::Triple , Features.push_back("-relax"); } + if (!Args.hasArg(options::OPT_menable_experimental_extensions)) +Features.push_back("+no-experimental-ext"); topperc

[clang] [Clang] Address post commit feedbacks in #89906 (PR #90495)

2024-04-29 Thread via cfe-commits
@@ -177,7 +177,7 @@ C++2c implementation status Attributes for Structured Bindings https://wg21.link/P0609R3;>P0609R3 - No + Clang 19 cor3ntin wrote: Ugh, how did that happen? Thanks for noticing! https://github.com/llvm/llvm-project/pull/90495

[clang] 1f44a0b - Make minor improvements to the creduce wrapper script

2024-04-29 Thread Reid Kleckner via cfe-commits
Author: Reid Kleckner Date: 2024-04-29T22:09:09Z New Revision: 1f44a0b1ff2daebe10b9916da228f7c0ba66827c URL: https://github.com/llvm/llvm-project/commit/1f44a0b1ff2daebe10b9916da228f7c0ba66827c DIFF: https://github.com/llvm/llvm-project/commit/1f44a0b1ff2daebe10b9916da228f7c0ba66827c.diff

[clang] [llvm] [CodeGen][i386] Move -mregparm storage earlier and fix Runtime calls (PR #89707)

2024-04-29 Thread Kees Cook via cfe-commits
https://github.com/kees closed https://github.com/llvm/llvm-project/pull/89707 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 869ffcf - [CodeGen][i386] Move -mregparm storage earlier and fix Runtime calls (#89707)

2024-04-29 Thread via cfe-commits
Author: Kees Cook Date: 2024-04-29T14:54:10-07:00 New Revision: 869ffcf3f6ca74c8a0ec6eb250d45e6ea0680c81 URL: https://github.com/llvm/llvm-project/commit/869ffcf3f6ca74c8a0ec6eb250d45e6ea0680c81 DIFF: https://github.com/llvm/llvm-project/commit/869ffcf3f6ca74c8a0ec6eb250d45e6ea0680c81.diff

[clang] [Clang] Prevent null pointer dereference in Sema::​CodeCompleteQualifiedId() (PR #90490)

2024-04-29 Thread via cfe-commits
@@ -6714,14 +6714,16 @@ void Sema::CodeCompleteQualifiedId(Scope *S, CXXScopeSpec , // If the scope is a concept-constrained type parameter, infer nested // members based on the constraints. - if (const auto *TTPT = - dyn_cast_or_null(NNS->getAsType())) { -

[clang] [OpenMP][TR12] change property of map-type modifier. (PR #90499)

2024-04-29 Thread via cfe-commits
@@ -113,7 +114,7 @@ struct SA { #pragma omp target map(b[true:true]) {} -#pragma omp target map(: c,f) // expected-error {{missing map type}} +#pragma omp target map(: c,f) // lt60-error {{missing map type}} jyu2-git wrote: Hi Alexey, could

[clang] [Clang] Prevent null pointer dereference in Sema::​CodeCompleteQualifiedId() (PR #90490)

2024-04-29 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik commented: Looks good, I will let Tom make the final accept. https://github.com/llvm/llvm-project/pull/90490 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Prevent null pointer dereference in Sema::​CodeCompleteQualifiedId() (PR #90490)

2024-04-29 Thread Shafik Yaghmour via cfe-commits
@@ -6714,14 +6714,16 @@ void Sema::CodeCompleteQualifiedId(Scope *S, CXXScopeSpec , // If the scope is a concept-constrained type parameter, infer nested // members based on the constraints. - if (const auto *TTPT = - dyn_cast_or_null(NNS->getAsType())) { -

[clang] [Clang] Prevent null pointer dereference in Sema::​CodeCompleteQualifiedId() (PR #90490)

2024-04-29 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik edited https://github.com/llvm/llvm-project/pull/90490 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][SPARC] Treat empty structs as if it's a one-bit type in the CC (PR #90338)

2024-04-29 Thread Sergei Barannikov via cfe-commits
@@ -263,7 +263,10 @@ SparcV9ABIInfo::classifyType(QualType Ty, unsigned SizeLimit) const { CoerceBuilder CB(getVMContext(), getDataLayout()); CB.addStruct(0, StrTy); - CB.pad(llvm::alignTo(CB.DL.getTypeSizeInBits(StrTy), 64)); + // All structs, even empty ones, should

[clang] [clang][SPARC] Treat empty structs as if it's a one-bit type in the CC (PR #90338)

2024-04-29 Thread Sergei Barannikov via cfe-commits
@@ -21,6 +21,12 @@ char f_int_4(char x) { return x; } // CHECK-LABEL: define{{.*}} fp128 @f_ld(fp128 noundef %x) long double f_ld(long double x) { return x; } +// Empty struct is lowered as a placeholder word parameter. +struct empty {}; + +// CHECK-LABEL: define{{.*}} i64

[clang] [Modules] Detect ODR mismatches for enums in non-C++ like in C++. (PR #90298)

2024-04-29 Thread Volodymyr Sapsai via cfe-commits
vsapsai wrote: > Not sure I'm following the response here - but I guess what I'm trying to > say, with more words, is that my understanding was that C doesn't have an > ODR, and you can have different definitions of a type, with the same name, in > C and that's OK. In different translation

[clang] [WebAssembly] Enable multivalue and reference-types in generic CPU config (PR #80923)

2024-04-29 Thread Heejin Ahn via cfe-commits
https://github.com/aheejin closed https://github.com/llvm/llvm-project/pull/80923 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 5bbf1ea - [WebAssembly] Enable multivalue and reference-types in generic CPU config (#80923)

2024-04-29 Thread via cfe-commits
Author: Heejin Ahn Date: 2024-04-29T14:23:08-07:00 New Revision: 5bbf1ea8f18d1f99637b7b8bf6b985c186c808f6 URL: https://github.com/llvm/llvm-project/commit/5bbf1ea8f18d1f99637b7b8bf6b985c186c808f6 DIFF: https://github.com/llvm/llvm-project/commit/5bbf1ea8f18d1f99637b7b8bf6b985c186c808f6.diff

[clang] [WebAssembly] Enable multivalue and reference-types in generic CPU config (PR #80923)

2024-04-29 Thread Heejin Ahn via cfe-commits
https://github.com/aheejin edited https://github.com/llvm/llvm-project/pull/80923 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

  1   2   3   4   5   >