[clang] [clang-tools-extra] [flang] [lldb] [llvm] [openmp] [pstl] Finally formalise our defacto line-ending policy (PR #86318)

2024-10-18 Thread via cfe-commits
ldrumm wrote: On Fri Oct 18, 2024 at 7:39 PM BST, Aaron Ballman wrote: > @ldrumm -- can you revert these changes ASAP? They're causing > significant problems in practice, so best to get us back to green rather > than fix forward. Thanks! Reverted. https://github.com/llvm/llvm-project/pull/863

[clang] [Clang] Provide default value for -fprofile-sample-use, -fprofile-auto (PR #112750)

2024-10-18 Thread Mikołaj Piróg via cfe-commits
https://github.com/mikolaj-pirog updated https://github.com/llvm/llvm-project/pull/112750 From 06472c56a4a916dc2fd7b29a0c137597bbda0504 Mon Sep 17 00:00:00 2001 From: "Pirog, Mikolaj Maciej" Date: Thu, 17 Oct 2024 10:17:09 -0700 Subject: [PATCH 1/2] Provide default value for -fprofile-sample-us

[clang] [analyzer] Improve solver (PR #112583)

2024-10-18 Thread Arseniy Zaostrovnykh via cfe-commits
@@ -50,31 +50,10 @@ void test2() { b = d; a -= d; - if (a != 0) -return; - - clang_analyzer_warnIfReached(); // expected-warning{{REACHABLE}} + clang_analyzer_warnIfReached(); // expected-warning {{REACHABLE}} - /* The BASELINE passes these checks ('wrning' is us

[clang] [analyzer][Solver][NFC] Cleanup const-correctness inside range-based solver (PR #112891)

2024-10-18 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat approved this pull request. LGTM, straightforward NFC improvement. Thanks for cleaning this up! (Currently the diff is a bit confusing, because this cleanup builds on the not-yet-merged commit https://github.com/llvm/llvm-project/pull/112887, but that's just GUI aw

[clang] [Clang] Fix an assertion in expression recovery (PR #112888)

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

[clang] af90e7c - [Clang] Fix an assertion in expression recovery (#112888)

2024-10-18 Thread via cfe-commits
Author: cor3ntin Date: 2024-10-18T15:42:54+02:00 New Revision: af90e7c5161de9a36af768dd5c9d73464e0eed64 URL: https://github.com/llvm/llvm-project/commit/af90e7c5161de9a36af768dd5c9d73464e0eed64 DIFF: https://github.com/llvm/llvm-project/commit/af90e7c5161de9a36af768dd5c9d73464e0eed64.diff LOG:

[clang] [Clang] Fix handling of immediate escalation for inherited constructors (PR #112860)

2024-10-18 Thread via cfe-commits
https://github.com/cor3ntin updated https://github.com/llvm/llvm-project/pull/112860 >From 57e5a150295cd828f852e198e2e9e4e8d5ed66ce Mon Sep 17 00:00:00 2001 From: Corentin Jabot Date: Fri, 18 Oct 2024 10:59:35 +0200 Subject: [PATCH 1/2] [Clang] Fix handling of immediate escalation for inherite

[clang] [NFC] clang add DiagnosticsTestHelper decl (PR #112820)

2024-10-18 Thread Erich Keane via cfe-commits
@@ -1024,6 +1024,9 @@ class DiagnosticsEngine : public RefCountedBase { /// @} }; +/// Declare the friend function for testing to avoid GCC warning. erichkeane wrote: couldn't we just put this at the top of the unittest file where this is defined/used? J

[clang] [Clang] prevent setting default lexical access specifier for missing primary declarations (PR #112424)

2024-10-18 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/112424 >From a22c6bae4f42f42e67f8e0c2b1f914e50d140099 Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Tue, 15 Oct 2024 22:43:24 +0300 Subject: [PATCH 1/2] [Clang] prevent setting default lexical access specifier f

[clang] [Clang] fix range calculation for conditionals with throw expressions (PR #112081)

2024-10-18 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/112081 >From 67c41612085489a2a17eec49f98dbfa0e5bb97cf Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Sat, 12 Oct 2024 08:27:51 +0300 Subject: [PATCH] [Clang] fix range calculation for conditionals with throw expr

[clang] [Clang] prevent assertion failure in value-dependent initializer expressions (PR #112612)

2024-10-18 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/112612 >From 6112d12f757cce0214132e9201dc2a434e40e0c7 Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Wed, 16 Oct 2024 23:42:05 +0300 Subject: [PATCH 1/2] [Clang] prevent assertion failure in value-dependent initi

[clang] [X86][RFC] Refactor the SSE intrinsics constexpr tests to simplify future expansion (PR #112578)

2024-10-18 Thread Simon Pilgrim via cfe-commits
@@ -6,13 +6,23 @@ #include +#if defined(__cplusplus) && (__cplusplus >= 201103L) +constexpr bool match_m128(__m128 v, float x, float y, float z, float w) { + return v[0] == x && v[1] == y && v[2] == z && v[3] == w; RKSimon wrote: I'd prefer to keep the mat

[clang] [X86][RFC] Refactor the SSE intrinsics constexpr tests to simplify future expansion (PR #112578)

2024-10-18 Thread Simon Pilgrim via cfe-commits
@@ -6,13 +6,23 @@ #include +#if defined(__cplusplus) && (__cplusplus >= 201103L) +constexpr bool match_m128(__m128 v, float x, float y, float z, float w) { + return v[0] == x && v[1] == y && v[2] == z && v[3] == w; +} +#define TEST_CONSTEXPR(...) static_assert(__VA_ARGS__)

[clang] [NFC] Fix c++ style comment in c file (PR #112814)

2024-10-18 Thread Jinsong Ji via cfe-commits
@@ -8,7 +8,6 @@ #include "clang-c/Documentation.h" #include "clang-c/Index.h" #include "clang/Config/config.h" -#include "llvm/Support/AutoConvert.h" jsji wrote: Please update all the comments to use c style instead then? https://github.com/llvm/llvm-project/

[clang] Remove support for RenderScript (PR #112916)

2024-10-18 Thread via cfe-commits
cor3ntin wrote: Hey Aaron. Thanks for your contribution. We usually require a changelog for non-nfc changes. Can you add an entry to the release notes of clang? :clown_face: https://github.com/llvm/llvm-project/pull/112916 ___ cfe-commits mailing li

[clang] 7619699 - [clang] Make LazyOffsetPtr more portable (#112927)

2024-10-18 Thread via cfe-commits
Author: Jessica Clarke Date: 2024-10-18T21:49:23+01:00 New Revision: 76196998e25b98d81abc437708622261810782ca URL: https://github.com/llvm/llvm-project/commit/76196998e25b98d81abc437708622261810782ca DIFF: https://github.com/llvm/llvm-project/commit/76196998e25b98d81abc437708622261810782ca.diff

[clang] 85df281 - [clang-format] Fix a bug that always returns error for JSON (#112839)

2024-10-18 Thread via cfe-commits
Author: Owen Pan Date: 2024-10-18T21:10:00-07:00 New Revision: 85df28180bd38d3fd5356efe6022eebec31e0814 URL: https://github.com/llvm/llvm-project/commit/85df28180bd38d3fd5356efe6022eebec31e0814 DIFF: https://github.com/llvm/llvm-project/commit/85df28180bd38d3fd5356efe6022eebec31e0814.diff LOG:

[clang] [clang-format] Fix a bug that always returns error for JSON (PR #112839)

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

[clang] [llvm] [Clang] Match MSVC handling of duplicate header search paths in Microsoft compatibility modes. (PR #105738)

2024-10-18 Thread Tom Honermann via cfe-commits
tahonermann wrote: > This choice seems like a question of how the driver's command line is > interpreted, rather than a language mode, so I wonder if it makes sense for > it to consider `-fms-compatibility` at all or whether this should just be > based on the driver mode. Do you have rationale

[clang] [clang-format] Fix a bug that always returns error for JSON (PR #112839)

2024-10-18 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `sanitizer-x86_64-linux-bootstrap-asan` running on `sanitizer-buildbot2` while building `clang` at step 2 "annotate". Full details are available at: https://lab.llvm.org/buildbot/#/builders/52/builds/3045 Here is the relevan

[clang] [llvm] [Clang] Match MSVC handling of duplicate header search paths in Microsoft compatibility modes. (PR #105738)

2024-10-18 Thread Richard Smith via cfe-commits
zygoloid wrote: I've been pondering this. On the one hand, people switching from the `cl.exe`-compatible driver to the GCC-compatible driver might want the MSVC interpretation of the path flags. On the other hand, people enabling `-fms-compatibility` to accept code written against MSVC in a di

[clang] [llvm] [TLI] Add support for the `ilogb` libcall. (PR #112725)

2024-10-18 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `openmp-offload-libc-amdgpu-runtime` running on `omp-vega20-1` while building `clang,llvm` at step 10 "Add check check-offload". Full details are available at: https://lab.llvm.org/buildbot/#/builders/73/builds/7244 Here is

[clang] [llvm] [Coverage] Introduce "partial fold" on BranchRegion (PR #112694)

2024-10-18 Thread Jessica Paquette via cfe-commits
@@ -125,7 +125,7 @@ json::Array renderRegions(ArrayRef Regions) { json::Array renderBranchRegions(ArrayRef Regions) { json::Array RegionArray; for (const auto &Region : Regions) -if (!Region.Folded) +if (!Region.TrueFolded || !Region.FalseFolded) o

[clang-tools-extra] [clang-tidy] rewrite matchers in modernize-use-starts-ends-with (PR #112101)

2024-10-18 Thread Julian Schmidt via cfe-commits
https://github.com/5chmidti closed https://github.com/llvm/llvm-project/pull/112101 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] 18b5018 - [clang-tidy] rewrite matchers in modernize-use-starts-ends-with (#112101)

2024-10-18 Thread via cfe-commits
Author: Julian Schmidt Date: 2024-10-18T09:07:21+02:00 New Revision: 18b50189a749a39d1ac61a72af1d103f68fefc6b URL: https://github.com/llvm/llvm-project/commit/18b50189a749a39d1ac61a72af1d103f68fefc6b DIFF: https://github.com/llvm/llvm-project/commit/18b50189a749a39d1ac61a72af1d103f68fefc6b.diff

[clang] [llvm] [Coverage] Introduce "partial fold" on BranchRegion (PR #112694)

2024-10-18 Thread Jessica Paquette via cfe-commits
@@ -19,18 +19,18 @@ using namespace coverage; static void sumBranches(size_t &NumBranches, size_t &CoveredBranches, const ArrayRef &Branches) { for (const auto &BR : Branches) { -// Skip folded branches. -if (BR.Folded) - continue; - -

[clang] 5a09ce9 - [OpenCL] Replace a CreatePointerCast call; NFC (#112676)

2024-10-18 Thread via cfe-commits
Author: Sven van Haastregt Date: 2024-10-18T09:10:05+02:00 New Revision: 5a09ce9e038ed73ea60edf5463dd6509f7c4848f URL: https://github.com/llvm/llvm-project/commit/5a09ce9e038ed73ea60edf5463dd6509f7c4848f DIFF: https://github.com/llvm/llvm-project/commit/5a09ce9e038ed73ea60edf5463dd6509f7c4848f.

[clang] [OpenCL] Replace a CreatePointerCast call; NFC (PR #112676)

2024-10-18 Thread Sven van Haastregt via cfe-commits
https://github.com/svenvh closed https://github.com/llvm/llvm-project/pull/112676 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [flang][Driver] Add support for -f[no-]wrapv and -f[no]-strict-overflow in the frontend (PR #110061)

2024-10-18 Thread Yusuke MINATO via cfe-commits
yus3710-fj wrote: CI failed again, but the test mentioned above was passed this time. So, I think I can merge this. https://github.com/llvm/llvm-project/pull/110061 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin

[clang] 9698e57 - [flang][Driver] Add support for -f[no-]wrapv and -f[no]-strict-overflow in the frontend (#110061)

2024-10-18 Thread via cfe-commits
Author: Yusuke MINATO Date: 2024-10-18T16:30:23+09:00 New Revision: 9698e57548c61d356f12cc42a8b4785e56f9ab51 URL: https://github.com/llvm/llvm-project/commit/9698e57548c61d356f12cc42a8b4785e56f9ab51 DIFF: https://github.com/llvm/llvm-project/commit/9698e57548c61d356f12cc42a8b4785e56f9ab51.diff

[clang] [clang][AST] CXXRecords in anony namespace from diff TUs shouldn't be equivalent (PR #112534)

2024-10-18 Thread Balázs Kéri via cfe-commits
balazske wrote: The fix looks acceptable, but a test is needed. The test code in the bug report can be used somehow in at the AST merge LIT tests or in the `ASTImporterTest`. https://github.com/llvm/llvm-project/pull/112534 ___ cfe-commits mailing lis

[clang] [flang] [flang][Driver] Add support for -f[no-]wrapv and -f[no]-strict-overflow in the frontend (PR #110061)

2024-10-18 Thread Yusuke MINATO via cfe-commits
https://github.com/yus3710-fj closed https://github.com/llvm/llvm-project/pull/110061 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [compiler-rt] [libcxx] [llvm] [clang] Warn about memset/memcpy to NonTriviallyCopyable types (PR #111434)

2024-10-18 Thread via cfe-commits
serge-sans-paille wrote: @AaronBallman soft and gentle ping :-) https://github.com/llvm/llvm-project/pull/111434 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Add implicit resource element type concepts to AST (PR #112600)

2024-10-18 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 updated https://github.com/llvm/llvm-project/pull/112600 >From 0739f6da81d7c1edd9578ae4ff9dd699e5c828c6 Mon Sep 17 00:00:00 2001 From: Joshua Batista Date: Thu, 10 Oct 2024 14:31:25 -0700 Subject: [PATCH 01/14] ConceptSpecializationExpr shows up in AST!!! --- .../c

[clang] [Clang][HIP] Deprecate the AMDGCN_WAVEFRONT_SIZE macros (PR #112849)

2024-10-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Fabian Ritter (ritter-x2a) Changes So far, these macros can be used in contexts where no meaningful wavefront size is available. We therefore deprecate these macros, to replace them with a more resilient interface to access wavefront size

[clang] [Clang][HIP] Deprecate the AMDGCN_WAVEFRONT_SIZE macros (PR #112849)

2024-10-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-amdgpu Author: Fabian Ritter (ritter-x2a) Changes So far, these macros can be used in contexts where no meaningful wavefront size is available. We therefore deprecate these macros, to replace them with a more resilient interface to access wavef

[clang] [Clang][HIP] Deprecate the AMDGCN_WAVEFRONT_SIZE macros (PR #112849)

2024-10-18 Thread Fabian Ritter via cfe-commits
https://github.com/ritter-x2a created https://github.com/llvm/llvm-project/pull/112849 So far, these macros can be used in contexts where no meaningful wavefront size is available. We therefore deprecate these macros, to replace them with a more resilient interface to access wavefront size inf

[clang] [clang][bytecode] Ignore explicit calls to trivial dtors (PR #112841)

2024-10-18 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr closed https://github.com/llvm/llvm-project/pull/112841 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 9d0616c - [clang][bytecode] Ignore explicit calls to trivial dtors (#112841)

2024-10-18 Thread via cfe-commits
Author: Timm Baeder Date: 2024-10-18T09:45:02+02:00 New Revision: 9d0616ce52fc2a75c8e4808adec41d5189f4240c URL: https://github.com/llvm/llvm-project/commit/9d0616ce52fc2a75c8e4808adec41d5189f4240c DIFF: https://github.com/llvm/llvm-project/commit/9d0616ce52fc2a75c8e4808adec41d5189f4240c.diff L

[clang] Remove type-punning in LazyOffsetPtr. (PR #112806)

2024-10-18 Thread Richard Smith via cfe-commits
https://github.com/zygoloid edited https://github.com/llvm/llvm-project/pull/112806 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Remove type-punning in LazyOffsetPtr. (PR #112806)

2024-10-18 Thread Richard Smith via cfe-commits
zygoloid wrote: > > This violates aliasing rules and doesn't work at all on big-endian 64-bit > > systems where the pointer is stored in the second four bytes of the > > uint64_t. > > Your sizes aren't correct in the description here. This issue occurs on big > endian 32-bit systems, Yeah, s

[clang] [Coverage] Introduce `getBranchCounterPair()`. NFC. (PR #112702)

2024-10-18 Thread Jessica Paquette via cfe-commits
@@ -1592,6 +1605,13 @@ struct CounterCoverageMappingBuilder llvm::EnableSingleByteCoverage ? getRegionCounter(S->getCond()) : addCounters(ParentCount, BackedgeCount, BC.ContinueCount); +auto [ExecCount, ExitCount] = +(llvm::EnableSing

[clang] [Coverage] Introduce `getBranchCounterPair()`. NFC. (PR #112702)

2024-10-18 Thread Jessica Paquette via cfe-commits
@@ -941,6 +941,19 @@ struct CounterCoverageMappingBuilder return Counter::getCounter(CounterMap[S]); } + std::pair getBranchCounterPair(const Stmt *S, + Counter ParentCnt) { +Counter ExecCnt = getRegionCounter(S); +

[clang] 09cc75e - [clang] Deduplicate the logic that only warns once when stack is almost full (#112552)

2024-10-18 Thread via cfe-commits
Author: Boaz Brickner Date: 2024-10-18T10:11:14+02:00 New Revision: 09cc75e2ccc3616e1cb3b17f2fb99cb3bb323b12 URL: https://github.com/llvm/llvm-project/commit/09cc75e2ccc3616e1cb3b17f2fb99cb3bb323b12 DIFF: https://github.com/llvm/llvm-project/commit/09cc75e2ccc3616e1cb3b17f2fb99cb3bb323b12.diff

[clang] [clang] Deduplicate the logic that only warns once when stack is almost full (PR #112552)

2024-10-18 Thread Boaz Brickner via cfe-commits
https://github.com/bricknerb updated https://github.com/llvm/llvm-project/pull/112552 >From 8ff7b52319c5525a4ff26c324c283c6b0d249de3 Mon Sep 17 00:00:00 2001 From: Boaz Brickner Date: Tue, 15 Oct 2024 14:46:59 + Subject: [PATCH 1/5] [clang] Dedupliate the logic that only warns once when st

[clang] [AMDGPU] Allow overload of __builtin_amdgcn_mov/update_dpp (PR #112447)

2024-10-18 Thread Stanislav Mekhanoshin via cfe-commits
https://github.com/rampitec updated https://github.com/llvm/llvm-project/pull/112447 >From 761b3e21748dd3a7b53cd0ead745943213317eb4 Mon Sep 17 00:00:00 2001 From: Stanislav Mekhanoshin Date: Tue, 15 Oct 2024 15:23:28 -0700 Subject: [PATCH 1/6] [AMDGPU] Allow overload of __builtin_amdgcn_mov/up

[clang] [compiler-rt] [libcxx] [llvm] [clang] Warn about memset/memcpy to NonTriviallyCopyable types (PR #111434)

2024-10-18 Thread Carlos Galvez via cfe-commits
@@ -102,7 +102,7 @@ struct __aliasing_iterator_wrapper { _LIBCPP_HIDE_FROM_ABI _Alias operator*() const _NOEXCEPT { _Alias __val; - __builtin_memcpy(&__val, std::__to_address(__base_), sizeof(value_type)); + __builtin_memcpy(&__val, static_cast(std::__to_ad

[clang] [clang-tools-extra] [llvm] [clang] Introduce diagnostics suppression mappings (PR #112517)

2024-10-18 Thread kadir çetinkaya via cfe-commits
@@ -332,19 +334,22 @@ static void SetupSerializedDiagnostics(DiagnosticOptions *DiagOpts, void CompilerInstance::createDiagnostics(DiagnosticConsumer *Client, bool ShouldOwnClient) { - Diagnostics = createDiagnostics(&getDiagnosticOpt

[clang] [llvm] [Coverage] Introduce "partial fold" on BranchRegion (PR #112694)

2024-10-18 Thread NAKAMURA Takumi via cfe-commits
@@ -19,18 +19,18 @@ using namespace coverage; static void sumBranches(size_t &NumBranches, size_t &CoveredBranches, const ArrayRef &Branches) { for (const auto &BR : Branches) { -// Skip folded branches. -if (BR.Folded) - continue; - -

[clang] [llvm] [Coverage] Introduce "partial fold" on BranchRegion (PR #112694)

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

[clang] [llvm] [Coverage] Introduce "partial fold" on BranchRegion (PR #112694)

2024-10-18 Thread NAKAMURA Takumi via cfe-commits
@@ -125,7 +125,7 @@ json::Array renderRegions(ArrayRef Regions) { json::Array renderBranchRegions(ArrayRef Regions) { json::Array RegionArray; for (const auto &Region : Regions) -if (!Region.Folded) +if (!Region.TrueFolded || !Region.FalseFolded) c

[clang] [llvm] [Coverage] Introduce "partial fold" on BranchRegion (PR #112694)

2024-10-18 Thread NAKAMURA Takumi via cfe-commits
https://github.com/chapuni commented: Thanks for comments! https://github.com/llvm/llvm-project/pull/112694 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Coverage] Introduce "partial fold" on BranchRegion (PR #112694)

2024-10-18 Thread Hana Dusíková via cfe-commits
hanickadot wrote: Do you have example before/after of the change? It's a bit hard to imagine. https://github.com/llvm/llvm-project/pull/112694 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-c

[clang] [llvm] [Coverage] Introduce "partial fold" on BranchRegion (PR #112694)

2024-10-18 Thread NAKAMURA Takumi via cfe-commits
@@ -719,10 +720,10 @@ struct FunctionRecord { Region.Kind == CounterMappingRegion::MCDCBranchRegion) { CountedBranchRegions.emplace_back(Region, Count, FalseCount, HasSingleByteCoverage); - // If both counters are hard-

[clang] [Sema] Fix warnings in SemaFunctionEffects.cpp (PR #112857)

2024-10-18 Thread Karl-Johan Karlsson via cfe-commits
https://github.com/karka228 created https://github.com/llvm/llvm-project/pull/112857 Fix gcc warnings like: SemaFunctionEffects.cpp:1531:5: warning: this statement may fall through [-Wimplicit-fallthrough=] >From ba5358f12c84266c4527d0e045055b10eabe4a0f Mon Sep 17 00:00:00 2001 From: Karl-Joha

[clang] [Sema] Fix warnings in SemaFunctionEffects.cpp (PR #112857)

2024-10-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Karl-Johan Karlsson (karka228) Changes Fix gcc warnings like: SemaFunctionEffects.cpp:1531:5: warning: this statement may fall through [-Wimplicit-fallthrough=] --- Full diff: https://github.com/llvm/llvm-project/pull/112857.diff 1 File

[clang] [analyzer] Improve solver (PR #112583)

2024-10-18 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat approved this pull request. LGTM, thanks for the updates! I have an optional suggestion/question in the only inline discussion that's left unresolved, but feel free to merge this without handling that. https://github.com/llvm/llvm-project/pull/112583 __

[clang] [Clang] Fix handling of immediate escalation for inherited constructors (PR #112860)

2024-10-18 Thread via cfe-commits
https://github.com/cor3ntin updated https://github.com/llvm/llvm-project/pull/112860 >From 57e5a150295cd828f852e198e2e9e4e8d5ed66ce Mon Sep 17 00:00:00 2001 From: Corentin Jabot Date: Fri, 18 Oct 2024 10:59:35 +0200 Subject: [PATCH 1/2] [Clang] Fix handling of immediate escalation for inherite

[clang] [clang][bytecode] Ignore explicit calls to trivial dtors (PR #112841)

2024-10-18 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `clang-cmake-x86_64-avx512-linux` running on `avx512-intel64` while building `clang` at step 7 "ninja check 1". Full details are available at: https://lab.llvm.org/buildbot/#/builders/133/builds/5383 Here is the relevant pie

[clang] [clang] Deduplicate the logic that only warns once when stack is almost full (PR #112552)

2024-10-18 Thread Boaz Brickner via cfe-commits
https://github.com/bricknerb closed https://github.com/llvm/llvm-project/pull/112552 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Coverage] Introduce `getBranchCounterPair()`. NFC. (PR #112702)

2024-10-18 Thread Jessica Paquette via cfe-commits
@@ -1709,6 +1730,13 @@ struct CounterCoverageMappingBuilder : addCounters( addCounters(ParentCount, BackedgeCount, BodyBC.ContinueCount), IncrementBC.ContinueCount); +auto [ExecCount, ExitCount] = +(llvm::EnableSingle

[clang] [Coverage] Introduce `getBranchCounterPair()`. NFC. (PR #112702)

2024-10-18 Thread Jessica Paquette via cfe-commits
@@ -1804,9 +1832,10 @@ struct CounterCoverageMappingBuilder Counter LoopCount = addCounters(ParentCount, BackedgeCount, BC.ContinueCount); -Counter OutCount = -addCounters(BC.BreakCount, subtractCounters(LoopCount, BodyCount)); -if (OutCount != Pare

[clang] [clang] Fix C23 constexpr crashes (PR #112708)

2024-10-18 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon closed https://github.com/llvm/llvm-project/pull/112708 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV] Add Smdbltrp and Ssdbltrp extension (PR #111837)

2024-10-18 Thread via cfe-commits
https://github.com/T-Tie updated https://github.com/llvm/llvm-project/pull/111837 >From 2c193cb89f5071ec89ccbe7df363bbff70dda85e Mon Sep 17 00:00:00 2001 From: T-Tie <160845405+t-...@users.noreply.github.com> Date: Thu, 10 Oct 2024 21:11:39 +0800 Subject: [PATCH 1/9] Update riscv-target-features

[clang] [clang] LazyOffsetPtr: Use native pointer width (PR #111995)

2024-10-18 Thread Richard Smith via cfe-commits
zygoloid wrote: > > > #112806 should address this without narrowing the field to 32 bits. > > > > > > As does [#111995 > > (comment)](https://github.com/llvm/llvm-project/pull/111995#discussion_r1805329590), > > with less code and more generality > > I prefer this solution too. That solutio

[clang] [AMDGPU] Allow overload of __builtin_amdgcn_mov/update_dpp (PR #112447)

2024-10-18 Thread Stanislav Mekhanoshin via cfe-commits
rampitec wrote: I actually wish a better way to have overloaded builtins in clang. I do not believe any user of these builtins is expecting that a wide integer will be silently truncated, and any fp will go through fptosi and backwards after, like we do now. We have much more builtins like tha

[clang-tools-extra] [clangd] Let DefineOutline tweak handle member function templates (PR #112345)

2024-10-18 Thread kadir çetinkaya via cfe-commits
kadircet wrote: i remember mainly two concerns; - we didn't want to surprise developers by breaking their builds as template definitions needs to be visible at instantiation sites. so if we keep the definition in the same file, just move it out-of-line, this should be fine. - i remember AST was

[clang] [Coverage] Introduce `getBranchCounterPair()`. NFC. (PR #112702)

2024-10-18 Thread Jessica Paquette via cfe-commits
@@ -941,6 +941,19 @@ struct CounterCoverageMappingBuilder return Counter::getCounter(CounterMap[S]); } + std::pair getBranchCounterPair(const Stmt *S, ornata wrote: it's not immediately obvious what the pair represents from this function name. `getExe

[clang] [Coverage] Introduce `getBranchCounterPair()`. NFC. (PR #112702)

2024-10-18 Thread Jessica Paquette via cfe-commits
@@ -941,6 +941,19 @@ struct CounterCoverageMappingBuilder return Counter::getCounter(CounterMap[S]); } + std::pair getBranchCounterPair(const Stmt *S, + Counter ParentCnt) { +Counter ExecCnt = getRegionCounter(S); +

[clang] [CLANG][AArch64]Add SVE tuple types for mfloat8_t (PR #112687)

2024-10-18 Thread via cfe-commits
https://github.com/CarolineConcatto closed https://github.com/llvm/llvm-project/pull/112687 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 508fd96 - [CLANG][AArch64]Add SVE tuple types for mfloat8_t (#112687)

2024-10-18 Thread via cfe-commits
Author: CarolineConcatto Date: 2024-10-18T09:10:17+01:00 New Revision: 508fd966fb00428ccd1dd7ddeb636fb7393029ec URL: https://github.com/llvm/llvm-project/commit/508fd966fb00428ccd1dd7ddeb636fb7393029ec DIFF: https://github.com/llvm/llvm-project/commit/508fd966fb00428ccd1dd7ddeb636fb7393029ec.di

[clang] [clang] Deduplicate the logic that only warns once when stack is almost full (PR #112552)

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

[clang] abfba7d - [clang] Fix C23 constexpr crashes (#112708)

2024-10-18 Thread via cfe-commits
Author: Mariya Podchishchaeva Date: 2024-10-18T10:18:34+02:00 New Revision: abfba7d2e6a3cb0f1d0c976898447957dbbca6e0 URL: https://github.com/llvm/llvm-project/commit/abfba7d2e6a3cb0f1d0c976898447957dbbca6e0 DIFF: https://github.com/llvm/llvm-project/commit/abfba7d2e6a3cb0f1d0c976898447957dbbca6

[clang] [clang] Deduplicate the logic that only warns once when stack is almost full (PR #112552)

2024-10-18 Thread Boaz Brickner via cfe-commits
@@ -0,0 +1,45 @@ +//===--- SingleWarningStackAwareExecutor.h - A utility for warning once when +// close to out of stack space ---*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for lic

[clang] [Coverage] Introduce `getBranchCounterPair()`. NFC. (PR #112702)

2024-10-18 Thread Jessica Paquette via cfe-commits
@@ -1645,22 +1662,26 @@ struct CounterCoverageMappingBuilder Counter CondCount = llvm::EnableSingleByteCoverage ? getRegionCounter(S->getCond()) : addCounters(BackedgeCount, BC.ContinueCount); +auto [ExecCount, Exi

[clang] [Coverage] Introduce `getBranchCounterPair()`. NFC. (PR #112702)

2024-10-18 Thread Jessica Paquette via cfe-commits
@@ -1709,6 +1730,13 @@ struct CounterCoverageMappingBuilder : addCounters( addCounters(ParentCount, BackedgeCount, BodyBC.ContinueCount), IncrementBC.ContinueCount); +auto [ExecCount, ExitCount] = +(llvm::EnableSingle

[clang] [clang] Fix C23 constexpr crashes (PR #112708)

2024-10-18 Thread Mariya Podchishchaeva via cfe-commits
Fznamznon wrote: Release branch cherry-pick https://github.com/llvm/llvm-project/pull/112855 https://github.com/llvm/llvm-project/pull/112708 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-co

[clang] [clang] constexpr built-in abs function. (PR #112539)

2024-10-18 Thread via cfe-commits
https://github.com/c8ef updated https://github.com/llvm/llvm-project/pull/112539 >From dfa1585af3f080987cbd15830c45c34bfecc1fca Mon Sep 17 00:00:00 2001 From: c8ef Date: Wed, 16 Oct 2024 01:18:13 + Subject: [PATCH 01/11] implement constexpr builtin {l}abs --- clang/include/clang/Basic/Buil

[clang] [Clang] Fix handling of immediate escalation for inherited constructors (PR #112860)

2024-10-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: cor3ntin (cor3ntin) Changes Fixes #112677 --- Full diff: https://github.com/llvm/llvm-project/pull/112860.diff 3 Files Affected: - (modified) clang/docs/ReleaseNotes.rst (+2-1) - (modified) clang/lib/AST/Decl.cpp (+13) - (modified) cl

[clang] [clang] constexpr built-in abs function. (PR #112539)

2024-10-18 Thread via cfe-commits
c8ef wrote: Thank you for all your reviews! If there are no further comments, I will proceed with merging this after updating the branch. https://github.com/llvm/llvm-project/pull/112539 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https:/

[clang] [Clang] Fix handling of immediate escalation for inherited constructors (PR #112860)

2024-10-18 Thread via cfe-commits
https://github.com/cor3ntin created https://github.com/llvm/llvm-project/pull/112860 Fixes #112677 >From 57e5a150295cd828f852e198e2e9e4e8d5ed66ce Mon Sep 17 00:00:00 2001 From: Corentin Jabot Date: Fri, 18 Oct 2024 10:59:35 +0200 Subject: [PATCH] [Clang] Fix handling of immediate escalation fo

[clang] [Clang] Fix handling of immediate escalation for inherited constructors (PR #112860)

2024-10-18 Thread Timm Baeder via cfe-commits
@@ -3284,6 +3284,13 @@ bool FunctionDecl::isImmediateEscalating() const { // consteval specifier, if (isDefaulted() && !isConsteval()) return true; + + if (auto *CD = dyn_cast(this); tbaederr wrote: ```suggestion if (const auto *CD = dyn_cast(this);

[clang] [clang][analyzer][doc] Update Clang SA www docs index.html (PR #112833)

2024-10-18 Thread via cfe-commits
@@ -121,10 +80,25 @@ Mac OS X - Other Platforms - For other platforms, please follow the instructions for building the analyzer from - source code. +The static analyzer is part of Clang. Please refer to the +https://releases.llvm.org/download.html";>LLVM +

[clang] [analyzer] Improve solver (PR #112583)

2024-10-18 Thread Donát Nagy via cfe-commits
@@ -177,7 +177,8 @@ BugReportPtr BitwiseShiftValidator::checkOvershift() { RightOpStr = formatv(" '{0}'", ConcreteRight->getValue()); else { SValBuilder &SVB = Ctx.getSValBuilder(); -if (const llvm::APSInt *MinRight = SVB.getMinValue(FoldedState, Right)) { +if

[clang-tools-extra] [clangd] Let DefineOutline tweak handle member function templates (PR #112345)

2024-10-18 Thread Christian Kandeler via cfe-commits
ckandeler wrote: > ```c++ > template > inline void Foo::bar(const T& t, const U& u) {} > ``` > > this won't compile as `T` isn't defined. you also need to print `template > ` on top (and keep doing for rest of the outer decls). The patch does that already. In the test, the outer template dec

[clang] [clang][analyzer][doc] Migrate ClangSA www FAQ section (PR #112831)

2024-10-18 Thread Donát Nagy via cfe-commits
@@ -0,0 +1,208 @@ +FAQ and How to Deal with Common False Positives +=== + +.. contents:: + :local: + +Custom Assertions +- + +Q: How do I tell the analyzer that I do not want the bug being reported here since my custom

[clang] [clang][analyzer][doc] Migrate ClangSA www FAQ section (PR #112831)

2024-10-18 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat commented: Overall LGTM, with some minor bikeshedding on the redirect page. I also added several inline comments about the _content_ of the page, but the content changes should be left for a separate follow-up commit to separate migrating the text and changing it.

[clang] [clang][analyzer][doc] Migrate ClangSA www FAQ section (PR #112831)

2024-10-18 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat edited https://github.com/llvm/llvm-project/pull/112831 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][bytecode] Check for memory leaks after destroying global scope (PR #112868)

2024-10-18 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes The global scope we create when evaluating expressions might free some of the dynamic memory allocations, so we can't check for memory leaks before destroying it. --- Full diff: https://github.com/llvm/llvm

[clang] [clang][analyzer][doc] Migrate ClangSA www FAQ section (PR #112831)

2024-10-18 Thread Donát Nagy via cfe-commits
@@ -0,0 +1,208 @@ +FAQ and How to Deal with Common False Positives +=== + +.. contents:: + :local: + +Custom Assertions +- + +Q: How do I tell the analyzer that I do not want the bug being reported here since my custom

[clang] [clang][analyzer][doc] Migrate ClangSA www FAQ section (PR #112831)

2024-10-18 Thread Donát Nagy via cfe-commits
@@ -0,0 +1,208 @@ +FAQ and How to Deal with Common False Positives +=== + +.. contents:: + :local: + +Custom Assertions +- + +Q: How do I tell the analyzer that I do not want the bug being reported here since my custom

[clang] [clang][analyzer][doc] Migrate ClangSA www FAQ section (PR #112831)

2024-10-18 Thread Donát Nagy via cfe-commits
@@ -0,0 +1,208 @@ +FAQ and How to Deal with Common False Positives +=== + +.. contents:: + :local: + +Custom Assertions +- + +Q: How do I tell the analyzer that I do not want the bug being reported here since my custom

[clang] [llvm] [Coverage] Introduce "partial fold" on BranchRegion (PR #112694)

2024-10-18 Thread Hana Dusíková via cfe-commits
https://github.com/hanickadot approved this pull request. https://github.com/llvm/llvm-project/pull/112694 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Coverage] Introduce "partial fold" on BranchRegion (PR #112694)

2024-10-18 Thread Hana Dusíková via cfe-commits
hanickadot wrote: I have no additional list of thing Jessica pointed out, LGTM https://github.com/llvm/llvm-project/pull/112694 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][analyzer][doc] Migrate ClangSA www FAQ section (PR #112831)

2024-10-18 Thread Donát Nagy via cfe-commits
@@ -18,242 +17,11 @@ FAQ and How to Deal with Common False Positives +This page is deprecated and will be removed in release 21.0 +https://clang.llvm.org/docs/analyzer/user-docs/FAQ.html";>The new site NagyDonat wrote: ```suggestion Its content was migrate

[clang] [Clang] Fix handling of immediate escalation for inherited constructors (PR #112860)

2024-10-18 Thread Timm Baeder via cfe-commits
@@ -3304,6 +3311,12 @@ bool FunctionDecl::isImmediateFunction() const { if (isImmediateEscalating() && BodyContainsImmediateEscalatingExpressions()) return true; + if (auto *CD = dyn_cast(this); tbaederr wrote: ```suggestion if (const auto *CD = dyn_

[clang] [analyzer] Improve solver (PR #112583)

2024-10-18 Thread Balazs Benics via cfe-commits
@@ -2883,22 +2883,16 @@ const llvm::APSInt *RangeConstraintManager::getSymVal(ProgramStateRef St, const llvm::APSInt *RangeConstraintManager::getSymMinVal(ProgramStateRef St, SymbolRef Sym) const { - // TODO: Use `getR

[clang] [Clang] Emit error for duplicate mangled names within a lambda (PR #107581)

2024-10-18 Thread Kerry McLaughlin via cfe-commits
https://github.com/kmclaughlin-arm updated https://github.com/llvm/llvm-project/pull/107581 >From 1e6f25c517d8d1adeeaf59f826141efdcad8f05a Mon Sep 17 00:00:00 2001 From: Kerry McLaughlin Date: Fri, 6 Sep 2024 10:13:33 + Subject: [PATCH 1/5] [Clang] Emit error for duplicate mangled names wit

[clang] [llvm] [Coverage] Introduce "partial fold" on BranchRegion (PR #112694)

2024-10-18 Thread NAKAMURA Takumi via cfe-commits
@@ -19,18 +19,18 @@ using namespace coverage; static void sumBranches(size_t &NumBranches, size_t &CoveredBranches, const ArrayRef &Branches) { for (const auto &BR : Branches) { -// Skip folded branches. -if (BR.Folded) - continue; - -

[clang] [Clang][AArch64] Fix Pure Scalables Types argument passing and return (PR #112747)

2024-10-18 Thread Momchil Velikov via cfe-commits
@@ -353,6 +427,17 @@ AArch64ABIInfo::classifyArgumentType(QualType Ty, bool IsVariadic, nullptr, true, Align); } + // In AAPCS named arguments of a Pure Scalable Type are passed expanded in + // registers, or indirectly if there are not enough registers. + if (Ki

<    1   2   3   4   5   >