[clang] [analyzer] Fix taint sink rules for exec-like functions (PR #66358)

2023-09-14 Thread via cfe-commits
https://github.com/DonatNagyE review_requested https://github.com/llvm/llvm-project/pull/66358 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Documentation] Replace recommonmark by myst-parser (PR #65664)

2023-09-14 Thread via cfe-commits
https://github.com/cor3ntin updated https://github.com/llvm/llvm-project/pull/65664: >From 144892d671cac5851096ca3521ce23ad736b48dc Mon Sep 17 00:00:00 2001 From: Corentin Jabot Date: Thu, 7 Sep 2023 21:41:33 +0200 Subject: [PATCH 1/3] [Documentation] Replace recommonmark by myst-parser This i

[clang] [Documentation] Replace recommonmark by myst-parser (PR #65664)

2023-09-14 Thread via cfe-commits
https://github.com/llvmbot labeled https://github.com/llvm/llvm-project/pull/65664 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Documentation] Replace recommonmark by myst-parser (PR #65664)

2023-09-14 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-openacc Changes This is a bit rough, but i did that while trying to figure out if there would be a good way to do pre commit checks on RsT files. Recommonmark has been deprecated, then archived last year. This was tracked by: https://github.

[clang] [Clang] Handle consteval expression in array bounds expressions (PR #66222)

2023-09-14 Thread Takuya Shimizu via cfe-commits
hazohelet wrote: > @hazohelet Does this collide or intersect with the work wrt. (un)evaluated > contexts in https://reviews.llvm.org/D155064 ? I wasn't aware of VLA cases in that patch. My patch needs modification so that use of `is_constant_evaluated` and consteval-if NOT considered tautologi

[clang] d61ba03 - [clang][Interp][NFC] Call delegate() for the RHS of a comma op

2023-09-14 Thread Timm Bäder via cfe-commits
Author: Timm Bäder Date: 2023-09-14T13:36:51+02:00 New Revision: d61ba038a9d49761ae86cce662f48bce1e47cbe9 URL: https://github.com/llvm/llvm-project/commit/d61ba038a9d49761ae86cce662f48bce1e47cbe9 DIFF: https://github.com/llvm/llvm-project/commit/d61ba038a9d49761ae86cce662f48bce1e47cbe9.diff LO

[clang-tools-extra] [MS] Follow up fix to pass aligned args to variadic x86_32 functions (PR #65692)

2023-09-14 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: Thank you for the fix, I appreciate it! https://github.com/llvm/llvm-project/pull/65692 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

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

2023-09-14 Thread Daniel Krupp via cfe-commits
dkrupp wrote: If we remove the malloc(..) as the taint sink, we would lose some true positive findings where the size of the allocated area is specified directly as a number by the attacker: ``` char *size=getenv("SIZE"); if (size){ pathbuf=(char*) malloc(atoi(size)+1); // warn: denial of se

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

2023-09-14 Thread via cfe-commits
DonatNagyE wrote: > By looking at the disappeared reports you attached, I'm convinced that the > `MsgTaintedBufferSize` diagnostics give little to no benefit in general. On > the other side, I've seen good hits for OOBV2 in the presence of taint - even > if that's rarely the case. On the theor

[clang] [libc] Add invoke / invoke_result type traits (PR #65750)

2023-09-14 Thread Guillaume Chatelet via cfe-commits
https://github.com/gchatelet updated https://github.com/llvm/llvm-project/pull/65750: >From 5023264dce58aaa46b18404a4578b7a777962758 Mon Sep 17 00:00:00 2001 From: Guillaume Chatelet Date: Fri, 8 Sep 2023 13:10:05 + Subject: [PATCH 1/4] [libc] add invoke / invoke_result type traits --- li

[clang-tools-extra] [libc] Add invoke / invoke_result type traits (PR #65750)

2023-09-14 Thread Guillaume Chatelet via cfe-commits
https://github.com/gchatelet updated https://github.com/llvm/llvm-project/pull/65750: >From 5023264dce58aaa46b18404a4578b7a777962758 Mon Sep 17 00:00:00 2001 From: Guillaume Chatelet Date: Fri, 8 Sep 2023 13:10:05 + Subject: [PATCH 1/4] [libc] add invoke / invoke_result type traits --- li

[PATCH] D151834: Include math-errno with fast-math

2023-09-14 Thread Zahira Ammarguellat via Phabricator via cfe-commits
zahiraam added a comment. In D151834#4645866 , @uabelho wrote: > What's the way forward here? Revert if it's unclear what to do? We have a fix for it. By eod a PR will be created. Thanks. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[clang] [libc] Add invoke / invoke_result type traits (PR #65750)

2023-09-14 Thread Guillaume Chatelet via cfe-commits
@@ -0,0 +1,26 @@ +//===-- invoke_result type_traits ---*- 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: Apa

[clang] [libc] Add invoke / invoke_result type traits (PR #65750)

2023-09-14 Thread Guillaume Chatelet via cfe-commits
https://github.com/gchatelet review_requested https://github.com/llvm/llvm-project/pull/65750 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [libc] Add invoke / invoke_result type traits (PR #65750)

2023-09-14 Thread Guillaume Chatelet via cfe-commits
@@ -0,0 +1,26 @@ +//===-- invoke_result type_traits ---*- 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: Apa

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

2023-09-14 Thread Balazs Benics via cfe-commits
steakhal wrote: > So for me either solution would work: > a) remove strlen() as a propagator and note it in the checker doc > b) remove malloc() as a sink and note it in the checker doc > c) don't do anything and live with the false positives TBH I would prefer (b). I see removing the whole `Msg

[clang] [Clang] Handle consteval expression in array bounds expressions (PR #66222)

2023-09-14 Thread via cfe-commits
cor3ntin wrote: > Is it alright to set `InConditionallyConstantEvaluateContext` true only when > the outer evaluation context `isAlwaysConstantEvaluatedContext()` so that we > can say the array bound expr is always constant-evaluated if it happens in > always-constant-evaluated context? Where

[clang] [NFC][CodeGen] Change CodeGenOpt::Level/CodeGenFileType into enum classes (PR #66295)

2023-09-14 Thread Louis Dionne via cfe-commits
ldionne wrote: There shouldn't be any changes under libcxxabi. Those changes are not necessary. https://github.com/llvm/llvm-project/pull/66295 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-

[clang] [Documentation] Replace recommonmark by myst-parser (PR #65664)

2023-09-14 Thread via cfe-commits
https://github.com/cor3ntin updated https://github.com/llvm/llvm-project/pull/65664: >From 144892d671cac5851096ca3521ce23ad736b48dc Mon Sep 17 00:00:00 2001 From: Corentin Jabot Date: Thu, 7 Sep 2023 21:41:33 +0200 Subject: [PATCH 1/4] [Documentation] Replace recommonmark by myst-parser This i

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

2023-09-14 Thread via cfe-commits
DonatNagyE wrote: Putting an upper bound on `strlen` is not just for `malloc`, it's also needed for ArrayBoundV2. As a very clear example, this [function `strfuzz_ends_with` from twin](https://codechecker-demo.eastus.cloudapp.azure.com/Default/report-detail?run=twin_v0.8.1_ednikru_taint_nostrl

[PATCH] D151834: Include math-errno with fast-math

2023-09-14 Thread Mikael Holmén via Phabricator via cfe-commits
uabelho added a comment. In D151834#4645910 , @zahiraam wrote: > In D151834#4645866 , @uabelho wrote: > >> What's the way forward here? Revert if it's unclear what to do? > > We have a fix for it. By eod a PR will

[clang] [clang][dataflow] Ignore assignment where base class's operator is used (PR #66364)

2023-09-14 Thread Kinuko Yasuda via cfe-commits
https://github.com/kinu created https://github.com/llvm/llvm-project/pull/66364: In C++ it seems it is legit to use base class's operator (e.g. `using Base::operator=`) to perform copy if the base class is the common ancestor of the source and destination object. In such a case we shouldn't try

[clang] [clang][dataflow] Ignore assignment where base class's operator is used (PR #66364)

2023-09-14 Thread via cfe-commits
https://github.com/llvmbot labeled https://github.com/llvm/llvm-project/pull/66364 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][dataflow] Ignore assignment where base class's operator is used (PR #66364)

2023-09-14 Thread via cfe-commits
https://github.com/llvmbot labeled https://github.com/llvm/llvm-project/pull/66364 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][dataflow] Ignore assignment where base class's operator is used (PR #66364)

2023-09-14 Thread via cfe-commits
https://github.com/llvmbot labeled https://github.com/llvm/llvm-project/pull/66364 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][dataflow] Ignore assignment where base class's operator is used (PR #66364)

2023-09-14 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Changes In C++ it seems it is legit to use base class's operator (e.g. `using Base::operator=`) to perform copy if the base class is the common ancestor of the source and destination object. In such a case we shouldn't try to access fi

[clang] [clang][dataflow] Ignore assignment where base class's operator is used (PR #66364)

2023-09-14 Thread Kinuko Yasuda via cfe-commits
kinu wrote: @martinboehme @sam-mccall @ymand appreciated if any of you (or other owners) can review https://github.com/llvm/llvm-project/pull/66364 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo

[PATCH] D158413: [Lex] Introduce Preprocessor::LexAll()

2023-09-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/lib/Lex/Preprocessor.cpp:998 +std::vector Preprocessor::LexAll() { + std::vector toks; v.g.vassilev wrote: > Shouldn't we take the results as a `LexAll(std::vector &result)`? > > Perhaps we should rename

[clang] [clang-cl] Fix for __FUNCTION__ in c++. (PR #66120)

2023-09-14 Thread Zahira Ammarguellat via cfe-commits
https://github.com/zahiraam updated https://github.com/llvm/llvm-project/pull/66120: >From 3fcfa303bd211f9a3382657012968cd3f7269db8 Mon Sep 17 00:00:00 2001 From: Ammarguellat Date: Tue, 12 Sep 2023 11:25:19 -0700 Subject: [PATCH 1/2] [clang-cl] Fix for __FUNCTION__ in c++. --- clang/lib/AST/

[clang-tools-extra] [clang-cl] Fix for __FUNCTION__ in c++. (PR #66120)

2023-09-14 Thread Zahira Ammarguellat via cfe-commits
https://github.com/zahiraam updated https://github.com/llvm/llvm-project/pull/66120: >From 3fcfa303bd211f9a3382657012968cd3f7269db8 Mon Sep 17 00:00:00 2001 From: Ammarguellat Date: Tue, 12 Sep 2023 11:25:19 -0700 Subject: [PATCH 1/2] [clang-cl] Fix for __FUNCTION__ in c++. --- clang/lib/AST/

[clang] [clang-format] More on unbreakable strings in TypeScript (PR #66321)

2023-09-14 Thread via cfe-commits
https://github.com/sstwcw updated https://github.com/llvm/llvm-project/pull/66321: >From cb479e7d7d6e70748ebeef3b930d7911dc9e4276 Mon Sep 17 00:00:00 2001 From: sstwcw Date: Thu, 14 Sep 2023 03:26:10 + Subject: [PATCH] [clang-format] More on unbreakable strings in TypeScript (#66321) Now.

[clang] cb479e7 - [clang-format] More on unbreakable strings in TypeScript (#66321)

2023-09-14 Thread via cfe-commits
Author: sstwcw Date: 2023-09-14T12:41:21Z New Revision: cb479e7d7d6e70748ebeef3b930d7911dc9e4276 URL: https://github.com/llvm/llvm-project/commit/cb479e7d7d6e70748ebeef3b930d7911dc9e4276 DIFF: https://github.com/llvm/llvm-project/commit/cb479e7d7d6e70748ebeef3b930d7911dc9e4276.diff LOG: [clang

[clang] [clang-format] More on unbreakable strings in TypeScript (PR #66321)

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

[clang] [libc] Add invoke / invoke_result type traits (PR #65750)

2023-09-14 Thread Guillaume Chatelet via cfe-commits
@@ -0,0 +1,59 @@ +//===-- invoke type_traits --*- 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: Apa

[clang-tools-extra] [libc] Add invoke / invoke_result type traits (PR #65750)

2023-09-14 Thread Guillaume Chatelet via cfe-commits
@@ -0,0 +1,59 @@ +//===-- invoke type_traits --*- 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: Apa

[clang] [libc] Add invoke / invoke_result type traits (PR #65750)

2023-09-14 Thread Guillaume Chatelet via cfe-commits
https://github.com/gchatelet edited https://github.com/llvm/llvm-project/pull/65750 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [libc] Add invoke / invoke_result type traits (PR #65750)

2023-09-14 Thread Guillaume Chatelet via cfe-commits
https://github.com/gchatelet edited https://github.com/llvm/llvm-project/pull/65750 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

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

2023-09-14 Thread Kinuko Yasuda via cfe-commits
https://github.com/kinu created https://github.com/llvm/llvm-project/pull/66368: So that the values that are accessed via such accessors can be analyzed as a limited version of context-sensitive analysis. We can potentially do this only when some option is set, but doing additional modeling lik

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

2023-09-14 Thread via cfe-commits
https://github.com/llvmbot labeled 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] [clang][dataflow] Model the fields that are accessed via inline accessors (PR #66368)

2023-09-14 Thread via cfe-commits
https://github.com/llvmbot labeled 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] [clang][dataflow] Model the fields that are accessed via inline accessors (PR #66368)

2023-09-14 Thread via cfe-commits
https://github.com/llvmbot labeled 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] [clang][dataflow] Model the fields that are accessed via inline accessors (PR #66368)

2023-09-14 Thread Kinuko Yasuda via cfe-commits
kinu wrote: /cc @martinboehme @ymand 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] [clang][dataflow] Model the fields that are accessed via inline accessors (PR #66368)

2023-09-14 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Changes So that the values that are accessed via such accessors can be analyzed as a limited version of context-sensitive analysis. We can potentially do this only when some option is set, but doing additional modeling like this won't b

[clang-tools-extra] [libc] Add invoke / invoke_result type traits (PR #65750)

2023-09-14 Thread Clement Courbet via cfe-commits
@@ -145,6 +145,110 @@ TEST(LlvmLibcTypeTraitsTest, integral_constant) { EXPECT_EQ((integral_constant::value), 4); } +namespace invoke_detail { + +enum State { INIT = 0, A_APPLY_CALLED, B_APPLY_CALLED }; + +struct A { + State state = INIT; + virtual ~A() {} + virtual void

[clang] [libc] Add invoke / invoke_result type traits (PR #65750)

2023-09-14 Thread Clement Courbet via cfe-commits
@@ -145,6 +145,110 @@ TEST(LlvmLibcTypeTraitsTest, integral_constant) { EXPECT_EQ((integral_constant::value), 4); } +namespace invoke_detail { + +enum State { INIT = 0, A_APPLY_CALLED, B_APPLY_CALLED }; + +struct A { + State state = INIT; + virtual ~A() {} + virtual void

[clang-tools-extra] [libc] Add invoke / invoke_result type traits (PR #65750)

2023-09-14 Thread Clement Courbet via cfe-commits
@@ -145,6 +145,110 @@ TEST(LlvmLibcTypeTraitsTest, integral_constant) { EXPECT_EQ((integral_constant::value), 4); } +namespace invoke_detail { + +enum State { INIT = 0, A_APPLY_CALLED, B_APPLY_CALLED }; + +struct A { + State state = INIT; + virtual ~A() {} + virtual void

[clang] [libc] Add invoke / invoke_result type traits (PR #65750)

2023-09-14 Thread Clement Courbet via cfe-commits
@@ -145,6 +145,110 @@ TEST(LlvmLibcTypeTraitsTest, integral_constant) { EXPECT_EQ((integral_constant::value), 4); } +namespace invoke_detail { + +enum State { INIT = 0, A_APPLY_CALLED, B_APPLY_CALLED }; + +struct A { + State state = INIT; + virtual ~A() {} + virtual void

[clang] [libc] Add invoke / invoke_result type traits (PR #65750)

2023-09-14 Thread Clement Courbet via cfe-commits
@@ -145,6 +145,110 @@ TEST(LlvmLibcTypeTraitsTest, integral_constant) { EXPECT_EQ((integral_constant::value), 4); } +namespace invoke_detail { + +enum State { INIT = 0, A_APPLY_CALLED, B_APPLY_CALLED }; + +struct A { + State state = INIT; + virtual ~A() {} + virtual void

[clang-tools-extra] [libc] Add invoke / invoke_result type traits (PR #65750)

2023-09-14 Thread Clement Courbet via cfe-commits
@@ -145,6 +145,110 @@ TEST(LlvmLibcTypeTraitsTest, integral_constant) { EXPECT_EQ((integral_constant::value), 4); } +namespace invoke_detail { + +enum State { INIT = 0, A_APPLY_CALLED, B_APPLY_CALLED }; + +struct A { + State state = INIT; + virtual ~A() {} + virtual void

[clang] Update GoogleTest to v1.14.0 (PR #65823)

2023-09-14 Thread via cfe-commits
mikaelholmen wrote: Ok, seems like the only problem is the MemProf unit test compiler-rt/lib/memprof/tests/ So if I manually disable that I don't see any other failures with this patch. https://github.com/llvm/llvm-project/pull/65823 ___ cfe-commits

[libunwind] [runtimes] Remove explicit -isysroot from the testing configurations on macOS (PR #66265)

2023-09-14 Thread Louis Dionne via cfe-commits
@@ -2,6 +2,24 @@ @SERIALIZED_LIT_PARAMS@ +# Workaround for https://gitlab.kitware.com/cmake/cmake/-/issues/19180. +# +# On Apple platforms, CMake resolves the compiler to the final binary using +# `$(xcrun --find `). Unfortunately, running this compiler as-is +# doesn't work

[clang] [dataflow] Add global condition to DataflowAnalysisContext (PR #65949)

2023-09-14 Thread Sam McCall via cfe-commits
@@ -108,6 +108,16 @@ class DataflowAnalysisContext { /// A null `PointeeType` can be used for the pointee of `std::nullptr_t`. PointerValue &getOrCreateNullPointerValue(QualType PointeeType); + /// Adds `Constraint` to current and future flow conditions in this context. +

[clang] [dataflow] Add global condition to DataflowAnalysisContext (PR #65949)

2023-09-14 Thread Sam McCall via cfe-commits
https://github.com/sam-mccall updated https://github.com/llvm/llvm-project/pull/65949: >From 1d765a3b22cd81d6739a20f2b2f7b68935773f2a Mon Sep 17 00:00:00 2001 From: Sam McCall Date: Mon, 11 Sep 2023 13:21:11 +0200 Subject: [PATCH 1/4] [dataflow] Add global condition to DataflowAnalysisContext

[PATCH] D158415: [Lex] Handle repl_input_end in Preprocessor::LexAll()

2023-09-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. The idea LGTM when D158413 lands, even if that lands with a slightly different design. (IOW, once D158413 lands, feel free to push this change without furth

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

2023-09-14 Thread Balazs Benics via cfe-commits
steakhal wrote: > Putting an upper bound on `strlen` is not just for `malloc`, it's also needed > for ArrayBoundV2. > > As a very clear example, this [function `strfuzz_ends_with` from > twin](https://codechecker-demo.eastus.cloudapp.azure.com/Default/report-detail?run=twin_v0.8.1_ednikru_tain

[clang-tools-extra] [include-cleaner] Handle symbols from system headers. (PR #66089)

2023-09-14 Thread Haojian Wu via cfe-commits
https://github.com/hokein updated https://github.com/llvm/llvm-project/pull/66089: >From 5aabc90355738b808f7cdce5a4df21e00adc1324 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Tue, 12 Sep 2023 15:50:48 +0200 Subject: [PATCH] [include-cleaner] Handle symbols from system headers. This is the i

[clang] [clang] Fix wrong warning about missing init for flexible array members (PR #66341)

2023-09-14 Thread via cfe-commits
https://github.com/cor3ntin approved this pull request. LGTM ! (double checking: this does not need a release note because it fixes something that was changed post 17 branch. Correct?) https://github.com/llvm/llvm-project/pull/66341 ___ cfe-commits ma

[clang] [clang-format] Disable string breaking in JS for now (PR #66372)

2023-09-14 Thread via cfe-commits
https://github.com/sstwcw created https://github.com/llvm/llvm-project/pull/66372: See the discussion [here](https://github.com/llvm/llvm-project/pull/66168#issuecomment-1719038797). The functionality is not mature enough. >From a736d84df61e3e7c1a4c8b22c7cd1e7524499d64 Mon Sep 17 00:00:00 2001

[clang] Extension: allow recursive macros (PR #65851)

2023-09-14 Thread via cfe-commits
https://github.com/cor3ntin requested changes to this pull request. A RFC is in progress here https://discourse.llvm.org/t/rfc-allow-recursive-macros-as-extension/73401 https://github.com/llvm/llvm-project/pull/65851 ___ cfe-commits mailing list cfe-co

[clang] [clang-format] Disable string breaking in JS for now (PR #66372)

2023-09-14 Thread via cfe-commits
https://github.com/llvmbot labeled https://github.com/llvm/llvm-project/pull/66372 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Disable string breaking in JS for now (PR #66372)

2023-09-14 Thread via cfe-commits
https://github.com/llvmbot labeled https://github.com/llvm/llvm-project/pull/66372 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Disable string breaking in JS for now (PR #66372)

2023-09-14 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-format Changes See the discussion [here](https://github.com/llvm/llvm-project/pull/66168#issuecomment-1719038797). The functionality is not mature enough. -- Full diff: https://github.com/llvm/llvm-project/pull/66372.diff 4 Files Affect

[clang] [clang-format] Stop breaking unbreakable strings in JS (PR #66168)

2023-09-14 Thread via cfe-commits
sstwcw wrote: > Another thing is that we need to get this fixed really soon. Another (safer > and actually preferred) alternative is to revert the change and address > problematic use cases before recommitting it, but I'm also fine with > forward-fixing this as long as fixes don't require majo

[clang] [libc] Add invoke / invoke_result type traits (PR #65750)

2023-09-14 Thread Guillaume Chatelet via cfe-commits
https://github.com/gchatelet resolved https://github.com/llvm/llvm-project/pull/65750 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D148381: [Clang] Implement the 'counted_by' attribute

2023-09-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/include/clang/AST/Decl.h:4272-4275 +FieldDecl *FD = nullptr; +for (FieldDecl *Field : fields()) + FD = Field; +return FD; void wrote: > aaron.ballman wrote: > > Could this be implemented as:

[clang] [libc] Add invoke / invoke_result type traits (PR #65750)

2023-09-14 Thread Guillaume Chatelet via cfe-commits
https://github.com/gchatelet resolved https://github.com/llvm/llvm-project/pull/65750 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver] Link Flang runtime on Solaris (PR #65644)

2023-09-14 Thread Rainer Orth via cfe-commits
@@ -4,6 +4,7 @@ ! RUN: %flang -### -target ppc64le-linux-gnu %S/Inputs/hello.f90 2>&1 | FileCheck %s --check-prefixes=CHECK,GNU ! RUN: %flang -### -target aarch64-apple-darwin %S/Inputs/hello.f90 2>&1 | FileCheck %s --check-prefixes=CHECK,DARWIN +! RUN: %flang -### -target s

[clang] [NFC][CodeGen] Change CodeGenOpt::Level/CodeGenFileType into enum classes (PR #66295)

2023-09-14 Thread Paul T Robinson via cfe-commits
@@ -661,27 +661,27 @@ static bool FixupInvocation(CompilerInvocation &Invocation, static unsigned getOptimizationLevel(ArgList &Args, InputKind IK, DiagnosticsEngine &Diags) { - unsigned DefaultOpt = llvm::CodeGenOpt::None; + unsigned De

[PATCH] D156794: [clang][Interp] Lazily visit unknown global declarations

2023-09-14 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin accepted this revision. cor3ntin added a comment. This revision is now accepted and ready to land. LGTM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156794/new/ https://reviews.llvm.org/D156794 ___ cfe-commits mailing list cfe-commi

[PATCH] D134654: [clang] Detect header loops

2023-09-14 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added a comment. @aaron.ballman @urnathan What is the status of this PR? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134654/new/ https://reviews.llvm.org/D134654 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists

[PATCH] D154093: [clang-format] Break long string literals in C#, etc.

2023-09-14 Thread Evgeny Eltsin via Phabricator via cfe-commits
eaeltsin added a comment. This still misses contexts when string literal is required, for example https://github.com/search?q=repo%3Agoogle%2Fclosure-compiler%20%22%20must%20be%20a%20string%20literal%22&type=code I wonder, if splitting the literal with `+` is a good option at all. Repository:

[clang] [clang-format] Stop breaking unbreakable strings in JS (PR #66168)

2023-09-14 Thread via cfe-commits
eaeltsin wrote: Here are string literal context from closure - This still misses contexts when string literal is required, for example https://github.com/search?q=repo%3Agoogle%2Fclosure-compiler%20%22%20must%20be%20a%20string%20literal%22&type=code I wonder, if splitting the literal with `+`

[libunwind] [runtimes] Remove explicit -isysroot from the testing configurations on macOS (PR #66265)

2023-09-14 Thread Louis Dionne via cfe-commits
https://github.com/ldionne updated https://github.com/llvm/llvm-project/pull/66265: >From c325c0ba95e6d6abe7ff1a371853051bab0510af Mon Sep 17 00:00:00 2001 From: Louis Dionne Date: Wed, 13 Sep 2023 13:30:30 -0400 Subject: [PATCH] [runtimes] Remove explicit -isysroot from the testing configurat

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

2023-09-14 Thread Takuya Shimizu via cfe-commits
@@ -961,10 +961,16 @@ def FormatNonStandard : DiagGroup<"format-non-iso">; def FormatY2K : DiagGroup<"format-y2k">; def FormatPedantic : DiagGroup<"format-pedantic">; def FormatTypeConfusion : DiagGroup<"format-type-confusion">; + +def FormatOverflowNonKprintf: DiagGroup<"forma

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

2023-09-14 Thread Takuya Shimizu via cfe-commits
@@ -1350,10 +1360,17 @@ void Sema::checkFortifiedBuiltinMemoryFunction(FunctionDecl *FD, llvm::APSInt::getUnsigned(H.getSizeLowerBound()) .extOrTrunc(SizeTypeWidth); if (FormatSize > *SourceSize && *SourceSize != 0) { - DiagID = dia

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

2023-09-14 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/3] [clang][Diagnostics] Separate Wformat-overflow and Wform

[PATCH] D155475: [Clang][Sema] Add -Wctad-selects-copy to diagnose copy deduction candidate

2023-09-14 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added subscribers: philnik, ldionne, cor3ntin. cor3ntin added a comment. I have a couple questions but overall I think this is a great warning to add. Sorry it took us a while to get to your PR Comment at: clang/include/clang/Basic/DiagnosticGroups.td:1384 +def CTADSel

[PATCH] D155572: [clang][Interp] Start implementing binary operators for complex types

2023-09-14 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added a comment. In D155572#4542484 , @aaron.ballman wrote: > In D155572#4541403 , @tbaeder wrote: > >> In D155572#4539457 , >> @aaron.ballman wrote: >> >>> Is t

[clang] [NFC][CodeGen] Change CodeGenOpt::Level/CodeGenFileType into enum classes (PR #66295)

2023-09-14 Thread Andrzej Warzyński via cfe-commits
@@ -661,27 +661,27 @@ static bool FixupInvocation(CompilerInvocation &Invocation, static unsigned getOptimizationLevel(ArgList &Args, InputKind IK, DiagnosticsEngine &Diags) { - unsigned DefaultOpt = llvm::CodeGenOpt::None; + unsigned De

[clang] [NFC][CodeGen] Change CodeGenOpt::Level/CodeGenFileType into enum classes (PR #66295)

2023-09-14 Thread Andrzej Warzyński via cfe-commits
https://github.com/banach-space approved this pull request. Flang driver changes LGTM, thanks! https://github.com/llvm/llvm-project/pull/66295 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-c

[clang] [Driver] Link Flang runtime on Solaris (PR #65644)

2023-09-14 Thread Andrzej Warzyński via cfe-commits
@@ -4,6 +4,7 @@ ! RUN: %flang -### -target ppc64le-linux-gnu %S/Inputs/hello.f90 2>&1 | FileCheck %s --check-prefixes=CHECK,GNU ! RUN: %flang -### -target aarch64-apple-darwin %S/Inputs/hello.f90 2>&1 | FileCheck %s --check-prefixes=CHECK,DARWIN +! RUN: %flang -### -target s

[clang] [clang] Fix wrong warning about missing init for flexible array members (PR #66341)

2023-09-14 Thread Mariya Podchishchaeva via cfe-commits
Fznamznon wrote: > (double checking: this does not need a release note because it fixes > something that was changed post 17 branch. Correct?) Exactly. There is a release note for guilty change. https://github.com/llvm/llvm-project/pull/66341 ___ cfe

[PATCH] D157547: Arm64EC entry/exit thunks, consolidated.

2023-09-14 Thread Billy Laws via Phabricator via cfe-commits
bylaws added inline comments. Comment at: llvm/lib/Target/AArch64/AArch64MCInstLower.cpp:59 + +StringRef Name = Printer.getSymbol(GV)->getName(); +// Don't mangle ARM64EC runtime functions. bylaws wrote: > This mangling logic is also necessary for dllimpo

[PATCH] D155572: [clang][Interp] Start implementing binary operators for complex types

2023-09-14 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D155572#4645995 , @tbaeder wrote: > In D155572#4542484 , @aaron.ballman > wrote: > >> In D155572#4541403 , @tbaeder >> wrote: >> >>> In

[PATCH] D74094: Reapply: [IRGen] Emit lifetime intrinsics around temporary aggregate argument allocas

2023-09-14 Thread Duncan P. N. Exon Smith via Phabricator via cfe-commits
dexonsmith added a comment. In D74094#4645562 , @nickdesaulniers wrote: > I don't yet fully comprehend yet what's going wrong, and probably need to > familiarize myself with the language rules around `auto`'s type deduction. For reduction purposes, it m

[clang] [LSAN][NFC] Add a new line to a log (PR #66305)

2023-09-14 Thread via cfe-commits
Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=, Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=,Jonas Devlieghere ,Douglas Yung ,daisy202309 <144047963+daisy202...@users.noreply.github.com>,Jonas Devlieghere ,Mehdi Amini ,Siva Chandra ,Jonas Devlieghere , Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=

[clang] [LSAN][NFC] Add a new line to a log (PR #66305)

2023-09-14 Thread via cfe-commits
Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=, Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=,Jonas Devlieghere ,Douglas Yung ,daisy202309 <144047963+daisy202...@users.noreply.github.com>,Jonas Devlieghere ,Mehdi Amini ,Siva Chandra ,Jonas Devlieghere , Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=

[clang] [LSAN][NFC] Add a new line to a log (PR #66305)

2023-09-14 Thread via cfe-commits
Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=, Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=,Jonas Devlieghere ,Douglas Yung ,daisy202309 <144047963+daisy202...@users.noreply.github.com>,Jonas Devlieghere ,Mehdi Amini ,Siva Chandra ,Jonas Devlieghere , Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=

[clang] [LSAN][NFC] Add a new line to a log (PR #66305)

2023-09-14 Thread via cfe-commits
Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=, Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=,Jonas Devlieghere ,Douglas Yung ,daisy202309 <144047963+daisy202...@users.noreply.github.com>,Jonas Devlieghere ,Mehdi Amini ,Siva Chandra ,Jonas Devlieghere , Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=

[clang] [LSAN][NFC] Add a new line to a log (PR #66305)

2023-09-14 Thread via cfe-commits
Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=, Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=,Jonas Devlieghere ,Douglas Yung ,daisy202309 <144047963+daisy202...@users.noreply.github.com>,Jonas Devlieghere ,Mehdi Amini ,Siva Chandra ,Jonas Devlieghere , Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=

[clang] [LSAN][NFC] Add a new line to a log (PR #66305)

2023-09-14 Thread via cfe-commits
Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=, Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=,Jonas Devlieghere ,Douglas Yung ,daisy202309 <144047963+daisy202...@users.noreply.github.com>,Jonas Devlieghere ,Mehdi Amini ,Siva Chandra ,Jonas Devlieghere , Valentin Clement =?utf-8?b?KOODkOODrOODsw=?=

[clang] [LSAN][NFC] Add a new line to a log (PR #66305)

2023-09-14 Thread Matt Arsenault via cfe-commits
Valentin Clement =?utf-8?b?KOODkOODrOODsw==?=, Valentin Clement =?utf-8?b?KOODkOODrOODsw==?=,Jonas Devlieghere ,Douglas Yung ,daisy202309 <144047963+daisy202...@users.noreply.github.com>,Jonas Devlieghere ,Mehdi Amini ,Siva Chandra ,Jonas Devlieghere , Valentin Clement =?utf-8?b?KOODkOODrOODsw=

[clang] 1db6b12 - [C23] Remove N2713 from the list

2023-09-14 Thread Aaron Ballman via cfe-commits
Author: Aaron Ballman Date: 2023-09-14T12:08:51-04:00 New Revision: 1db6b127a1efddd3130402533b01a26c9864c462 URL: https://github.com/llvm/llvm-project/commit/1db6b127a1efddd3130402533b01a26c9864c462 DIFF: https://github.com/llvm/llvm-project/commit/1db6b127a1efddd3130402533b01a26c9864c462.diff

[PATCH] D158413: [Lex] Introduce Preprocessor::LexTokensUntilEOF()

2023-09-14 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld updated this revision to Diff 556791. Hahnfeld retitled this revision from "[Lex] Introduce Preprocessor::LexAll()" to "[Lex] Introduce Preprocessor::LexTokensUntilEOF()". Hahnfeld edited the summary of this revision. Hahnfeld added a comment. Rename to `Preprocessor::LexTokensUntilEOF()

[clang] [RISCV] Install sifive_vector.h to riscv-resource-headers (PR #66330)

2023-09-14 Thread Brandon Wu via cfe-commits
https://github.com/4vtomat updated https://github.com/llvm/llvm-project/pull/66330: >From 8eb805beb037ba824fdf01dd8528b797a80de7ad Mon Sep 17 00:00:00 2001 From: 4vtomat Date: Wed, 13 Sep 2023 22:59:30 -0700 Subject: [PATCH 1/2] [RISCV] Install sifive_vector.h to riscv-resource-headers --- cl

[clang] [RISCV] Install sifive_vector.h to riscv-resource-headers (PR #66330)

2023-09-14 Thread via cfe-commits
https://github.com/llvmbot labeled https://github.com/llvm/llvm-project/pull/66330 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D158413: [Lex] Introduce Preprocessor::LexTokensUntilEOF()

2023-09-14 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld marked 2 inline comments as done. Hahnfeld added inline comments. Comment at: clang/lib/Lex/Preprocessor.cpp:998 +std::vector Preprocessor::LexAll() { + std::vector toks; aaron.ballman wrote: > v.g.vassilev wrote: > > Shouldn't we take the results as

[clang] [clang-format] Fix a bug in ContinuationIndenter (PR #66354)

2023-09-14 Thread via cfe-commits
https://github.com/mydeveloperday approved this pull request. https://github.com/llvm/llvm-project/pull/66354 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][CodeGen] Change CodeGenOpt::Level/CodeGenFileType into enum classes (PR #66295)

2023-09-14 Thread Arthur Eubanks via cfe-commits
@@ -661,27 +661,27 @@ static bool FixupInvocation(CompilerInvocation &Invocation, static unsigned getOptimizationLevel(ArgList &Args, InputKind IK, DiagnosticsEngine &Diags) { - unsigned DefaultOpt = llvm::CodeGenOpt::None; + unsigned De

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

2023-09-14 Thread Arthur Eubanks via cfe-commits
aeubanks wrote: can you instead expose the options you want as proper clang flags? https://github.com/llvm/llvm-project/pull/66347 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

<    1   2   3   4   >