[clang] [clang] [SemaCXX] Disallow deducing "this" on operator `new` and `delete` (PR #82251)

2024-02-20 Thread via cfe-commits
cor3ntin wrote: @Rajveer100 you need us to merge that for you? https://github.com/llvm/llvm-project/pull/82251 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 351e4fa - [Clang] Fix assert when transforming a pack indexing type. (#82234)

2024-02-20 Thread via cfe-commits
Author: cor3ntin Date: 2024-02-21T08:46:47+01:00 New Revision: 351e4fa2bfe5b13073c1675a1b1693ea766c1e25 URL: https://github.com/llvm/llvm-project/commit/351e4fa2bfe5b13073c1675a1b1693ea766c1e25 DIFF: https://github.com/llvm/llvm-project/commit/351e4fa2bfe5b13073c1675a1b1693ea766c1e25.diff

[clang] [Clang] Fix assert when transforming a pack indexing type. (PR #82234)

2024-02-20 Thread via cfe-commits
https://github.com/cor3ntin closed https://github.com/llvm/llvm-project/pull/82234 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AMDGPU] Add an option to disable unsafe uses of atomic xor (PR #69229)

2024-02-20 Thread Pierre van Houtryve via cfe-commits
Pierre-vh wrote: > Thanks for the comments @arsenm @yxsamliu @b-sumner. > > By approaching a similar solution, do you mean MMRAs (#78569) ? > > If so, should I rebase/adapt my patch to the MMRA PR? Or will this PR be > redundant and needs closing? > > @yxsamliu These concise names look good

[clang] [Clang] Fix assert when transforming a pack indexing type. (PR #82234)

2024-02-20 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/82234 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AMDGPU] Emit a waitcnt instruction after each memory instruction (PR #79236)

2024-02-20 Thread Pierre van Houtryve via cfe-commits
@@ -167,6 +167,10 @@ def FeatureCuMode : SubtargetFeature<"cumode", "Enable CU wavefront execution mode" >; +def FeaturePreciseMemory Pierre-vh wrote: Just remove `m_amdgpu_Features_Group` from your option's `SimpleMFlag`, follow the same pattern as

[clang] [clang] [SemaCXX] Disallow deducing "this" on operator `new` and `delete` (PR #82251)

2024-02-20 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik approved this pull request. LGTM, thanks for submitting a fix. https://github.com/llvm/llvm-project/pull/82251 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [llvm] [MC/DC][Coverage] Loosen the limit of NumConds from 6 (PR #82448)

2024-02-20 Thread Hana Dusíková via cfe-commits
hanickadot wrote: > @hanickadot Your comments to `llvm/CoverageMapping.cpp` are not for this PR. > See #80676 . > > They are my preferences. Didn't know the context, I saw it green as added. Just ignore it. https://github.com/llvm/llvm-project/pull/82448

[clang] 8b23d68 - [Analyzer] Support RefAllowingPartiallyDestroyed and RefPtrAllowingPartiallyDestroyed (#82209)

2024-02-20 Thread via cfe-commits
Author: Ryosuke Niwa Date: 2024-02-20T23:02:03-08:00 New Revision: 8b23d68a621f16b6d66e68cb64b99f1221b9df2c URL: https://github.com/llvm/llvm-project/commit/8b23d68a621f16b6d66e68cb64b99f1221b9df2c DIFF: https://github.com/llvm/llvm-project/commit/8b23d68a621f16b6d66e68cb64b99f1221b9df2c.diff

[clang] [Analyzer] Support RefAllowingPartiallyDestroyed and RefPtrAllowingPartiallyDestroyed (PR #82209)

2024-02-20 Thread Ryosuke Niwa via cfe-commits
https://github.com/rniwa closed https://github.com/llvm/llvm-project/pull/82209 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [MC/DC][Coverage] Loosen the limit of NumConds from 6 (PR #82448)

2024-02-20 Thread NAKAMURA Takumi via cfe-commits
chapuni wrote: @hanickadot Your comments to `llvm/CoverageMapping.cpp` are not for this PR. See #80676 . They are my preferences. https://github.com/llvm/llvm-project/pull/82448 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [clang][CodeGen] Keep processing the rest of AST after encountering unsupported MC/DC expressions (PR #82464)

2024-02-20 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Wentao Zhang (whentojump) Changes Currently, upon seeing [unsupported decisions](https://clang.llvm.org/docs/SourceBasedCodeCoverage.html#mc-dc-instrumentation) (more than 6 conditions, or split nesting), the post-visitor hook

[clang] [clang][CodeGen] Keep processing the rest of AST after encountering unsupported MC/DC expressions (PR #82464)

2024-02-20 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-codegen Author: Wentao Zhang (whentojump) Changes Currently, upon seeing [unsupported decisions](https://clang.llvm.org/docs/SourceBasedCodeCoverage.html#mc-dc-instrumentation) (more than 6 conditions, or split nesting), the post-visitor hook

[clang] [clang][CodeGen] Keep processing the rest of AST after encountering unsupported MC/DC expressions (PR #82464)

2024-02-20 Thread Wentao Zhang via cfe-commits
https://github.com/whentojump created https://github.com/llvm/llvm-project/pull/82464 Currently, upon seeing [unsupported decisions](https://clang.llvm.org/docs/SourceBasedCodeCoverage.html#mc-dc-instrumentation) (more than 6 conditions, or split nesting), the post-visitor hook

[clang] [llvm] [MC/DC][Coverage] Loosen the limit of NumConds from 6 (PR #82448)

2024-02-20 Thread NAKAMURA Takumi via cfe-commits
@@ -1959,9 +2013,44 @@ struct CounterCoverageMappingBuilder subtractCounters(ParentCount, TrueCount)); } + void RewindDecision(unsigned Since) { +#ifndef NDEBUG +llvm::DenseSet SeenIDs; +#endif +unsigned NConds = 0; chapuni

[clang] [llvm] [MC/DC][Coverage] Loosen the limit of NumConds from 6 (PR #82448)

2024-02-20 Thread NAKAMURA Takumi via cfe-commits
@@ -723,7 +737,15 @@ struct MCDCCoverageBuilder { if (I == CondIDs.end()) return -1; else - return I->second; + return I->second.ID; + } + + void ccc(const Expr *CondExpr, mcdc::ConditionIDs IDs) { chapuni wrote: This is w-i-p.

[clang] [llvm] [MC/DC][Coverage] Loosen the limit of NumConds from 6 (PR #82448)

2024-02-20 Thread NAKAMURA Takumi via cfe-commits
https://github.com/chapuni commented: Thanks for your comments and sorry for my hasty w-i-p work . I know a few rough implementations would be there. https://github.com/llvm/llvm-project/pull/82448 ___ cfe-commits mailing list

[clang] [llvm] [MC/DC][Coverage] Loosen the limit of NumConds from 6 (PR #82448)

2024-02-20 Thread NAKAMURA Takumi via cfe-commits
https://github.com/chapuni edited https://github.com/llvm/llvm-project/pull/82448 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][Sema] Diagnosis for constexpr constructor not initializing a union member (PR #81225)

2024-02-20 Thread Shafik Yaghmour via cfe-commits
@@ -2471,6 +2480,23 @@ static bool CheckConstexprFunctionBody(Sema , const FunctionDecl *Dcl, return true; } +static bool +checkUnionConstructorIntializer(Sema , const FunctionDecl *Dcl, +const CXXConstructorDecl *Constructor, +

[clang] [Clang][Sema] Diagnosis for constexpr constructor not initializing a union member (PR #81225)

2024-02-20 Thread Shafik Yaghmour via cfe-commits
@@ -2343,17 +2349,9 @@ static bool CheckConstexprFunctionBody(Sema , const FunctionDecl *Dcl, // - if the class is a union having variant members, exactly one of them // shall be initialized; shafik wrote: We need add a reference to

[clang] [Clang][Sema] Diagnosis for constexpr constructor not initializing a union member (PR #81225)

2024-02-20 Thread Shafik Yaghmour via cfe-commits
@@ -2471,6 +2480,23 @@ static bool CheckConstexprFunctionBody(Sema , const FunctionDecl *Dcl, return true; } +static bool +checkUnionConstructorIntializer(Sema , const FunctionDecl *Dcl, +const CXXConstructorDecl *Constructor, +

[clang] [Clang][Sema] Diagnosis for constexpr constructor not initializing a union member (PR #81225)

2024-02-20 Thread Shafik Yaghmour via cfe-commits
@@ -2471,6 +2480,23 @@ static bool CheckConstexprFunctionBody(Sema , const FunctionDecl *Dcl, return true; } +static bool +checkUnionConstructorIntializer(Sema , const FunctionDecl *Dcl, shafik wrote: I really don't like this name, I don't feel like it

[clang] [Clang][Sema] Diagnosis for constexpr constructor not initializing a union member (PR #81225)

2024-02-20 Thread Shafik Yaghmour via cfe-commits
@@ -2393,6 +2391,17 @@ static bool CheckConstexprFunctionBody(Sema , const FunctionDecl *Dcl, Kind)) return false; } +} else if (!Constructor->isDelegatingConstructor()) { shafik wrote: Can

[clang] [llvm] [MC/DC][Coverage] Loosen the limit of NumConds from 6 (PR #82448)

2024-02-20 Thread Hana Dusíková via cfe-commits
@@ -223,9 +223,130 @@ Expected CounterMappingContext::evaluate(const Counter ) const { return LastPoppedValue; } +mcdc::TVIdxBuilder::TVIdxBuilder(const SmallVectorImpl , + int Offset) +: Indices(NextIDs.size()) { + // Construct Nodes

[clang] [llvm] [MC/DC][Coverage] Loosen the limit of NumConds from 6 (PR #82448)

2024-02-20 Thread Hana Dusíková via cfe-commits
@@ -223,9 +223,130 @@ Expected CounterMappingContext::evaluate(const Counter ) const { return LastPoppedValue; } +mcdc::TVIdxBuilder::TVIdxBuilder(const SmallVectorImpl , + int Offset) +: Indices(NextIDs.size()) { + // Construct Nodes

[clang] [llvm] [MC/DC][Coverage] Loosen the limit of NumConds from 6 (PR #82448)

2024-02-20 Thread Hana Dusíková via cfe-commits
@@ -1959,9 +2013,44 @@ struct CounterCoverageMappingBuilder subtractCounters(ParentCount, TrueCount)); } + void RewindDecision(unsigned Since) { +#ifndef NDEBUG +llvm::DenseSet SeenIDs; +#endif +unsigned NConds = 0;

[clang] [llvm] [MC/DC][Coverage] Loosen the limit of NumConds from 6 (PR #82448)

2024-02-20 Thread Hana Dusíková via cfe-commits
@@ -223,9 +223,130 @@ Expected CounterMappingContext::evaluate(const Counter ) const { return LastPoppedValue; } +mcdc::TVIdxBuilder::TVIdxBuilder(const SmallVectorImpl , + int Offset) +: Indices(NextIDs.size()) { + // Construct Nodes

[clang] [llvm] [MC/DC][Coverage] Loosen the limit of NumConds from 6 (PR #82448)

2024-02-20 Thread Hana Dusíková via cfe-commits
https://github.com/hanickadot requested changes to this pull request. https://github.com/llvm/llvm-project/pull/82448 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [MC/DC][Coverage] Loosen the limit of NumConds from 6 (PR #82448)

2024-02-20 Thread Hana Dusíková via cfe-commits
@@ -723,7 +737,15 @@ struct MCDCCoverageBuilder { if (I == CondIDs.end()) return -1; else - return I->second; + return I->second.ID; + } + + void ccc(const Expr *CondExpr, mcdc::ConditionIDs IDs) { hanickadot wrote: this should be

[clang] [llvm] [MC/DC][Coverage] Loosen the limit of NumConds from 6 (PR #82448)

2024-02-20 Thread Hana Dusíková via cfe-commits
https://github.com/hanickadot edited https://github.com/llvm/llvm-project/pull/82448 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Fix crash in TokenAnnotator (PR #82349)

2024-02-20 Thread Owen Pan via cfe-commits
@@ -13503,6 +13503,9 @@ TEST_F(FormatTest, IncorrectCodeUnbalancedBraces) { verifyFormat("{"); verifyFormat("#})"); verifyNoCrash("(/**/[:!] ?[)."); + verifyNoCrash("struct X{" +" operator iunt(" owenca wrote: ```suggestion

[clang] [llvm] [AMDGPU] Enable OpenCL hostcall printf (WIP) (PR #72556)

2024-02-20 Thread Sameer Sahasrabuddhe via cfe-commits
@@ -199,15 +214,31 @@ RValue CodeGenFunction::EmitAMDGPUDevicePrintfCallExpr(const CallExpr *E) { } llvm::Value *Arg = A.getRValue(*this).getScalarVal(); +if (isString(A.getType().getTypePtr()) && CGM.getLangOpts().OpenCL) ssahasra wrote: The

[clang] [llvm] [AMDGPU] Enable OpenCL hostcall printf (WIP) (PR #72556)

2024-02-20 Thread Sameer Sahasrabuddhe via cfe-commits
@@ -198,15 +213,31 @@ RValue CodeGenFunction::EmitAMDGPUDevicePrintfCallExpr(const CallExpr *E) { } llvm::Value *Arg = A.getRValue(*this).getScalarVal(); +if (isString(A.getType().getTypePtr()) && CGM.getLangOpts().OpenCL) + Arg =

[clang] [llvm] [AMDGPU] Enable OpenCL hostcall printf (WIP) (PR #72556)

2024-02-20 Thread Sameer Sahasrabuddhe via cfe-commits
@@ -178,17 +181,29 @@ RValue CodeGenFunction::EmitNVPTXDevicePrintfCallExpr(const CallExpr *E) { E, this, GetVprintfDeclaration(CGM.getModule()), false); } +// Deterimines if an argument is a string +static bool isString(const clang::Type *argXTy) {

[clang] [Headers][X86] Make brief descriptions briefer (PR #82422)

2024-02-20 Thread Phoebe Wang via cfe-commits
https://github.com/phoebewang edited https://github.com/llvm/llvm-project/pull/82422 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Headers][X86] Make brief descriptions briefer (PR #82422)

2024-02-20 Thread Phoebe Wang via cfe-commits
@@ -2099,9 +2099,11 @@ static __inline__ __m128i __DEFAULT_FN_ATTRS _mm_add_epi64(__m128i __a, } /// Adds, with saturation, the corresponding elements of two 128-bit -///signed [16 x i8] vectors, saving each sum in the corresponding element of -///a 128-bit result

[clang] [clang-format] Fix crash in TokenAnnotator (PR #82349)

2024-02-20 Thread Owen Pan via cfe-commits
@@ -3817,7 +3817,7 @@ void TokenAnnotator::calculateFormattingInformation(AnnotatedLine ) const { do { Tok = Tok->Next; } while (Tok && Tok->isNot(TT_OverloadedOperatorLParen)); -if (!Tok) +if (!Tok || !Tok->Next)

[clang] [llvm] [RISCV] RISCV vector calling convention (1/2) (PR #77560)

2024-02-20 Thread Brandon Wu via cfe-commits
4vtomat wrote: Rebase https://github.com/llvm/llvm-project/pull/77560 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Limit how much work guessLanguage() can do (PR #78925)

2024-02-20 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: > The OOM is not limited to `guessLanguage()`. [...] It occurs even if you > rename the header files to .cpp files and clang-format the renamed files > directly. I'm aware of that. However, for clangd users, a crucial difference between `guessLanguage()` vs. other

[clang] 04fbc46 - [clang-format] Fix RemoveSemicolon for empty functions (#82278)

2024-02-20 Thread via cfe-commits
Author: Owen Pan Date: 2024-02-20T21:51:51-08:00 New Revision: 04fbc461e0fd1c6f2b014761e9c03ca80d17b33b URL: https://github.com/llvm/llvm-project/commit/04fbc461e0fd1c6f2b014761e9c03ca80d17b33b DIFF: https://github.com/llvm/llvm-project/commit/04fbc461e0fd1c6f2b014761e9c03ca80d17b33b.diff

[clang] [clang-format] Fix RemoveSemicolon for empty functions (PR #82278)

2024-02-20 Thread Owen Pan via cfe-commits
https://github.com/owenca closed https://github.com/llvm/llvm-project/pull/82278 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AMDGPU] Enable OpenCL hostcall printf (WIP) (PR #72556)

2024-02-20 Thread Vikram Hegde via cfe-commits
vikramRH wrote: The new set of changes adds following changes, 1. The iteration over vector elements now happens using vector size from the format specifier as reference, this is inline with runtime implementation and helps handling undefined behavior when we have a mismatch. 2. The error flag

[clang] [Clang][Sema] fix crash in codegen stage when an lambda expression declared in an unevaluated context (PR #80802)

2024-02-20 Thread Qizhi Hu via cfe-commits
jcsxky wrote: > @jcsxky Do you have more test cases other than the one from #76674? I wonder > what'll happen if constraint checking is involved. Do you mean `concept`? If yes, I will have a try. https://github.com/llvm/llvm-project/pull/80802 ___

[clang] [alpha.webkit.UncountedLocalVarsChecker] Allow uncounted object references within trivial statements (PR #82229)

2024-02-20 Thread Artem Dergachev via cfe-commits
haoNoQ wrote: Ooo interesting. I want to spend a bit more time thinking whether this has to go into every callback, maybe it can be a set-and-forget thing? (Probably not.) Also it might be a good idea to cache only statements that may ever get directly queried. (This seems to be exactly

[clang] [clang] Allow MCTargetOptions to be parseable by -mllvm. (PR #66347)

2024-02-20 Thread via cfe-commits
hstk30-hw wrote: Some project use `Werror` strictly, https://github.com/ClangBuiltLinux/linux/issues/306 add the `-no-deprecated-warn` option, but we can't pass the flags from clang to llvm-mc, change the makefile to use `llvm-mc` to generate obj just for some file is inconvenience.

[clang] [InstallAPI] Set InstallAPI as a standalone tool instead of CC1 action (PR #82293)

2024-02-20 Thread Cyndy Ishida via cfe-commits
https://github.com/cyndyishida updated https://github.com/llvm/llvm-project/pull/82293 >From bd648b50002a64ec098ff450cc6dacc0bc6b Mon Sep 17 00:00:00 2001 From: Cyndy Ishida Date: Tue, 20 Feb 2024 10:06:30 -0800 Subject: [PATCH 1/2] Revert " [clang][InstallAPI] Introduce basic driver to

[clang] [llvm] [MC/DC][Coverage] Loosen the limit of NumConds from 6 (PR #82448)

2024-02-20 Thread NAKAMURA Takumi via cfe-commits
@@ -983,7 +979,7 @@ void CodeGenPGO::mapRegionCounters(const Decl *D) { // for most embedded applications. Setting a maximum value prevents the // bitmap footprint from growing too large without the user's knowledge. In // the future, this value could be adjusted with a

[clang] [ObjC] Check entire chain of superclasses to see if class layout can be statically known (PR #81335)

2024-02-20 Thread via cfe-commits
https://github.com/AtariDreams updated https://github.com/llvm/llvm-project/pull/81335 >From efa382134783898ab2613f13f46dfc3384a3795e Mon Sep 17 00:00:00 2001 From: Rose <83477269+ataridre...@users.noreply.github.com> Date: Fri, 9 Feb 2024 17:51:15 -0500 Subject: [PATCH 1/2] [ObjC] Add

[clang] [ObjC] Check entire chain of superclasses to see if class layout can be statically known (PR #81335)

2024-02-20 Thread via cfe-commits
https://github.com/AtariDreams updated https://github.com/llvm/llvm-project/pull/81335 >From efa382134783898ab2613f13f46dfc3384a3795e Mon Sep 17 00:00:00 2001 From: Rose <83477269+ataridre...@users.noreply.github.com> Date: Fri, 9 Feb 2024 17:51:15 -0500 Subject: [PATCH 1/2] [ObjC] Add

[clang] [ObjC] Check entire chain of superclasses to see if class layout can be statically known (PR #81335)

2024-02-20 Thread via cfe-commits
https://github.com/AtariDreams updated https://github.com/llvm/llvm-project/pull/81335 >From efa382134783898ab2613f13f46dfc3384a3795e Mon Sep 17 00:00:00 2001 From: Rose <83477269+ataridre...@users.noreply.github.com> Date: Fri, 9 Feb 2024 17:51:15 -0500 Subject: [PATCH 1/2] [ObjC] Add

[clang] [compiler-rt] [AArch64] Implement __builtin_cpu_supports, compiler-rt tests. (PR #82378)

2024-02-20 Thread Pavel Iliin via cfe-commits
https://github.com/ilinpv updated https://github.com/llvm/llvm-project/pull/82378 >From 7ada935c9000e915acc9433341e8d4317ff158d6 Mon Sep 17 00:00:00 2001 From: Pavel Iliin Date: Tue, 20 Feb 2024 02:01:04 + Subject: [PATCH 1/2] [AArch64] Implement __builtin_cpu_supports, compiler-rt tests.

[clang] [clang][driver] Allow unaligned access on ARMv7 and higher by default (PR #82400)

2024-02-20 Thread Eli Friedman via cfe-commits
@@ -886,28 +886,16 @@ llvm::ARM::FPUKind arm::getARMTargetFeatures(const Driver , } else { // Assume pre-ARMv6 doesn't support unaligned accesses. // -// ARMv6 may or may not support unaligned accesses depending on the -// SCTLR.U bit, which is

[clang] [Analyzer] Support RefAllowingPartiallyDestroyed and RefPtrAllowingPartiallyDestroyed (PR #82209)

2024-02-20 Thread Ryosuke Niwa via cfe-commits
https://github.com/rniwa updated https://github.com/llvm/llvm-project/pull/82209 >From 1d53adbe50d8afb7c91e8b393c64d6f590256602 Mon Sep 17 00:00:00 2001 From: Ryosuke Niwa Date: Sun, 18 Feb 2024 21:47:48 -0800 Subject: [PATCH 1/2] [analyzer] Support RefAllowingPartiallyDestroyed and

[clang] [Analyzer] Support RefAllowingPartiallyDestroyed and RefPtrAllowingPartiallyDestroyed (PR #82209)

2024-02-20 Thread Ryosuke Niwa via cfe-commits
@@ -103,15 +103,18 @@ std::optional isRefCountable(const CXXRecordDecl* R) return hasRef && hasDeref; } +bool isRefType(const std::string ) { + return name == "Ref" || name == "RefAllowingPartiallyDestroyed" || + name == "RefPtr" || name ==

[clang] [llvm] [MC/DC][Coverage] Loosen the limit of NumConds from 6 (PR #82448)

2024-02-20 Thread Jessica Paquette via cfe-commits
@@ -983,7 +979,7 @@ void CodeGenPGO::mapRegionCounters(const Decl *D) { // for most embedded applications. Setting a maximum value prevents the // bitmap footprint from growing too large without the user's knowledge. In // the future, this value could be adjusted with a

[clang] Sanitizer: Support -fwrapv with -fsanitize=signed-integer-overflow (PR #82432)

2024-02-20 Thread Kees Cook via cfe-commits
https://github.com/kees approved this pull request. Working as expected for me! https://github.com/llvm/llvm-project/pull/82432 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 84ed55e - Revert "[clang][ScanDeps] Canonicalize -D and -U flags (#82298)"

2024-02-20 Thread Nico Weber via cfe-commits
Author: Nico Weber Date: 2024-02-20T20:24:32-05:00 New Revision: 84ed55e11f8d8f434395f869a1caa8485dd0c187 URL: https://github.com/llvm/llvm-project/commit/84ed55e11f8d8f434395f869a1caa8485dd0c187 DIFF: https://github.com/llvm/llvm-project/commit/84ed55e11f8d8f434395f869a1caa8485dd0c187.diff

[clang] [clang][ScanDeps] Canonicalize -D and -U flags (PR #82298)

2024-02-20 Thread Nico Weber via cfe-commits
nico wrote: Also failing here https://lab.llvm.org/buildbot/#/builders/259/builds/126 and here https://lab.llvm.org/buildbot/#/builders/139/builds/59858 Given that the bots have been broken for a few hours now, I'll revert. https://github.com/llvm/llvm-project/pull/82298

[clang] [clang][ScanDeps] Canonicalize -D and -U flags (PR #82298)

2024-02-20 Thread Nico Weber via cfe-commits
nico wrote: The test is failing at least on my bot: http://45.33.8.238/linux/131314/step_7.txt I'm guessing this is some unicode/sed thing? It's a pretty vanilla linux machine. (It uses a non-standard non-supported build system, but at least from a distance that looks unrelated?)

[clang] [clang][analyzer] Change modeling of 'fileno' in checkers. (PR #81842)

2024-02-20 Thread Ben Shi via cfe-commits
=?utf-8?q?Balázs_Kéri?= Message-ID: In-Reply-To: @@ -1404,6 +1486,47 @@ void StreamChecker::evalFeofFerror(const FnDescription *Desc, } } +void StreamChecker::evalFileno(const FnDescription *Desc, const CallEvent , + CheckerContext ) const

[clang] [clang][analyzer] Change modeling of 'fileno' in checkers. (PR #81842)

2024-02-20 Thread Ben Shi via cfe-commits
=?utf-8?q?Bal=C3=A1zs_K=C3=A9ri?= Message-ID: In-Reply-To: @@ -268,6 +268,16 @@ void test_clearerr(FILE *F) { // expected-warning@-1{{FALSE}} } +void test_fileno(FILE *F) { + errno = 0; + int A = fileno(F); + clang_analyzer_eval(F !=

[clang] [clang][analyzer] Change modeling of 'fileno' in checkers. (PR #81842)

2024-02-20 Thread Ben Shi via cfe-commits
=?utf-8?q?Bal=C3=A1zs_K=C3=A9ri?= Message-ID: In-Reply-To: https://github.com/benshi001 approved this pull request. https://github.com/llvm/llvm-project/pull/81842 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [clang][analyzer] Change modeling of 'fileno' in checkers. (PR #81842)

2024-02-20 Thread Ben Shi via cfe-commits
=?utf-8?q?Balázs_Kéri?= Message-ID: In-Reply-To: https://github.com/benshi001 edited https://github.com/llvm/llvm-project/pull/81842 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Sanitizer: Support -fwrapv with -fsanitize=signed-integer-overflow (PR #82432)

2024-02-20 Thread Kees Cook via cfe-commits
kees wrote: This doesn't seem to do anything for me with the Linux kernel's -next branch (which supports -sio as `CONFIG_UBSAN_SIGNED_WRAP=y`). e.g. I see no behavioral difference with test_ubsan.ko nor the expected atomic overflows. https://github.com/llvm/llvm-project/pull/82432

[clang] [alpha.webkit.UncountedCallArgsChecker] Ignore calls to WTF's container methods (PR #82156)

2024-02-20 Thread Ryosuke Niwa via cfe-commits
https://github.com/rniwa closed https://github.com/llvm/llvm-project/pull/82156 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 031f9f3 - [alpha.webkit.UncountedCallArgsChecker] Ignore calls to WTF's container methods (#82156)

2024-02-20 Thread via cfe-commits
Author: Ryosuke Niwa Date: 2024-02-20T17:12:24-08:00 New Revision: 031f9f331723e6bebc405ffdee4b8a87a5fc0472 URL: https://github.com/llvm/llvm-project/commit/031f9f331723e6bebc405ffdee4b8a87a5fc0472 DIFF: https://github.com/llvm/llvm-project/commit/031f9f331723e6bebc405ffdee4b8a87a5fc0472.diff

[clang] [alpha.webkit.UncountedCallArgsChecker] Ignore calls to WTF's container methods (PR #82156)

2024-02-20 Thread Ryosuke Niwa via cfe-commits
rniwa wrote: Yeah, indeed. Thank you for the review! https://github.com/llvm/llvm-project/pull/82156 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Analyzer] Support RefAllowingPartiallyDestroyed and RefPtrAllowingPartiallyDestroyed (PR #82209)

2024-02-20 Thread Ryosuke Niwa via cfe-commits
@@ -103,15 +103,18 @@ std::optional isRefCountable(const CXXRecordDecl* R) return hasRef && hasDeref; } +bool isRefType(const std::string ) { + return name == "Ref" || name == "RefAllowingPartiallyDestroyed" || + name == "RefPtr" || name ==

[clang] [Analyzer] Support RefAllowingPartiallyDestroyed and RefPtrAllowingPartiallyDestroyed (PR #82209)

2024-02-20 Thread Artem Dergachev via cfe-commits
https://github.com/haoNoQ approved this pull request. LGTM! I have one stylistic nitpick. https://github.com/llvm/llvm-project/pull/82209 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [Analyzer] Support RefAllowingPartiallyDestroyed and RefPtrAllowingPartiallyDestroyed (PR #82209)

2024-02-20 Thread Artem Dergachev via cfe-commits
@@ -103,15 +103,18 @@ std::optional isRefCountable(const CXXRecordDecl* R) return hasRef && hasDeref; } +bool isRefType(const std::string ) { + return name == "Ref" || name == "RefAllowingPartiallyDestroyed" || + name == "RefPtr" || name ==

[clang] [Analyzer] Support RefAllowingPartiallyDestroyed and RefPtrAllowingPartiallyDestroyed (PR #82209)

2024-02-20 Thread Artem Dergachev via cfe-commits
https://github.com/haoNoQ edited https://github.com/llvm/llvm-project/pull/82209 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [MC/DC][Coverage] Loosen the limit of NumConds from 6 (PR #82448)

2024-02-20 Thread NAKAMURA Takumi via cfe-commits
https://github.com/chapuni edited https://github.com/llvm/llvm-project/pull/82448 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver] Improve error when a compiler-rt library is not found (PR #81037)

2024-02-20 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay updated https://github.com/llvm/llvm-project/pull/81037 >From c9dc3ca27e6978a3b6595d094e32cbd9cd102f64 Mon Sep 17 00:00:00 2001 From: Fangrui Song Date: Wed, 7 Feb 2024 12:56:05 -0800 Subject: [PATCH] [Driver] Improve error when a compiler-rt library is not found

[clang] [Driver,BareMetal] Replace -lclang_rt.builtins{,-$arch}.a with an absolute path (PR #82424)

2024-02-20 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay closed https://github.com/llvm/llvm-project/pull/82424 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 4ca0480 - [Driver,BareMetal] Replace -lclang_rt.builtins{,-$arch}.a with an absolute path (#82424)

2024-02-20 Thread via cfe-commits
Author: Fangrui Song Date: 2024-02-20T16:54:27-08:00 New Revision: 4ca0480a4fefe25c2f6e36c04f02998af79274a0 URL: https://github.com/llvm/llvm-project/commit/4ca0480a4fefe25c2f6e36c04f02998af79274a0 DIFF: https://github.com/llvm/llvm-project/commit/4ca0480a4fefe25c2f6e36c04f02998af79274a0.diff

[clang] [llvm] [AMDGPU] Emit a waitcnt instruction after each memory instruction (PR #79236)

2024-02-20 Thread Jun Wang via cfe-commits
https://github.com/jwanggit86 edited https://github.com/llvm/llvm-project/pull/79236 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AMDGPU] Emit a waitcnt instruction after each memory instruction (PR #79236)

2024-02-20 Thread Jun Wang via cfe-commits
@@ -167,6 +167,10 @@ def FeatureCuMode : SubtargetFeature<"cumode", "Enable CU wavefront execution mode" >; +def FeaturePreciseMemory jwanggit86 wrote: A possible fix is to check `hasFlag` after calling `handleTargetFeaturesGroup`, and if the check is

[clang] [llvm] [AMDGPU] Emit a waitcnt instruction after each memory instruction (PR #79236)

2024-02-20 Thread Jun Wang via cfe-commits
https://github.com/jwanggit86 edited https://github.com/llvm/llvm-project/pull/79236 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AMDGPU] Emit a waitcnt instruction after each memory instruction (PR #79236)

2024-02-20 Thread Jun Wang via cfe-commits
@@ -167,6 +167,10 @@ def FeatureCuMode : SubtargetFeature<"cumode", "Enable CU wavefront execution mode" >; +def FeaturePreciseMemory jwanggit86 wrote: @Pierre-vh With the suggested change, the func `getAMDGPUTargetFeatures` looks something like the

[clang] [llvm] [clang] Use separator for large numeric values in overflow diagnostic (PR #80939)

2024-02-20 Thread Atousa Duprat via cfe-commits
Atousa wrote: humble ping @AaronBallman https://github.com/llvm/llvm-project/pull/80939 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Sanitizer: Support -fwrapv with -fsanitize=signed-integer-overflow (PR #82432)

2024-02-20 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay approved this pull request. https://github.com/llvm/llvm-project/pull/82432 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NVPTX] Enable the _Float16 type for NVPTX compilation (PR #82436)

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

[clang] 53e9698 - [NVPTX] Enable the _Float16 type for NVPTX compilation (#82436)

2024-02-20 Thread via cfe-commits
Author: Joseph Huber Date: 2024-02-20T18:12:27-06:00 New Revision: 53e96984b6dbb9d8ff55d2ccd0c27ffc1d27315f URL: https://github.com/llvm/llvm-project/commit/53e96984b6dbb9d8ff55d2ccd0c27ffc1d27315f DIFF: https://github.com/llvm/llvm-project/commit/53e96984b6dbb9d8ff55d2ccd0c27ffc1d27315f.diff

[clang] [NVPTX] Enable the _Float16 type for NVPTX compilation (PR #82436)

2024-02-20 Thread Artem Belevich via cfe-commits
https://github.com/Artem-B approved this pull request. https://github.com/llvm/llvm-project/pull/82436 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL][Doc] Add doc about expected differences (PR #82395)

2024-02-20 Thread Chris B via cfe-commits
https://github.com/llvm-beanz updated https://github.com/llvm/llvm-project/pull/82395 >From 558dd6182a4dc6fc5c5383358cac422289a7a90b Mon Sep 17 00:00:00 2001 From: Chris Bieneman Date: Tue, 20 Feb 2024 12:01:16 -0600 Subject: [PATCH 1/5] [HLSL][Doc] Add doc about expected differences This

[clang] [compiler-rt] [asan][windows] Eliminate the static asan runtime on windows (PR #81677)

2024-02-20 Thread Charlie Barto via cfe-commits
https://github.com/barcharcraz ready_for_review https://github.com/llvm/llvm-project/pull/81677 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [alpha.webkit.UncountedCallArgsChecker] Ignore calls to WTF's container methods (PR #82156)

2024-02-20 Thread Artem Dergachev via cfe-commits
https://github.com/haoNoQ approved this pull request. Ooo this is much cleaner! https://github.com/llvm/llvm-project/pull/82156 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Sanitizer: Support -fwrapv with -fsanitize=signed-integer-overflow (PR #82432)

2024-02-20 Thread Justin Stitt via cfe-commits
https://github.com/JustinStitt edited https://github.com/llvm/llvm-project/pull/82432 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Sanitizer: Support -fwrapv with -fsanitize=signed-integer-overflow (PR #82432)

2024-02-20 Thread Justin Stitt via cfe-commits
@@ -70,6 +77,7 @@ void test1(void) { // WRAPV: add i8 {{.*}}, 1 JustinStitt wrote: How's [1d9cb0a](https://github.com/llvm/llvm-project/pull/82432/commits/1d9cb0aca8985aa1636780b3ff9a863962cc2d57) look? https://github.com/llvm/llvm-project/pull/82432

[clang] Sanitizer: Support -fwrapv with -fsanitize=signed-integer-overflow (PR #82432)

2024-02-20 Thread Justin Stitt via cfe-commits
https://github.com/JustinStitt updated https://github.com/llvm/llvm-project/pull/82432 >From b02b09b9eb4f9a8ac60dd077d95c67b959db3b70 Mon Sep 17 00:00:00 2001 From: Justin Stitt Date: Tue, 20 Feb 2024 22:21:02 + Subject: [PATCH 1/4] support fwrapv with signed int overflow sanitizer ---

[clang] [clang][driver] Allow unaligned access on ARMv7 and higher by default (PR #82400)

2024-02-20 Thread Paul Kirth via cfe-commits
@@ -886,28 +886,16 @@ llvm::ARM::FPUKind arm::getARMTargetFeatures(const Driver , } else { // Assume pre-ARMv6 doesn't support unaligned accesses. // -// ARMv6 may or may not support unaligned accesses depending on the -// SCTLR.U bit, which is

[clang] [clang][driver] Allow unaligned access on ARMv7 and higher by default (PR #82400)

2024-02-20 Thread Paul Kirth via cfe-commits
@@ -305,6 +305,16 @@ X86 Support Arm and AArch64 Support ^^^ +- ARMv6+ targets now default to allowing unaligned access, except Armv6-M, and + Armv8-M without the Main Extension. Baremetal targets should check that the + new default will work with their

[clang] [clang][driver] Allow unaligned access on ARMv7 and higher by default (PR #82400)

2024-02-20 Thread Paul Kirth via cfe-commits
https://github.com/ilovepi updated https://github.com/llvm/llvm-project/pull/82400 >From 20634c2f54ae667ee8374d12e58e582aa6cdd051 Mon Sep 17 00:00:00 2001 From: Paul Kirth Date: Tue, 20 Feb 2024 10:34:57 -0800 Subject: [PATCH 1/4] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20in?=

[clang] [HLSL][Doc] Add doc about expected differences (PR #82395)

2024-02-20 Thread Damyan Pepper via cfe-commits
https://github.com/damyanp approved this pull request. https://github.com/llvm/llvm-project/pull/82395 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][ScanDeps] Canonicalize -D and -U flags (PR #82298)

2024-02-20 Thread Michael Spencer via cfe-commits
https://github.com/Bigcheese closed https://github.com/llvm/llvm-project/pull/82298 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 3ff8055 - [clang][ScanDeps] Canonicalize -D and -U flags (#82298)

2024-02-20 Thread via cfe-commits
Author: Michael Spencer Date: 2024-02-20T15:20:40-08:00 New Revision: 3ff805540173b83d73b673b39ac5760fc19bac15 URL: https://github.com/llvm/llvm-project/commit/3ff805540173b83d73b673b39ac5760fc19bac15 DIFF:

[clang] [clang][ScanDeps] Canonicalize -D and -U flags (PR #82298)

2024-02-20 Thread Michael Spencer via cfe-commits
https://github.com/Bigcheese updated https://github.com/llvm/llvm-project/pull/82298 >From b60972ed9183dd9e2deb3860f7732dc87bdfc84e Mon Sep 17 00:00:00 2001 From: Michael Spencer Date: Fri, 16 Feb 2024 22:05:25 -0800 Subject: [PATCH] Canonicalize -D and -U flags Canonicalize `-D` and `-U`

[clang] Sanitizer: Support -fwrapv with -fsanitize=signed-integer-overflow (PR #82432)

2024-02-20 Thread Fangrui Song via cfe-commits
@@ -70,6 +77,7 @@ void test1(void) { // WRAPV: add i8 {{.*}}, 1 MaskRay wrote: L72 needs a `// CATCH_WRAP: getelementptr i32, ptr` Actually, since -fsanitize=signed-integer-overflow and -fwrapv -fsanitize=signed-integer-overflow share so many checks.

[clang-tools-extra] [clangd] Fix renaming single argument ObjC methods (PR #82396)

2024-02-20 Thread Alex Hoppen via cfe-commits
https://github.com/ahoppen approved this pull request. Thanks for fixing! https://github.com/llvm/llvm-project/pull/82396 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [attributes][analyzer] Generalize [[clang::suppress]] to declarations. (PR #80371)

2024-02-20 Thread Erich Keane via cfe-commits
erichkeane wrote: > Ok gotcha thanks! In any case, I'll do my best to handle this more gracefully > in the future. Your advice is always appreciated! Perfect! I'll try to be better about this in the future as well. https://github.com/llvm/llvm-project/pull/80371

  1   2   3   4   5   >