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

2024-07-25 Thread Sergio Afonso via cfe-commits
skatrak wrote: I'm not very knowledgeable on the set of offloading-related options clang supports, how those impact the set of invocations and options produced by the driver, or how these options eventually impact passes and codegen. Much less about potential shortcomings and improvements to t

[clang] [ASTMatchers] Extend hasName matcher when matching templates (PR #100349)

2024-07-25 Thread Nathan James via cfe-commits
njames93 wrote: @AaronBallman That's a good point, I didn't account for how defaulted template arguments aren't printed. Would using `<*>` or a more rustic approach of `<_>` be a good alternative? https://github.com/llvm/llvm-project/pull/100349 ___ c

[clang] [Clang] Fix confusing diagnositcs related to explicit this parameters (PR #100351)

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

[clang] [libcxx] Reapply "[Clang] Implement resolution for CWG1835 (#92957, #98547)" (PR #100425)

2024-07-25 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: There is discussion on the Core reflectors about this DR (https://lists.isocpp.org/core/2024/07/16028.php), so given the amount of difficulty we've had with this DR so far, I would recommend we hold off on landing any changes until Core has finished deliberation. https://g

[clang] [clang] replaced the usage of `asctime` with `std::put_time` (PR #99075)

2024-07-25 Thread Rainer Orth via cfe-commits
rorth wrote: At least in the short term. ISTM that `clang++` may need to do something along the lines of Bug 33767 (resp. the underlying GCC bug/patch), otherwise users are in for a nasty surprise. https://github.com/llvm/llvm-project/pull/99075 ___

[clang] [Clang][Interp] Create the variable that holds the value of evaluating the binding (PR #100565)

2024-07-25 Thread via cfe-commits
yronglin wrote: > Why is creating those variables necessary, what part about the reproducer > doesn't work in the current interpreter, and why would the new one support it? Seems current interpreter treats `&sre == &__real scf` and `&sim == &__imag scf` not an integral constant expression. ht

[clang] [Clang] Initializer list on RHS of assignment (PR #100548)

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

[clang] [Clang] Initializer list on RHS of assignment (PR #100548)

2024-07-25 Thread via cfe-commits
https://github.com/cor3ntin commented: Thanks for this patch. The direction looks right but i think there is room for minor improvements https://github.com/llvm/llvm-project/pull/100548 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://li

[clang] [Clang] Initializer list on RHS of assignment (PR #100548)

2024-07-25 Thread via cfe-commits
@@ -0,0 +1,20 @@ +// RUN: %clang_cc1 -std=c++11 -fsyntax-only -verify %s + +template +void f(T dependent) { + int i; + i = { dependent, dependent }; +} + +template +void f2(T dependent) { + int i; + i = { dependent, dependent }; // expected-error {{excess elements in scalar i

[clang] [Clang] Initializer list on RHS of assignment (PR #100548)

2024-07-25 Thread via cfe-commits
@@ -14578,21 +14578,56 @@ ExprResult Sema::CreateBuiltinBinOp(SourceLocation OpLoc, BinaryOperatorKind Opc, Expr *LHSExpr, Expr *RHSExpr) { if (getLangOpts().CPlusPlus11 && isa(RHSExpr)) { -// The sy

[clang] [Clang] Initializer list on RHS of assignment (PR #100548)

2024-07-25 Thread via cfe-commits
@@ -101,6 +101,20 @@ static_assert(!__is_layout_compatible(StructWithAnonUnion, StructWithAnonUnion3) #endif } // namespace cwg2759 +namespace cwg2768 { // cwg2768: 20 +#if __cplusplus >= 201103L +enum class E {E1}; + +void f() { + E e; + e = E{0}; // #1 + // cxx11-14-erro

[clang] [Clang] Initializer list on RHS of assignment (PR #100548)

2024-07-25 Thread via cfe-commits
@@ -14578,21 +14578,56 @@ ExprResult Sema::CreateBuiltinBinOp(SourceLocation OpLoc, BinaryOperatorKind Opc, Expr *LHSExpr, Expr *RHSExpr) { if (getLangOpts().CPlusPlus11 && isa(RHSExpr)) { -// The sy

[clang] [Clang] Initializer list on RHS of assignment (PR #100548)

2024-07-25 Thread via cfe-commits
@@ -14578,21 +14578,56 @@ ExprResult Sema::CreateBuiltinBinOp(SourceLocation OpLoc, BinaryOperatorKind Opc, Expr *LHSExpr, Expr *RHSExpr) { if (getLangOpts().CPlusPlus11 && isa(RHSExpr)) { -// The sy

[clang] [ASTMatchers] Extend hasName matcher when matching templates (PR #100349)

2024-07-25 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > > > @AaronBallman That's a good point, I didn't account for how defaulted > > > template arguments aren't printed. Would using `<*>` ~or a more rustic > > > approach of `<_>`~ be a good alternative? > > > > > > I was thinking about that, but I keep coming around to wonde

[clang] [analyzer][NFC] Minor cleanup in two test files. (PR #100570)

2024-07-25 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat created https://github.com/llvm/llvm-project/pull/100570 This commit contains two unrelated trivial changes: (1) Three unused variables are removed from `ctor.mm`. (2) A FIXME block is removed from `ctor-array.cpp` because it described an issue that was resolved

[clang] [analyzer][NFC] Minor cleanup in two test files. (PR #100570)

2024-07-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Donát Nagy (NagyDonat) Changes This commit contains two unrelated trivial changes: (1) Three unused variables are removed from `ctor.mm`. (2) A FIXME block is removed from `ctor-array.cpp` because it described an issue that was resolve

[clang] [analyzer][NFC] Minor cleanup in two test files. (PR #100570)

2024-07-25 Thread Kristóf Umann via cfe-commits
https://github.com/Szelethus approved this pull request. https://github.com/llvm/llvm-project/pull/100570 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 9ad92c4 - [analyzer][NFC] Minor cleanup in two test files. (#100570)

2024-07-25 Thread via cfe-commits
Author: Donát Nagy Date: 2024-07-25T15:56:17+02:00 New Revision: 9ad92c476907451bdc95a6c2b6a6bbba03815b4b URL: https://github.com/llvm/llvm-project/commit/9ad92c476907451bdc95a6c2b6a6bbba03815b4b DIFF: https://github.com/llvm/llvm-project/commit/9ad92c476907451bdc95a6c2b6a6bbba03815b4b.diff LO

[clang] [analyzer][NFC] Minor cleanup in two test files. (PR #100570)

2024-07-25 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat closed https://github.com/llvm/llvm-project/pull/100570 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [analyzer][NFC] Minor cleanup in two test files. (PR #100570)

2024-07-25 Thread via cfe-commits
isuckatcs wrote: If these changes are unrelated to each other, wouldn't it be better to separate them into 2 commits? https://github.com/llvm/llvm-project/pull/100570 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-b

[clang] [clang] Remove `__is_layout_compatible` from revertible type traits list (PR #100572)

2024-07-25 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll created https://github.com/llvm/llvm-project/pull/100572 `__is_layout_compatible` was added in Clang 19 (#81506), and at that time it wasn't entirely clear whether it should be a revertible type trait or not. We decided to follow the example of other type traits. Sin

[clang] [clang] Remove `__is_layout_compatible` from revertible type traits list (PR #100572)

2024-07-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Vlad Serebrennikov (Endilll) Changes `__is_layout_compatible` was added in Clang 19 (#81506), and at that time it wasn't entirely clear whether it should be a revertible type trait or not. We decided to follow the example of other type tr

[clang] [Clang][Interp] Create the variable that holds the value of evaluating the binding (PR #100565)

2024-07-25 Thread Timm Baeder via cfe-commits
tbaederr wrote: https://godbolt.org/z/a8TW93h63 Because it isn't a constant expression - at the time of the evaluation of the `static_assert`, the parameter value `cf` is unknown and so initializing `scf` can't work. Rejecting this is correct. https://github.com/llvm/llvm-project/pull/100565

[clang] [clang] Remove `__is_layout_compatible` from revertible type traits list (PR #100572)

2024-07-25 Thread via cfe-commits
https://github.com/cor3ntin approved this pull request. Thanks! https://github.com/llvm/llvm-project/pull/100572 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][analyzer] Improve PointerSubChecker (PR #96501)

2024-07-25 Thread Balázs Kéri via cfe-commits
https://github.com/balazske updated https://github.com/llvm/llvm-project/pull/96501 From b431151f83fa2980e4a132191ccf5713ab69806b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bal=C3=A1zs=20K=C3=A9ri?= Date: Mon, 24 Jun 2024 16:48:54 +0200 Subject: [PATCH 1/2] [clang][analyzer] Improve PointerSubChe

[clang] [analyzer][NFC] Minor cleanup in two test files. (PR #100570)

2024-07-25 Thread Kristóf Umann via cfe-commits
Szelethus wrote: > If these changes are unrelated to each other, wouldn't it be better to > separate them into 2 commits? I see the principle, but I think its reasonable to push this one go, considering that these changes are really minor and inconsquential, especially since they affect the v

[clang] [clang] Remove `__is_layout_compatible` from revertible type traits list (PR #100572)

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

[clang] [clang] Implement `__is_virtual_base_of()` intrinsic (PR #100393)

2024-07-25 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll updated https://github.com/llvm/llvm-project/pull/100393 >From 772b5d85dff73de9f6a01a266bd201cbe04923ab Mon Sep 17 00:00:00 2001 From: Vlad Serebrennikov Date: Wed, 24 Jul 2024 17:38:50 +0300 Subject: [PATCH 1/5] [clang] Impement `__is_virtual_base_of()` intrinsic --

[clang] [Sema] Preserve ContainsUnexpandedParameterPack in TransformLambdaExpr (PR #86265)

2024-07-25 Thread Younan Zhang via cfe-commits
zyn0217 wrote: > And we probably don't want the logic that produces diagnostics (substitutions > cannot create new unexpanded packs in bad places), but we do need the logic > to update the LambdaScopeInfo::ContainsUnexpandedPacks so we can avoid this > extra traversal. Cheers. Thanks for the

[clang] [Sema] Preserve ContainsUnexpandedParameterPack in TransformLambdaExpr (PR #86265)

2024-07-25 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 updated https://github.com/llvm/llvm-project/pull/86265 >From 6e7b38b3e3f781e11db2fa5d552fdfb6123609df Mon Sep 17 00:00:00 2001 From: Younan Zhang Date: Fri, 22 Mar 2024 17:34:08 +0800 Subject: [PATCH 01/16] [Sema] Preserve ContainsUnexpandedParameterPack in Transfor

[clang] [NFC][Clang][Interp] Add more test for `__builtin_os_log_format_buffer_size` (PR #100566)

2024-07-25 Thread via cfe-commits
yronglin wrote: > Did you check locally that this works with sanitizers enabled? Yeah, the memory leak issue in https://github.com/llvm/llvm-project/pull/99895 seems to be caused by other floating point builtins in clang/test/CodeGen/builtins.c. The new examples added in this PR do not have a

[clang] [analyzer][NFC] Minor cleanup in two test files. (PR #100570)

2024-07-25 Thread Donát Nagy via cfe-commits
NagyDonat wrote: In my opinion the "put unrelated things into separate commits" guideline is just a corollary of the "don't create commits that are too complex" rule. If a change is extremely trivial, I'm actively trying to aggregate it with other tangentially related changes, because one simp

[clang] daf9d7f - [PowerPC] add testcaseis for PPC, NFC

2024-07-25 Thread Chen Zheng via cfe-commits
Author: Chen Zheng Date: 2024-07-25T10:13:45-04:00 New Revision: daf9d7f3881e4ffd1fd5988dc1b6223c733b6bef URL: https://github.com/llvm/llvm-project/commit/daf9d7f3881e4ffd1fd5988dc1b6223c733b6bef DIFF: https://github.com/llvm/llvm-project/commit/daf9d7f3881e4ffd1fd5988dc1b6223c733b6bef.diff LO

[clang] [Sema] Preserve ContainsUnexpandedParameterPack in TransformLambdaExpr (PR #86265)

2024-07-25 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 updated https://github.com/llvm/llvm-project/pull/86265 >From 6e7b38b3e3f781e11db2fa5d552fdfb6123609df Mon Sep 17 00:00:00 2001 From: Younan Zhang Date: Fri, 22 Mar 2024 17:34:08 +0800 Subject: [PATCH 01/17] [Sema] Preserve ContainsUnexpandedParameterPack in Transfor

[clang] [clang] Implement `__is_virtual_base_of()` intrinsic (PR #100393)

2024-07-25 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll updated https://github.com/llvm/llvm-project/pull/100393 >From 772b5d85dff73de9f6a01a266bd201cbe04923ab Mon Sep 17 00:00:00 2001 From: Vlad Serebrennikov Date: Wed, 24 Jul 2024 17:38:50 +0300 Subject: [PATCH 1/5] [clang] Impement `__is_virtual_base_of()` intrinsic --

[clang] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

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

[clang] [Clang][Interp] Create the variable that holds the value of evaluating the binding (PR #100565)

2024-07-25 Thread via cfe-commits
https://github.com/yronglin closed https://github.com/llvm/llvm-project/pull/100565 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 51d4980 - [clang][NFC] remove unneeded nullptr checks after dereference (#100489)

2024-07-25 Thread via cfe-commits
Author: Mike Rice Date: 2024-07-25T08:03:16-07:00 New Revision: 51d4980a133db12888207698e39c469cb7055cac URL: https://github.com/llvm/llvm-project/commit/51d4980a133db12888207698e39c469cb7055cac DIFF: https://github.com/llvm/llvm-project/commit/51d4980a133db12888207698e39c469cb7055cac.diff LOG

[clang] [clang][NFC] remove unneeded nullptr checks after dereference (PR #100489)

2024-07-25 Thread Mike Rice via cfe-commits
https://github.com/mikerice1969 closed https://github.com/llvm/llvm-project/pull/100489 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AArch64] Implement NEON vamin/vamax intrinsics (PR #99041)

2024-07-25 Thread via cfe-commits
@@ -5985,6 +5985,26 @@ multiclass SIMDThreeSameVectorFP opc, [(set (v2f64 V128:$Rd), (OpNode (v2f64 V128:$Rn), (v2f64 V128:$Rm)))]>; } +let mayRaiseFPException = 1, Uses = [FPCR] in +multiclass SIMDThreeVectorFP opc, CarolineConcatto wrote: Why are y

[clang] [NFC][Clang][Interp] Add more test for `__builtin_os_log_format_buffer_size` (PR #100566)

2024-07-25 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr approved this pull request. https://github.com/llvm/llvm-project/pull/100566 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][NFC] remove unneeded nullptr checks after dereference (PR #100489)

2024-07-25 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `llvm-clang-aarch64-darwin` running on `doug-worker-5` while building `clang` at step 6 "test-build-unified-tree-check-all". Full details are available at: https://lab.llvm.org/buildbot/#/builders/190/builds/2641 Here is the

[clang] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-07-25 Thread via cfe-commits
@@ -414,23 +419,22 @@ class Intrinsic { /// Get the architectural guard string (#ifdef). std::string getArchGuard() const { return ArchGuard; } std::string getTargetGuard() const { return TargetGuard; } + ArrayRef> getImmChecks() const { return ImmChecks; } /// Get t

[clang] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-07-25 Thread via cfe-commits
@@ -333,6 +333,8 @@ class Intrinsic { /// The types of return value [0] and parameters [1..]. std::vector Types; + + SmallVector, 2> ImmChecks; Lukacma wrote: I think using ImmCheck class as in SVEEmittor would make the code more readable as it would al

[clang] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-07-25 Thread via cfe-commits
@@ -1573,7 +1573,7 @@ void SVEEmitter::createTypeFlags(raw_ostream &OS) { OS << " " << KV.getKey() << " = " << KV.getValue() << ",\n"; OS << "#endif\n\n"; - OS << "#ifdef LLVM_GET_SVE_IMMCHECKTYPES\n"; + OS << "#ifdef LLVM_GET_ARM_INTRIN_IMMCHECKTYPES\n";

[clang] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-07-25 Thread via cfe-commits
@@ -810,7 +836,7 @@ bool SemaARM::CheckNeonBuiltinFunctionCall(const TargetInfo &TI, #undef GET_NEON_IMMEDIATE_CHECK } - return SemaRef.BuiltinConstantArgRange(TheCall, i, l, u + l); + return ParseNeonImmChecks(TheCall, ImmChecks, TV); Lukacma wrote: I t

[clang] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-07-25 Thread via cfe-commits
@@ -215,7 +215,37 @@ namespace clang { return ET == Poly8 || ET == Poly16 || ET == Poly64; } bool isUnsigned() const { return (Flags & UnsignedFlag) != 0; } -bool isQuad() const { return (Flags & QuadFlag) != 0; } +bool isQuad() const { return (Flags & Qua

[clang] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

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

[clang] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-07-25 Thread via cfe-commits
@@ -403,6 +369,63 @@ enum ArmSMEState : unsigned { ArmZT0Mask = 0b11 << 2 }; +bool SemaARM::ParseNeonImmChecks( +CallExpr *TheCall, SmallVector, 2> &ImmChecks, +int OverloadType = -1) { + int ArgIdx, CheckTy, ElementType; + bool hasError = false; L

[clang] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-07-25 Thread via cfe-commits
https://github.com/Lukacma commented: Thank you Spencer ! This patch is very useful as it will enable us to write more modular neon checks and unifies immediate checking with SVE. https://github.com/llvm/llvm-project/pull/100278 ___ cfe-commits maili

[clang] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-07-25 Thread via cfe-commits
@@ -554,6 +558,7 @@ class NeonEmitter { SmallVectorImpl &Defs); void genOverloadTypeCheckCode(raw_ostream &OS, SmallVectorImpl &Defs); + void genNeonImmCheckTypes(raw_ostream &OS); Lukacma

[clang] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-07-25 Thread via cfe-commits
@@ -76,7 +76,7 @@ let ArchGuard = "defined(__aarch64__) || defined(__arm64ec__)", TargetGuard = "f def SCALAR_FCVTPUH : SInst<"vcvtp_u16", "(1U)1", "Sh">; def SCALAR_FCVTPUH1 : SInst<"vcvtp_u32", "(1U>)1", "Sh">; def SCALAR_FCVTPUH2 : SInst<"vcvtp_u64", "(1U>>)1", "Sh">

[clang] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-07-25 Thread via cfe-commits
@@ -403,6 +369,63 @@ enum ArmSMEState : unsigned { ArmZT0Mask = 0b11 << 2 }; +bool SemaARM::ParseNeonImmChecks( Lukacma wrote: Have you thought about merging ParseNeonImmChecks and ParseSVEImmChecks into single function, which would work for both? Or is th

[clang] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-07-25 Thread via cfe-commits
@@ -403,6 +369,63 @@ enum ArmSMEState : unsigned { ArmZT0Mask = 0b11 << 2 }; +bool SemaARM::ParseNeonImmChecks( +CallExpr *TheCall, SmallVector, 2> &ImmChecks, +int OverloadType = -1) { + int ArgIdx, CheckTy, ElementType; + bool hasError = false; + + for (auto &I

[clang] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-07-25 Thread via cfe-commits
@@ -403,6 +369,63 @@ enum ArmSMEState : unsigned { ArmZT0Mask = 0b11 << 2 }; +bool SemaARM::ParseNeonImmChecks( +CallExpr *TheCall, SmallVector, 2> &ImmChecks, +int OverloadType = -1) { + int ArgIdx, CheckTy, ElementType; + bool hasError = false; + + for (auto &I

[clang] [Clang][AArch64] Add customisable immediate range checking to NEON (PR #100278)

2024-07-25 Thread via cfe-commits
@@ -215,7 +215,37 @@ namespace clang { return ET == Poly8 || ET == Poly16 || ET == Poly64; } bool isUnsigned() const { return (Flags & UnsignedFlag) != 0; } -bool isQuad() const { return (Flags & QuadFlag) != 0; } +bool isQuad() const { return (Flags & Qua

[clang-tools-extra] Fix crash in modernize-use-ranges (PR #100427)

2024-07-25 Thread Piotr Zegar via cfe-commits
PiotrZSL wrote: Fix is reported to work, so lets merge it. https://github.com/llvm/llvm-project/pull/100427 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] 0762db6 - [clang-tidy] Fix crash in modernize-use-ranges (#100427)

2024-07-25 Thread via cfe-commits
Author: Nathan James Date: 2024-07-25T17:25:37+02:00 New Revision: 0762db6533eda3453158c7b9b0631542c47093a8 URL: https://github.com/llvm/llvm-project/commit/0762db6533eda3453158c7b9b0631542c47093a8 DIFF: https://github.com/llvm/llvm-project/commit/0762db6533eda3453158c7b9b0631542c47093a8.diff

[clang-tools-extra] Fix crash in modernize-use-ranges (PR #100427)

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

[clang-tools-extra] a27f816 - [clang-tidy] Fix crash in C language in readability-non-const-parameter (#100461)

2024-07-25 Thread via cfe-commits
Author: Piotr Zegar Date: 2024-07-25T17:26:01+02:00 New Revision: a27f816fe56af9cc7f4f296ad6c577f6ea64349f URL: https://github.com/llvm/llvm-project/commit/a27f816fe56af9cc7f4f296ad6c577f6ea64349f DIFF: https://github.com/llvm/llvm-project/commit/a27f816fe56af9cc7f4f296ad6c577f6ea64349f.diff L

[clang-tools-extra] [clang-tidy] Fix crash in C language in readability-non-const-parameter (PR #100461)

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

[clang] nonblocking/nonallocating attributes: 2nd pass caller/callee analysis (PR #99656)

2024-07-25 Thread Doug Wyatt via cfe-commits
@@ -0,0 +1,194 @@ +// RUN: %clang_cc1 -fsyntax-only -fblocks -fcxx-exceptions -verify %s +// These are in a separate file because errors (e.g. incompatible attributes) currently prevent +// the AnalysisBasedWarnings pass from running at all. + +// This diagnostic is re-enabled an

[clang] [llvm] [mlir] Remove the `x86_mmx` IR type. (PR #98505)

2024-07-25 Thread Kamau Bridgeman via cfe-commits
kamaub wrote: The changes made to the if statement in this PR at: https://github.com/llvm/llvm-project/commit/dfeb3991fb489a703f631ab0c34b58f80568038d#diff-f58c914c06010d2cd2c1359514ce9b8a4170e8c214eb52dd49ef5b17d391950eR2681 causes a new `-Werror,-Wunused-but-set-variable` when building llvm-p

[clang] [clang] Remove `__is_layout_compatible` from revertible type traits list (PR #100572)

2024-07-25 Thread Nikolas Klauser via cfe-commits
philnik777 wrote: Should we also rename to `__builtin_is_layout_compatible`? https://github.com/llvm/llvm-project/pull/100572 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] nonblocking/nonallocating attributes: 2nd pass caller/callee analysis (PR #99656)

2024-07-25 Thread Doug Wyatt via cfe-commits
@@ -0,0 +1,194 @@ +// RUN: %clang_cc1 -fsyntax-only -fblocks -fcxx-exceptions -verify %s +// These are in a separate file because errors (e.g. incompatible attributes) currently prevent +// the AnalysisBasedWarnings pass from running at all. + +// This diagnostic is re-enabled an

[clang] [AIX] Detect `#pragma mc_func` (PR #99888)

2024-07-25 Thread Qiongsi Wu via cfe-commits
qiongsiwu wrote: > this same logic can be applied to almost every pragma we don't support, but > we don't want to add special handlers for every pragma we don't support. > It doesn't seem particularly dangerous to ignore this pragma because ignoring > it means no symbol is generated for the sy

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

2024-07-25 Thread via cfe-commits
@@ -1599,13 +1599,66 @@ createTypePackElementParameterList(const ASTContext &C, DeclContext *DC) { nullptr); } +static TemplateParameterList *createCommonTypeList(const ASTContext &C, + D

[clang] [AIX] Detect `#pragma mc_func` (PR #99888)

2024-07-25 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > I have not reviewed other pragmas that we do not support, but I think this > one is a bit special in that it defines functions (code) that can be > executed, and we are aware of use cases where detecting the error at link > time is insufficient. Ooh, maybe I misunderstoo

[clang] [llvm] [mlir] Remove the `x86_mmx` IR type. (PR #98505)

2024-07-25 Thread James Y Knight via cfe-commits
jyknight wrote: @RKSimon has fixed in abacc5220e228012b0b86ca2ed540ef1a715f1ee, thanks. Sorry for missing that! https://github.com/llvm/llvm-project/pull/98505 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mail

[clang] nonblocking/nonallocating attributes: 2nd pass caller/callee analysis (PR #99656)

2024-07-25 Thread Doug Wyatt via cfe-commits
@@ -0,0 +1,194 @@ +// RUN: %clang_cc1 -fsyntax-only -fblocks -fcxx-exceptions -verify %s +// These are in a separate file because errors (e.g. incompatible attributes) currently prevent +// the AnalysisBasedWarnings pass from running at all. + +// This diagnostic is re-enabled an

[clang] Fix assertion failure during conversion function overload resolution. (PR #98671)

2024-07-25 Thread Daniel M. Katz via cfe-commits
https://github.com/katzdm updated https://github.com/llvm/llvm-project/pull/98671 >From 47db72077258ebe086059f116bbf7fb32c184c8d Mon Sep 17 00:00:00 2001 From: Dan Katz Date: Fri, 12 Jul 2024 13:57:33 -0400 Subject: [PATCH 1/4] Fix assertion failure during operator overload resolution. --- c

[clang] Fix assertion failure during conversion function overload resolution. (PR #98671)

2024-07-25 Thread Daniel M. Katz via cfe-commits
@@ -5824,12 +5824,23 @@ FunctionDecl *Sema::getMoreConstrainedFunction(FunctionDecl *FD1, FunctionDecl *FD2) { assert(!FD1->getDescribedTemplate() && !FD2->getDescribedTemplate() && "not for function templates"); - Fun

[clang] Fix assertion failure during conversion function overload resolution. (PR #98671)

2024-07-25 Thread Daniel M. Katz via cfe-commits
@@ -5824,12 +5824,23 @@ FunctionDecl *Sema::getMoreConstrainedFunction(FunctionDecl *FD1, FunctionDecl *FD2) { assert(!FD1->getDescribedTemplate() && !FD2->getDescribedTemplate() && "not for function templates"); - Fun

[clang] [llvm] [AArch64] Implement intrinsics for SVE FAMIN/FAMAX (PR #99042)

2024-07-25 Thread via cfe-commits
https://github.com/CarolineConcatto approved this pull request. https://github.com/llvm/llvm-project/pull/99042 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Remove `__is_layout_compatible` from revertible type traits list (PR #100572)

2024-07-25 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: > Should we also rename to __builtin_is_layout_compatible? Yeah, but not in this patch. https://github.com/llvm/llvm-project/pull/100572 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/list

[clang] 3295d37 - [clang] Remove `__is_layout_compatible` from revertible type traits list (#100572)

2024-07-25 Thread via cfe-commits
Author: Vlad Serebrennikov Date: 2024-07-25T20:15:14+04:00 New Revision: 3295d377f37a60597321f502d164b5d6b1948e28 URL: https://github.com/llvm/llvm-project/commit/3295d377f37a60597321f502d164b5d6b1948e28 DIFF: https://github.com/llvm/llvm-project/commit/3295d377f37a60597321f502d164b5d6b1948e28.

[clang] [clang] Remove `__is_layout_compatible` from revertible type traits list (PR #100572)

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

[clang] [clang] Remove `__is_layout_compatible` from revertible type traits list (PR #100572)

2024-07-25 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: /cherry-pick 3295d377f37a60597321f502d164b5d6b1948e28 https://github.com/llvm/llvm-project/pull/100572 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Remove `__is_layout_compatible` from revertible type traits list (PR #100572)

2024-07-25 Thread via cfe-commits
llvmbot wrote: /pull-request llvm/llvm-project#100590 https://github.com/llvm/llvm-project/pull/100572 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver] Introduce ffp-model=aggressive (PR #100453)

2024-07-25 Thread James Y Knight via cfe-commits
jyknight wrote: It seems a bit confusing to me to create a situation where `-ffast-math` is equivalent to `-ffp-model=aggressive`, not `-ffp-model=fast`. https://github.com/llvm/llvm-project/pull/100453 ___ cfe-commits mailing list cfe-commits@lists.l

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

2024-07-25 Thread via cfe-commits
cor3ntin wrote: > Should we prefix this with `__builtin_` as mentioned in [#98310 > (comment)](https://github.com/llvm/llvm-project/issues/98310#issuecomment-2221105713) > ? Yes, if we are doing this, we should be consistent going forward https://github.com/llvm/llvm-project/pull/99473 __

[clang] nonblocking/nonallocating attributes: 2nd pass caller/callee analysis (PR #99656)

2024-07-25 Thread Doug Wyatt via cfe-commits
@@ -0,0 +1,19 @@ +// RUN: %clang_cc1 -fsyntax-only -fblocks -fcxx-exceptions -verify %s + +#pragma clang diagnostic ignored "-Wperf-constraint-implies-noexcept" + +// Objective-C +@interface OCClass +- (void)method; +@end + +void nl14(OCClass *oc) [[clang::nonblocking]] { +

[clang] nonblocking/nonallocating attributes: 2nd pass caller/callee analysis (PR #99656)

2024-07-25 Thread Doug Wyatt via cfe-commits
@@ -4699,7 +4699,7 @@ class FunctionEffect { private: LLVM_PREFERRED_TYPE(Kind) - unsigned FKind : 3; + uint8_t FKind : 3; dougsonos wrote: (sorry, what's "NFC" in this context?) https://github.com/llvm/llvm-project/pull/99656 ___

[clang] nonblocking/nonallocating attributes: 2nd pass caller/callee analysis (PR #99656)

2024-07-25 Thread Doug Wyatt via cfe-commits
https://github.com/dougsonos edited https://github.com/llvm/llvm-project/pull/99656 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Initializer list on RHS of assignment (PR #100548)

2024-07-25 Thread Mital Ashok via cfe-commits
https://github.com/MitalAshok updated https://github.com/llvm/llvm-project/pull/100548 >From 2c1d87c025a8caa818dd275560f31d0d4f8d64b8 Mon Sep 17 00:00:00 2001 From: Mital Ashok Date: Thu, 25 Jul 2024 10:56:16 +0100 Subject: [PATCH 1/2] [Clang] Initializer list on RHS of assignment --- clang/d

[clang] nonblocking/nonallocating attributes: 2nd pass caller/callee analysis (PR #99656)

2024-07-25 Thread Jon Roelofs via cfe-commits
@@ -0,0 +1,194 @@ +// RUN: %clang_cc1 -fsyntax-only -fblocks -fcxx-exceptions -verify %s +// These are in a separate file because errors (e.g. incompatible attributes) currently prevent +// the AnalysisBasedWarnings pass from running at all. + +// This diagnostic is re-enabled an

[clang] 342328d - [CLANG] Emit warning in finite math mode when INF and NAN are used. (#99672)

2024-07-25 Thread via cfe-commits
Author: Zahira Ammarguellat Date: 2024-07-25T12:32:34-04:00 New Revision: 342328db6b2a69cf59c01a6115b1baab925c0736 URL: https://github.com/llvm/llvm-project/commit/342328db6b2a69cf59c01a6115b1baab925c0736 DIFF: https://github.com/llvm/llvm-project/commit/342328db6b2a69cf59c01a6115b1baab925c0736

[clang] [CLANG] Emit warning in finite math mode when INF and NAN are used. (PR #99672)

2024-07-25 Thread Zahira Ammarguellat via cfe-commits
https://github.com/zahiraam closed https://github.com/llvm/llvm-project/pull/99672 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Initializer list on RHS of assignment (PR #100548)

2024-07-25 Thread Mital Ashok via cfe-commits
https://github.com/MitalAshok updated https://github.com/llvm/llvm-project/pull/100548 >From 2c1d87c025a8caa818dd275560f31d0d4f8d64b8 Mon Sep 17 00:00:00 2001 From: Mital Ashok Date: Thu, 25 Jul 2024 10:56:16 +0100 Subject: [PATCH 1/2] [Clang] Initializer list on RHS of assignment --- clang/d

[clang] nonblocking/nonallocating attributes: 2nd pass caller/callee analysis (PR #99656)

2024-07-25 Thread Jon Roelofs via cfe-commits
@@ -0,0 +1,19 @@ +// RUN: %clang_cc1 -fsyntax-only -fblocks -fcxx-exceptions -verify %s + +#pragma clang diagnostic ignored "-Wperf-constraint-implies-noexcept" + +// Objective-C +@interface OCClass +- (void)method; +@end + +void nl14(OCClass *oc) [[clang::nonblocking]] { +

[clang] [PS5][Driver] Ensure stack sizes are emitted by LTO (PR #100592)

2024-07-25 Thread Edd Dawson via cfe-commits
https://github.com/playstation-edd created https://github.com/llvm/llvm-project/pull/100592 ... when requested. Upstreaming a private patch. SIE tracker: TOOLCHAIN-16575 >From cc1cbf728c0e7aa13260af2101c0e312ae81 Mon Sep 17 00:00:00 2001 From: Edd Dawson Date: Thu, 25 Jul 2024 16:58:57 +

[clang] [llvm] [AArch64] Implement intrinsics for SVE FAMIN/FAMAX (PR #99042)

2024-07-25 Thread via cfe-commits
@@ -2385,3 +2385,8 @@ let SVETargetGuard = "sve2p1", SMETargetGuard = "sme2" in { def SVBFMLSLB_LANE : SInst<"svbfmlslb_lane[_{d}]", "dd$$i", "f", MergeNone, "aarch64_sve_bfmlslb_lane", [IsOverloadNone, VerifyRuntimeMode], [ImmCheck<3, ImmCheck0_7>]>; def SVBFMLSLT_LANE :

[clang] [PS5][Driver] Ensure stack sizes are emitted by LTO (PR #100592)

2024-07-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Edd Dawson (playstation-edd) Changes ... when requested. Upstreaming a private patch. SIE tracker: TOOLCHAIN-16575 --- Full diff: https://github.com/llvm/llvm-project/pull/100592.diff 2 Files Affected: - (modified) clang/lib/Driver/To

[clang] nonblocking/nonallocating attributes: 2nd pass caller/callee analysis (PR #99656)

2024-07-25 Thread Doug Wyatt via cfe-commits
https://github.com/dougsonos edited https://github.com/llvm/llvm-project/pull/99656 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] nonblocking/nonallocating attributes: 2nd pass caller/callee analysis (PR #99656)

2024-07-25 Thread Jon Roelofs via cfe-commits
@@ -4699,7 +4699,7 @@ class FunctionEffect { private: LLVM_PREFERRED_TYPE(Kind) - unsigned FKind : 3; + uint8_t FKind : 3; jroelofs wrote: "no functional change" https://llvm.org/docs/Lexicon.html#n https://github.com/llvm/llvm-project/pull/99656 __

[clang] [clang] Implement `__is_virtual_base_of()` intrinsic (PR #100393)

2024-07-25 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll updated https://github.com/llvm/llvm-project/pull/100393 >From 772b5d85dff73de9f6a01a266bd201cbe04923ab Mon Sep 17 00:00:00 2001 From: Vlad Serebrennikov Date: Wed, 24 Jul 2024 17:38:50 +0300 Subject: [PATCH 1/5] [clang] Impement `__is_virtual_base_of()` intrinsic --

[clang] nonblocking/nonallocating attributes: 2nd pass caller/callee analysis (PR #99656)

2024-07-25 Thread Jon Roelofs via cfe-commits
@@ -2397,6 +2397,1262 @@ class UnsafeBufferUsageReporter : public UnsafeBufferUsageHandler { }; } // namespace +// = + +namespace FXAnalysis { + +enum class DiagnosticID : uint8_t { + None = 0, // s

[clang] [clang][rtsan] Introduce realtime sanitizer clang codegen and -fsanitize flag (PR #100192)

2024-07-25 Thread Chris Apple via cfe-commits
cjappl wrote: Thanks to the feedback from @MaskRay and @vitalybuka , closing in favor of doing this processing in LLVM. (PR: https://github.com/llvm/llvm-project/pull/100596) The clang driver changes will come after that is merged! Appreciate all the reviews setting us on the right path. ht

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

2024-07-25 Thread Mark de Wever via cfe-commits
mordante wrote: > > Should we prefix this with `__builtin_` as mentioned in [#98310 > > (comment)](https://github.com/llvm/llvm-project/issues/98310#issuecomment-2221105713) > > ? > > Yes, if we are doing this, we should be consistent going forward I would like that. It's easier directly dete

[clang] [clang][rtsan] Introduce realtime sanitizer clang codegen and -fsanitize flag (PR #100192)

2024-07-25 Thread Chris Apple via cfe-commits
https://github.com/cjappl closed https://github.com/llvm/llvm-project/pull/100192 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

<    1   2   3   4   >