[clang] [clang][dataflow] Model the fields that are accessed via inline accessors (PR #66368)

2023-09-18 Thread via cfe-commits
https://github.com/martinboehme closed https://github.com/llvm/llvm-project/pull/66368 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 03be486 - [clang][dataflow] Model the fields that are accessed via inline accessors (#66368)

2023-09-18 Thread via cfe-commits
Author: Kinuko Yasuda Date: 2023-09-18T10:46:36+02:00 New Revision: 03be486ecc256638a94243de8260a95e1b25bca4 URL: https://github.com/llvm/llvm-project/commit/03be486ecc256638a94243de8260a95e1b25bca4 DIFF: https://github.com/llvm/llvm-project/commit/03be486ecc256638a94243de8260a95e1b25bca4.diff

[PATCH] D158156: [analyzer] Add C++ array delete checker

2023-09-18 Thread Discookie via Phabricator via cfe-commits
Discookie marked 6 inline comments as done. Discookie added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/CXXDeleteChecker.cpp:220 N->getLocationContext()); - return std::make_shared(Pos, OS.str(), true); + return

[clang] [clang][Sema] Stop format size estimator upon %p to adapt to linux kernel's extension (PR #65969)

2023-09-18 Thread Takuya Shimizu via cfe-commits
https://github.com/hazohelet updated https://github.com/llvm/llvm-project/pull/65969 >From 5ee1a4f83c69b5e2910ea883dca7f0fa2c1a4bd3 Mon Sep 17 00:00:00 2001 From: Takuya Shimizu Date: Wed, 13 Sep 2023 17:43:11 +0900 Subject: [PATCH 1/4] [clang][Diagnostics] Separate Wformat-overflow and

[PATCH] D158156: [analyzer] Add C++ array delete checker

2023-09-18 Thread Discookie via Phabricator via cfe-commits
Discookie marked 12 inline comments as done. Discookie added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/CXXDeleteChecker.cpp:192 + + const Stmt *S = N->getStmtForDiagnostics(); + if (!S) steakhal wrote: > Discookie wrote: > > steakhal

[PATCH] D157615: [ExtendLifetimes][1/4] Add "disable-post-ra" function attribute to disable the post-regalloc scheduler

2023-09-18 Thread Stephen Tozer via Phabricator via cfe-commits
StephenTozer added a comment. In D157615#4646848 , @dblaikie wrote: > Might be worth rewording the commit, or splitting it - I'd say the > introduction of `optdebug` should be the noteworthier part of this patch (or > whichever patch introduces it) -

[PATCH] D158472: [clang][Diagnostics] Emit fix-it hint separately on overload resolution failure

2023-09-18 Thread Takuya Shimizu via Phabricator via cfe-commits
hazohelet abandoned this revision. hazohelet added a comment. In D158472#4645378 , @aaron.ballman wrote: > In D158472#4605228 , @hazohelet > wrote: > >> This breaks the one-note-for-one-overload-candidate rule

[clang-tools-extra] [clang-tidy] Update llvmlibc-implementation-in-namespace to new rules (PR #66504)

2023-09-18 Thread Guillaume Chatelet via cfe-commits
gchatelet wrote: > Should this change be reflected in the Release Notes? Where would that be? `clang-tools-extra/docs/ReleaseNotes.rst`? I can't find what the current release notes look like for head. https://github.com/llvm/llvm-project/pull/66504

[PATCH] D158156: [analyzer] Add C++ array delete checker

2023-09-18 Thread Discookie via Phabricator via cfe-commits
Discookie updated this revision to Diff 556933. Discookie added a comment. Updated the visitor to track all conversions, and have type names for clarity. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D158156/new/ https://reviews.llvm.org/D158156 Files:

[PATCH] D158476: [driver] Search for compatible Android runtime directories

2023-09-18 Thread Petr Hosek via Phabricator via cfe-commits
phosek accepted this revision. phosek added a comment. This revision is now accepted and ready to land. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D158476/new/ https://reviews.llvm.org/D158476

[PATCH] D159292: [driver] Conditionally include installed libc++ headers for Android

2023-09-18 Thread Petr Hosek via Phabricator via cfe-commits
phosek accepted this revision. phosek added a comment. This revision is now accepted and ready to land. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D159292/new/ https://reviews.llvm.org/D159292

[clang] [clang-transformer] Allow stencils to read from system headers. (PR #66480)

2023-09-18 Thread Clement Courbet via cfe-commits
https://github.com/legrosbuffle closed https://github.com/llvm/llvm-project/pull/66480 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 75b76c4 - [clang-transformer] Allow stencils to read from system headers. (#66480)

2023-09-18 Thread via cfe-commits
Author: Clement Courbet Date: 2023-09-18T10:07:30+02:00 New Revision: 75b76c4b477e98b5e74f986f18acc04b4ada URL: https://github.com/llvm/llvm-project/commit/75b76c4b477e98b5e74f986f18acc04b4ada DIFF:

[clang] [RISCV] Support predefined marcro __riscv_misaligned_{fast,avoid}. (PR #65756)

2023-09-18 Thread Yeting Kuo via cfe-commits
@@ -1220,3 +1220,15 @@ // RUN: -march=rv64i_zve32x_zvkt1p0 -x c -E -dM %s \ // RUN: -o - | FileCheck --check-prefix=CHECK-ZVKT-EXT %s // CHECK-ZVKT-EXT: __riscv_zvkt 100{{$}} + +// RUN: %clang -target riscv32-unknown-linux-gnu -march=rv32i -x c -E -dM %s \

[clang] [RISCV] Support predefined marcro __riscv_misaligned_{fast,avoid}. (PR #65756)

2023-09-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Changes RISC-V C API introduced predefined macro to achieve hints about unaligned accesses ([pr]). This patch defines __riscv_misaligned_fast when using -mno-strict-align, otherwise, defines __riscv_misaligned_avoid. Note: This ignores

[PATCH] D158516: [clang][Interp] Only lazily visit constant globals

2023-09-18 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added a comment. Ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D158516/new/ https://reviews.llvm.org/D158516 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D157252: [clang][ExprConst] Handle 0 type size in builtin_memcpy etc.

2023-09-18 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added a comment. Ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D157252/new/ https://reviews.llvm.org/D157252 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [RISCV] Support predefined marcro __riscv_misaligned_{fast,avoid}. (PR #65756)

2023-09-18 Thread Yeting Kuo via cfe-commits
https://github.com/yetingk updated https://github.com/llvm/llvm-project/pull/65756 >From 391711dd39e2ee2e8f5d3dac6f466649238f4517 Mon Sep 17 00:00:00 2001 From: Yeting Kuo Date: Fri, 8 Sep 2023 19:46:03 +0800 Subject: [PATCH] [RISCV] Support predefined marcro __riscv_misaligned_{fast,avoid}.

[PATCH] D156453: [clang][Interp] Create only globals when initializing a global variable

2023-09-18 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added a comment. Ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156453/new/ https://reviews.llvm.org/D156453 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D154581: [clang][Interp] Track existing InitMaps in InterpState

2023-09-18 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added a comment. Ping CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154581/new/ https://reviews.llvm.org/D154581 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D154262: [clang][Interp] LambdaThisCaptures

2023-09-18 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added a comment. Ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154262/new/ https://reviews.llvm.org/D154262 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] Support target names with dots in more utilities (PR #65812)

2023-09-18 Thread James Henderson via cfe-commits
@@ -1696,6 +1696,38 @@ TEST(Support, ReplacePathPrefix) { EXPECT_EQ(Path, "C:\\old/foo\\bar"); } +TEST(Support, FindProgramName) { + StringRef WindowsProgName = + path::program_name("C:\\Test\\foo.exe", path::Style::windows); + EXPECT_EQ(WindowsProgName, "foo"); + +

[clang] Support target names with dots in more utilities (PR #65812)

2023-09-18 Thread James Henderson via cfe-commits
@@ -600,6 +600,14 @@ StringRef extension(StringRef path, Style style) { return fname.substr(pos); } +StringRef program_name(StringRef path, Style style) { + // In the future this may need to be extended to other + // program suffixes. jh7370 wrote:

[clang] Support target names with dots in more utilities (PR #65812)

2023-09-18 Thread James Henderson via cfe-commits
@@ -390,6 +390,21 @@ StringRef stem(StringRef path, Style style = Style::native); /// @result The extension of \a path. StringRef extension(StringRef path, Style style = Style::native); +/// Get the program's name +/// +/// If the path ends with the string .exe, returns the

[clang] Support target names with dots in more utilities (PR #65812)

2023-09-18 Thread James Henderson via cfe-commits
@@ -5,16 +5,22 @@ # RUN: mkdir %t # RUN: ln -s llvm-ar %t/llvm-ar-9 # RUN: ln -s llvm-ar %t/ar.exe +# RUN: ln -s llvm-ar %t/x86_64-portbld-freebsd13.2-llvm-ar +# RUN: ln -s llvm-ar %t/x86_64-portbld-freebsd13.2-llvm-ar.exe # RUN: ln -s llvm-ar

[clang] [Sema] add cast from IncompleteArrayType to ConstantArrayType in TryReferenceListInitialization (PR #65918)

2023-09-18 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 updated https://github.com/llvm/llvm-project/pull/65918 >From cfedbe3fb2f2f331b3f9ee1f4f3e2fcd348797e2 Mon Sep 17 00:00:00 2001 From: Congcong Cai Date: Mon, 11 Sep 2023 09:15:41 +0800 Subject: [PATCH 1/5] [Sema] add cast from IncompleteArrayType to

[clang-tools-extra] [clang-tidy] Update llvmlibc-implementation-in-namespace to new rules (PR #66504)

2023-09-18 Thread Guillaume Chatelet via cfe-commits
https://github.com/gchatelet updated https://github.com/llvm/llvm-project/pull/66504 >From f1427a81c4a3425c1a574316fc26d2c74297b34b Mon Sep 17 00:00:00 2001 From: Guillaume Chatelet Date: Fri, 15 Sep 2023 12:34:17 + Subject: [PATCH 1/2] [clang-tidy] Update

[clang] 9ea083f - [Clang][test] Replace legacy -target with --target=. (#66572)

2023-09-18 Thread via cfe-commits
Author: Yeting Kuo Date: 2023-09-18T15:35:57+08:00 New Revision: 9ea083f2d4049d398c00b9a6de1e95979ec2c157 URL: https://github.com/llvm/llvm-project/commit/9ea083f2d4049d398c00b9a6de1e95979ec2c157 DIFF: https://github.com/llvm/llvm-project/commit/9ea083f2d4049d398c00b9a6de1e95979ec2c157.diff

[clang] [Clang][test] Replace legacy -target with --target=. (PR #66572)

2023-09-18 Thread Yeting Kuo via cfe-commits
https://github.com/yetingk closed https://github.com/llvm/llvm-project/pull/66572 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [analyzer] Add std::variant checker (PR #66481)

2023-09-18 Thread Balazs Benics via cfe-commits
@@ -318,6 +318,10 @@ def C11LockChecker : Checker<"C11Lock">, Dependencies<[PthreadLockBase]>, Documentation; +def StdVariantChecker : Checker<"StdVariant">, + HelpText<"Check wether we access the right type stored in std::variant">, steakhal wrote:

[clang] [analyzer] Add std::variant checker (PR #66481)

2023-09-18 Thread Balazs Benics via cfe-commits
https://github.com/steakhal commented: This is my first round of review. So far it looks good. I didn't have much time, but that's all I had. I think it would make sense to have tests for variants containing variants and playing with the active members. That would be interesting to see.

[clang] [analyzer] Add std::variant checker (PR #66481)

2023-09-18 Thread Balazs Benics via cfe-commits
@@ -0,0 +1,312 @@ +//===- StdVariantChecker.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] [analyzer] Add std::variant checker (PR #66481)

2023-09-18 Thread Balazs Benics via cfe-commits
@@ -0,0 +1,312 @@ +//===- StdVariantChecker.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] [analyzer] Add std::variant checker (PR #66481)

2023-09-18 Thread Balazs Benics via cfe-commits
@@ -0,0 +1,312 @@ +//===- StdVariantChecker.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] [analyzer] Add std::variant checker (PR #66481)

2023-09-18 Thread Balazs Benics via cfe-commits
@@ -0,0 +1,312 @@ +//===- StdVariantChecker.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] [analyzer] Add std::variant checker (PR #66481)

2023-09-18 Thread Balazs Benics via cfe-commits
@@ -0,0 +1,312 @@ +//===- StdVariantChecker.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] [analyzer] Add std::variant checker (PR #66481)

2023-09-18 Thread Balazs Benics via cfe-commits
@@ -0,0 +1,312 @@ +//===- StdVariantChecker.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] [analyzer] Add std::variant checker (PR #66481)

2023-09-18 Thread Balazs Benics via cfe-commits
@@ -0,0 +1,312 @@ +//===- StdVariantChecker.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] [analyzer] Add std::variant checker (PR #66481)

2023-09-18 Thread Balazs Benics via cfe-commits
@@ -0,0 +1,312 @@ +//===- StdVariantChecker.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] [analyzer] Add std::variant checker (PR #66481)

2023-09-18 Thread Balazs Benics via cfe-commits
@@ -0,0 +1,128 @@ +//===- TaggedUnionModeling.h -*- 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] [analyzer] Add std::variant checker (PR #66481)

2023-09-18 Thread Balazs Benics via cfe-commits
@@ -0,0 +1,312 @@ +//===- StdVariantChecker.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] [analyzer] Add std::variant checker (PR #66481)

2023-09-18 Thread Balazs Benics via cfe-commits
@@ -0,0 +1,312 @@ +//===- StdVariantChecker.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] [analyzer] Add std::variant checker (PR #66481)

2023-09-18 Thread Balazs Benics via cfe-commits
@@ -0,0 +1,312 @@ +//===- StdVariantChecker.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] [analyzer] Add std::variant checker (PR #66481)

2023-09-18 Thread Balazs Benics via cfe-commits
https://github.com/steakhal edited https://github.com/llvm/llvm-project/pull/66481 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [analyzer] Add std::variant checker (PR #66481)

2023-09-18 Thread Balazs Benics via cfe-commits
@@ -0,0 +1,312 @@ +//===- StdVariantChecker.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] [clang][docs] Pass full path of source TD file to gen_rst_from_td. [NFC] (PR #66497)

2023-09-18 Thread Francesco Petrogalli via cfe-commits
fpetrogalli wrote: Hi @tstellar - this is the wrong approach, I will abandon the patch. Apologies for the noise! https://github.com/llvm/llvm-project/pull/66497 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [clang][docs] Pass full path of source TD file to gen_rst_from_td. [NFC] (PR #66497)

2023-09-18 Thread Francesco Petrogalli via cfe-commits
https://github.com/fpetrogalli closed https://github.com/llvm/llvm-project/pull/66497 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Introduce paged vector (PR #66430)

2023-09-18 Thread Giulio Eulisse via cfe-commits
@@ -0,0 +1,133 @@ +//===- llvm/ADT/PagedVector.h - 'Lazyly allocated' vectors *- C++ +//-*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +//

[clang] Introduce paged vector (PR #66430)

2023-09-18 Thread Giulio Eulisse via cfe-commits
@@ -0,0 +1,131 @@ +//===- llvm/ADT/PagedVector.h - 'Lazyly allocated' vectors *- C++ +//-*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +//

[clang] [analyzer] Fix StackAddrEscapeChecker crash on temporary object fields (PR #66493)

2023-09-18 Thread Balazs Benics via cfe-commits
steakhal wrote: Let me know if you are still okay with the latest change. @DonatNagyE @Xazax-hun https://github.com/llvm/llvm-project/pull/66493 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] Introduce paged vector (PR #66430)

2023-09-18 Thread Giulio Eulisse via cfe-commits
@@ -1625,6 +1625,35 @@ SmallVector has grown a few other minor advantages over std::vector, causing and is no longer "private to the implementation". A name like ``SmallVectorHeader`` might be more appropriate. +.. _dss_pagedvector: + +llvm/ADT/PagedVector.h

[clang] [analyzer] Fix StackAddrEscapeChecker crash on temporary object fields (PR #66493)

2023-09-18 Thread Balazs Benics via cfe-commits
https://github.com/steakhal updated https://github.com/llvm/llvm-project/pull/66493 >From cfdbc40487481b341d42f0472e196ff4bd33 Mon Sep 17 00:00:00 2001 From: Balazs Benics Date: Fri, 15 Sep 2023 12:42:39 +0200 Subject: [PATCH 1/2] [analyzer] Fix StackAddrEscapeChecker crash on temporary

[clang] Introduce paged vector (PR #66430)

2023-09-18 Thread Giulio Eulisse via cfe-commits
https://github.com/ktf resolved https://github.com/llvm/llvm-project/pull/66430 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Introduce paged vector (PR #66430)

2023-09-18 Thread Giulio Eulisse via cfe-commits
https://github.com/ktf updated https://github.com/llvm/llvm-project/pull/66430 >From b952f0577dfe8112f394bd5392212f843c0cc86e Mon Sep 17 00:00:00 2001 From: Giulio Eulisse <10544+...@users.noreply.github.com> Date: Thu, 14 Sep 2023 21:58:21 +0200 Subject: [PATCH 01/15] Introduce PagedVector

[clang] [analyzer] TaintPropagation checker strlen() should not propagate (PR #66086)

2023-09-18 Thread Balazs Benics via cfe-commits
steakhal wrote: As I'm not a maintainer, I could not push to your branch. Here is a patch that I think has the missing pieces to satisfy my review.

<    1   2   3   4   5