[PATCH] D142077: [Clang][SemaCXX][Coroutines] Fix misleading diagnostics with -Wunsequenced

2023-02-03 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Thanks for the review, will push once all tests pass! Comment at: clang/lib/Sema/SemaChecking.cpp:15186 + if (ChildExpr == CSE->getOperand()) +// Do not recurse over a CoroutineSuspendExpr's operand. +// The operand is also a subexpre

[PATCH] D143128: [-Wunsafe-buffer-usage][WIP] Fix-Its transforming `&DRE[any]` to `DRE.data() + any`

2023-02-03 Thread Ziqing Luo via Phabricator via cfe-commits
ziqingluo-90 updated this revision to Diff 494711. ziqingluo-90 retitled this revision from "[-Wunsafe-buffer-usage][WIP] Fix-Its transforming `&DRE[*]` to `DRE.data() + *`" to "[-Wunsafe-buffer-usage][WIP] Fix-Its transforming `&DRE[any]` to `DRE.data() + any`". ziqingluo-90 edited the summary o

[PATCH] D140584: [Clang] Refactor "Designators" into a unified implementation [NFC]

2023-02-03 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added a comment. I think this is fine as a short-term stepping stone to a different representation. Comment at: clang/include/clang/AST/Designator.h:88 + /// An array designator, e.g., "[42] = 0" and "[42 ... 50] = 1". + template struct

[PATCH] D79378: PR34581: Don't remove an 'if (p)' guarding a call to 'operator delete(p)' under -Oz.

2023-02-03 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In D79378#4101935 , @shiva0217 wrote: > In D79378#4101829 , @rjmccall wrote: > >> In D79378#4101613 , @shiva0217 >> wrote: >> >>> Hi, >>> >>> I hav

[PATCH] D142948: [OpenCL] Disable vector to scalar types coercion for OpenCL

2023-02-03 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Does the x86 backend lower these small vectors to the same ABI? If so, I think we could just teach Clang unconditionally that it doesn't need this coercion on x86 targets. If not, this is an ABI break; are you sure that's okay? Repository: rG LLVM Github Monorepo

[PATCH] D143288: [Fuchsia] Simplified the stage2 build setup

2023-02-03 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/D143288/new/ https://reviews.llvm.org/D143288 ___

[PATCH] D142991: [clang-tidy] Add --fix-mode and --nolint-prefix options

2023-02-03 Thread Kyle Edwards via Phabricator via cfe-commits
KyleFromKitware added a comment. I just tried this out on a somewhat larger scale - I built all of CMake with this flag enabled, and it found a number of clang-tidy violations and added `NOLINT` comments to silence them. Worked like a charm. CHANGES SINCE LAST ACTION https://reviews.llvm.org

[PATCH] D142991: [clang-tidy] Add --fix-mode and --nolint-prefix options

2023-02-03 Thread Kyle Edwards via Phabricator via cfe-commits
KyleFromKitware added a comment. Though I did find that it inserted more than one `NOLINT` comment for a templated function, probably due to multiple warnings being issued for the same violation. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D142991/new/ https://reviews.llvm.org/D14299

[PATCH] D140584: [Clang] Refactor "Designators" into a unified implementation [NFC]

2023-02-03 Thread Bill Wendling via Phabricator via cfe-commits
void added inline comments. Comment at: clang/include/clang/AST/Designator.h:88 + /// An array designator, e.g., "[42] = 0" and "[42 ... 50] = 1". + template struct ArrayDesignatorInfo { +/// Location of the first and last index expression within the designated ---

[PATCH] D139737: [-Wunsafe-buffer-usage] Initiate Fix-it generation for local variable declarations

2023-02-03 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added a comment. This revision is now accepted and ready to land. As far as I'm concerned, I think this is great for the initial implementation! Let's commit as soon as Jan confirms that his problem is addressed. Comment at: clang/lib/Analysis/U

[PATCH] D141338: [-Wunsafe-buffer-usage] Filter out conflicting fix-its

2023-02-03 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added a comment. This revision is now accepted and ready to land. Looks great! Comment at: clang/lib/Analysis/UnsafeBufferUsage.cpp:961 +// a fix-it overlaps with macros; or +// a fix-it conflicts with another one +if (overlapWithMacr

[PATCH] D139737: [-Wunsafe-buffer-usage] Initiate Fix-it generation for local variable declarations

2023-02-03 Thread Jan Korous via Phabricator via cfe-commits
jkorous added inline comments. Comment at: clang/lib/Analysis/UnsafeBufferUsage.cpp:703 + case Strategy::Kind::Span: +return FixItList{}; + case Strategy::Kind::Wontfix: jkorous wrote: > I am afraid I might have found one more problem :( > I bel

[PATCH] D139737: [-Wunsafe-buffer-usage] Initiate Fix-it generation for local variable declarations

2023-02-03 Thread Jan Korous via Phabricator via cfe-commits
jkorous added inline comments. Comment at: clang/lib/Analysis/UnsafeBufferUsage.cpp:703 + case Strategy::Kind::Span: +return FixItList{}; + case Strategy::Kind::Wontfix: jkorous wrote: > jkorous wrote: > > I am afraid I might have found one more

[PATCH] D142077: [Clang][SemaCXX][Coroutines] Fix misleading diagnostics with -Wunsequenced

2023-02-03 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno updated this revision to Diff 494740. bruno added a comment. Update checks that rely on `coroutine_traits` in `std-coroutine.h` CHANGES SINCE LAST ACTION https://reviews.llvm.org/D142077/new/ https://reviews.llvm.org/D142077 Files: clang/lib/Sema/SemaChecking.cpp clang/test/SemaCXX

[PATCH] D143287: [Clang][x86] Change x86 cast intrinsics to use __builtin_nondeterministic_value

2023-02-03 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added a comment. We have a couple bugs that show (freeze (poison)) doesn't work past SelectionDAG. Is that a concern here? The most recent https://github.com/llvm/llvm-project/issues/60429 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/

[clang] d46d44e - [Tooling/Inclusion] qualifed_name() => qualifiedName(), NFC

2023-02-03 Thread Haojian Wu via cfe-commits
Author: Haojian Wu Date: 2023-02-04T00:08:45+01:00 New Revision: d46d44e3c4a6f1f980f595386fc7ddd03c1f3fcd URL: https://github.com/llvm/llvm-project/commit/d46d44e3c4a6f1f980f595386fc7ddd03c1f3fcd DIFF: https://github.com/llvm/llvm-project/commit/d46d44e3c4a6f1f980f595386fc7ddd03c1f3fcd.diff LO

[clang] 223e99f - [clang][deps] Fix module context hash for constant strings

2023-02-03 Thread Ben Langmuir via cfe-commits
Author: Ben Langmuir Date: 2023-02-03T15:10:19-08:00 New Revision: 223e99fb698dd63b5bb9266e11c2582261e05ad9 URL: https://github.com/llvm/llvm-project/commit/223e99fb698dd63b5bb9266e11c2582261e05ad9 DIFF: https://github.com/llvm/llvm-project/commit/223e99fb698dd63b5bb9266e11c2582261e05ad9.diff

[PATCH] D143027: [clang][deps] Fix module context hash for constant strings

2023-02-03 Thread Ben Langmuir via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG223e99fb698d: [clang][deps] Fix module context hash for constant strings (authored by benlangmuir). Changed prior to commit: https://reviews.llvm.

[PATCH] D138337: Add support for kcfi-seal optimization with LTO

2023-02-03 Thread Sami Tolvanen via Phabricator via cfe-commits
samitolvanen updated this revision to Diff 494756. samitolvanen added a comment. This revision is now accepted and ready to land. Herald added subscribers: ormris, steven_wu. Don't drop type hashes from VisibleToRegularObj symbols. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D143025: [Fuchsia] Add llvm-mt and llvm-rc to clang bootstrap dependency

2023-02-03 Thread Haowei Wu via Phabricator via cfe-commits
haowei updated this revision to Diff 494755. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D143025/new/ https://reviews.llvm.org/D143025 Files: clang/CMakeLists.txt Index: clang/CMakeLists.txt =

[PATCH] D143300: [randstruct] Don't allow implicit forward decl to stop struct randomization

2023-02-03 Thread Bill Wendling via Phabricator via cfe-commits
void created this revision. void added reviewers: aaron.ballman, MaskRay, nickdesaulniers. Herald added a project: All. void requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. If a struct/enum type used in a record doesn't have a forward decl

[PATCH] D143025: [Fuchsia] Add llvm-mt and llvm-rc to clang bootstrap dependency

2023-02-03 Thread Haowei Wu via Phabricator via cfe-commits
haowei marked 2 inline comments as done. haowei added inline comments. Comment at: clang/cmake/caches/Fuchsia.cmake:170-171 runtimes + llvm-rc + llvm-mt CACHE STRING "") phosek wrote: > Could we do this in > https://github.com/llvm/llvm-project/blob/98f0

[PATCH] D142077: [Clang][SemaCXX][Coroutines] Fix misleading diagnostics with -Wunsequenced

2023-02-03 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
bruno added a comment. Only test failing is `ClangScanDeps/modules-full.cpp` on Windoes, which is unrelated to this change. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D142077/new/ https://reviews.llvm.org/D142077 ___ cfe-commits mailing li

[clang] 0b8daee - [Clang][SemaCXX][Coroutines] Fix misleading diagnostics with -Wunsequenced

2023-02-03 Thread Bruno Cardoso Lopes via cfe-commits
Author: Bruno Cardoso Lopes Date: 2023-02-03T15:37:29-08:00 New Revision: 0b8daee028a87ab8a6f8fe54d2eb2d5b5c2babd4 URL: https://github.com/llvm/llvm-project/commit/0b8daee028a87ab8a6f8fe54d2eb2d5b5c2babd4 DIFF: https://github.com/llvm/llvm-project/commit/0b8daee028a87ab8a6f8fe54d2eb2d5b5c2babd4

[PATCH] D142077: [Clang][SemaCXX][Coroutines] Fix misleading diagnostics with -Wunsequenced

2023-02-03 Thread Bruno Cardoso Lopes via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG0b8daee028a8: [Clang][SemaCXX][Coroutines] Fix misleading diagnostics with -Wunsequenced (authored by bruno). Repository: rG LLVM Github Monorepo

[PATCH] D143300: [randstruct] Don't allow implicit forward decl to stop struct randomization

2023-02-03 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. The test appears to belong to test/CodeGen instead of test/Sema ? Mixed 8-column and 2-column indentation probably should be unified. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D143300/new/ https://reviews.llvm.org/D1433

[PATCH] D143300: [randstruct] Don't allow implicit forward decl to stop struct randomization

2023-02-03 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: clang/test/Sema/init-randomized-struct-fwd-decl.c:23 + +// CHECK-LABEL: t1 +// CHECK: getelementptr inbounds %struct.foo, ptr %0, i32 0, i32 2 `// CHECK-LABEL: define {{.*}} @t1(` is less likely to cause a conflict with

[PATCH] D143300: [randstruct] Don't allow implicit forward decl to stop struct randomization

2023-02-03 Thread Bill Wendling via Phabricator via cfe-commits
void updated this revision to Diff 494772. void added a comment. Move test and improve checks. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D143300/new/ https://reviews.llvm.org/D143300 Files: clang/lib/Sema/SemaDecl.cpp clang/test/CodeGen/ini

[PATCH] D143304: [Coverage] Map regions from system headers

2023-02-03 Thread Gulfem Savrun Yeniceri via Phabricator via cfe-commits
gulfem created this revision. Herald added a project: All. gulfem requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Originally, the following commit removed mapping coverage regions for system headers: https://github.com/llvm/llvm-project/co

[PATCH] D143305: [clang] Fix -Xarch_ for -mllvm and alike

2023-02-03 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl created this revision. yaxunl added reviewers: tra, MaskRay. Herald added a subscriber: hiraditya. Herald added a project: All. yaxunl requested review of this revision. Herald added a reviewer: jdoerfert. Herald added subscribers: llvm-commits, sstefan1. Herald added a project: LLVM. Curre

[PATCH] D143306: [Driver] Default to -fno-openmp-implicit-rpath

2023-02-03 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay created this revision. MaskRay added reviewers: jdoerfert, jhuber6, JonChesterfield, tstellar. Herald added subscribers: guansong, yaxunl. Herald added a project: All. MaskRay requested review of this revision. Herald added subscribers: cfe-commits, sstefan1. Herald added a project: clang.

[PATCH] D143306: [Driver] Default to -fno-openmp-implicit-rpath

2023-02-03 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. No test probably makes this easy to back port. Eventually there needs to be a test but the original author can do it. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D143306/new/ https://reviews.llvm.org/D143306

[PATCH] D143109: [Sema] Push a LambdaScopeInfo before calling SubstDefaultArgument

2023-02-03 Thread Tom Honermann via Phabricator via cfe-commits
tahonermann added a comment. > Incidentally, it looks like that LSI copy > (https://github.com/llvm/llvm-project/blob/main/clang/lib/Sema/TreeTransform.h#L13469-L13478) > has not been needed since commit bf5fe2dbba0899bee4323f5eaa075acc43a18e2e > (see > https://github.com/llvm/llvm-project/blo

[clang] 16749d2 - [Driver] Remove deprecated -fsanitize-system-blacklist=

2023-02-03 Thread Fangrui Song via cfe-commits
Author: Fangrui Song Date: 2023-02-03T22:06:34-08:00 New Revision: 16749d28cc56b441dc252f7017fbf532ea41f8c4 URL: https://github.com/llvm/llvm-project/commit/16749d28cc56b441dc252f7017fbf532ea41f8c4 DIFF: https://github.com/llvm/llvm-project/commit/16749d28cc56b441dc252f7017fbf532ea41f8c4.diff

[PATCH] D143025: [Fuchsia] Add llvm-mt and llvm-rc to clang bootstrap dependency

2023-02-03 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 but can you update the change title and description since the original one no longer matches the content of the patch. Comment at: clang/CMakeLists.txt:599-600 + if (W

[PATCH] D143091: [clang-format] PackConstructorInitializers support PCIS_OnlyNextLine

2023-02-03 Thread Zhikai Zeng via Phabricator via cfe-commits
Backl1ght added inline comments. Comment at: clang/docs/ClangFormatStyleOptions.rst:3891 + * ``PCIS_OnlyNextLine`` (in configuration: ``OnlyNextLine``) +Put all constructor initializers on the next line if they fit. @HazardyKnusperkeks Maybe I misunder

<    1   2