[clang-tools-extra] [clangd] Add tweak to add pure virtual overrides (PR #139348)

2025-05-14 Thread Marco Maia via cfe-commits
https://github.com/marcogmaia updated https://github.com/llvm/llvm-project/pull/139348 >From 76503bd8f5618b710e2909d1303de5d34723 Mon Sep 17 00:00:00 2001 From: Marco Maia Date: Sat, 10 May 2025 00:48:39 -0300 Subject: [PATCH 01/10] [clangd] Add tweak to add pure virtual overrides --- ...

[clang-tools-extra] [clangd] Add tweak to add pure virtual overrides (PR #139348)

2025-05-14 Thread Marco Maia via cfe-commits
https://github.com/marcogmaia edited https://github.com/llvm/llvm-project/pull/139348 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clangd] Add tweak to add pure virtual overrides (PR #139348)

2025-05-14 Thread Marco Maia via cfe-commits
@@ -0,0 +1,296 @@ +//===--- OverridePureVirtuals.cpp *- C++-*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [clangd] Add tweak to add pure virtual overrides (PR #139348)

2025-05-14 Thread Marco Maia via cfe-commits
@@ -0,0 +1,296 @@ +//===--- OverridePureVirtuals.cpp *- C++-*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [clangd] Add tweak to add pure virtual overrides (PR #139348)

2025-05-14 Thread Marco Maia via cfe-commits
https://github.com/marcogmaia commented: @zwuis, the second round of review was applied. https://github.com/llvm/llvm-project/pull/139348 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit

[clang-tools-extra] [clangd] Add tweak to add pure virtual overrides (PR #139348)

2025-05-14 Thread Marco Maia via cfe-commits
@@ -0,0 +1,296 @@ +//===--- OverridePureVirtuals.cpp *- C++-*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [clangd] Add tweak to add pure virtual overrides (PR #139348)

2025-05-14 Thread Marco Maia via cfe-commits
@@ -0,0 +1,296 @@ +//===--- OverridePureVirtuals.cpp *- C++-*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang] clang-format: Add IncludeSortKey option (PR #137840)

2025-05-14 Thread Owen Pan via cfe-commits
@@ -3221,15 +3223,33 @@ static void sortCppIncludes(const FormatStyle &Style, stable_sort(Indices, [&](unsigned LHSI, unsigned RHSI) { const auto LHSFilenameLower = Includes[LHSI].Filename.lower(); const auto RHSFilenameLower = Includes[RHSI].Filename.lower(); -

[clang] [flang] [flang][driver] Separate the actions of the `-emit-fir` and `-emit-mlir` options (PR #139857)

2025-05-14 Thread via cfe-commits
https://github.com/NexMing edited https://github.com/llvm/llvm-project/pull/139857 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Add new warning: not eliding copy on return (missed NRVO) (PR #139973)

2025-05-14 Thread Matheus Izvekov via cfe-commits
mizvekov wrote: > Thank you for your feedback. I added more tests. By "function templates with > placeholder return types", do you mean something similar to create_object4 in > my test case? Yep. That's what I meant. https://github.com/llvm/llvm-project/pull/139973 ___

[clang] [OpenMP] Add assertion for 'factor' width mismatch in 'unroll partial' (PR #139986)

2025-05-14 Thread ALBIN BABU VARGHESE via cfe-commits
https://github.com/albus-droid edited https://github.com/llvm/llvm-project/pull/139986 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 2a8960e - [RISCV] Add Andes XAndesVDot (Andes Vector Dot Product) extension. (#139849)

2025-05-14 Thread via cfe-commits
Author: Jim Lin Date: 2025-05-15T10:14:58+08:00 New Revision: 2a8960e48b178fb2533e71bbe164e9f383046114 URL: https://github.com/llvm/llvm-project/commit/2a8960e48b178fb2533e71bbe164e9f383046114 DIFF: https://github.com/llvm/llvm-project/commit/2a8960e48b178fb2533e71bbe164e9f383046114.diff LOG:

[clang] [clang] Enforce 1-based indexing for command line source locations (PR #139457)

2025-05-14 Thread Naveen Seth Hanig via cfe-commits
https://github.com/naveen-seth updated https://github.com/llvm/llvm-project/pull/139457 >From 5f246435b9784113ada3f82328433487391f40ab Mon Sep 17 00:00:00 2001 From: naveen-seth Date: Sun, 11 May 2025 14:24:00 + Subject: [PATCH 1/7] [clang] Enforce 1-based indexing for command line source

[clang] Pre-Commit tests: [HIP] Fix return type in __clang_hip_cmath.h (PR #139891)

2025-05-14 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm approved this pull request. https://github.com/llvm/llvm-project/pull/139891 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [CMake] Add a linker test for -Bsymbolic-functions to AddLLVM (PR #79539)

2025-05-14 Thread Fangrui Song via cfe-commits
@@ -355,6 +349,9 @@ function(add_link_opts target_name) set_property(TARGET ${target_name} APPEND_STRING PROPERTY LINK_FLAGS " -Wl,-brtl") endif() + + check_linker_flag(CXX "-Wl,-Bsymbolic-functions" MaskRay wrote: Add a comment what ta

[clang] [OpenMP] Add assertion for 'factor' width mismatch in 'unroll partial' (PR #139986)

2025-05-14 Thread ALBIN BABU VARGHESE via cfe-commits
https://github.com/albus-droid updated https://github.com/llvm/llvm-project/pull/139986 >From 3cc8334092853442f85c5a17a3bd31e373f30da8 Mon Sep 17 00:00:00 2001 From: albus-droid Date: Wed, 14 May 2025 15:49:11 -0400 Subject: [PATCH 1/4] Added two conditions to check for width of the factor var

[clang] [Clang] Bypass TAD during overload resolution if a perfect match exists (PR #136203)

2025-05-14 Thread Alexander Kornienko via cfe-commits
alexfh wrote: @cor3ntin we've root-caused an assertion failure in Clang to this commit. It reproduces at least up to 1778d3b8245b9a7787bbd0b00f60f879ed4689c9. The test case is being reduced, but maybe you can spot something obviously wrong from the assertion failure and the stack trace: ``` as

[clang] [libcxx] [llvm] [Clang] Add warnings when mixing different charN_t types (PR #138708)

2025-05-14 Thread Dimitrij Mijoski via cfe-commits
@@ -484,7 +484,7 @@ template void utf8_to_utf16_in_ok(const std::codecvt& cvt) { // UTF-8 string of 1-byte CP, 2-byte CP, 3-byte CP and 4-byte CP const unsigned char input[] = "b\u0448\u\U0010"; - const char16_t expected[] = {'b', 0x0448, 0x, 0xDBEA, 0xDEAA

[clang] 18b885f - Revert "[clang][modules] Timestamp-less validation API" (#139987)

2025-05-14 Thread via cfe-commits
Author: Qinkun Bao Date: 2025-05-14T21:02:57-04:00 New Revision: 18b885f66babff3a10451bc811ffc077d61ed8ee URL: https://github.com/llvm/llvm-project/commit/18b885f66babff3a10451bc811ffc077d61ed8ee DIFF: https://github.com/llvm/llvm-project/commit/18b885f66babff3a10451bc811ffc077d61ed8ee.diff LO

[clang] [clang-tools-extra] Revert "[clang][modules] Timestamp-less validation API" (PR #139987)

2025-05-14 Thread Qinkun Bao via cfe-commits
https://github.com/qinkunbao created https://github.com/llvm/llvm-project/pull/139987 Reverts llvm/llvm-project#138983 >From 1399d288c999ae0fad0b7fd6c030bc336af2c4e8 Mon Sep 17 00:00:00 2001 From: Qinkun Bao Date: Wed, 14 May 2025 21:02:29 -0400 Subject: [PATCH] Revert "[clang][modules] Timest

[clang] [clang-tools-extra] Revert "[clang][modules] Timestamp-less validation API" (PR #139987)

2025-05-14 Thread Qinkun Bao via cfe-commits
https://github.com/qinkunbao closed https://github.com/llvm/llvm-project/pull/139987 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] Revert "[clang][modules] Timestamp-less validation API" (PR #139987)

2025-05-14 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-modules Author: Qinkun Bao (qinkunbao) Changes Reverts llvm/llvm-project#138983 --- Full diff: https://github.com/llvm/llvm-project/pull/139987.diff 14 Files Affected: - (modified) clang-tools-extra/clangd/ModulesBuilder.cpp (+1-2) - (modified

[clang] [clang-tools-extra] Revert "[clang][modules] Timestamp-less validation API" (PR #139987)

2025-05-14 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tools-extra Author: Qinkun Bao (qinkunbao) Changes Reverts llvm/llvm-project#138983 --- Full diff: https://github.com/llvm/llvm-project/pull/139987.diff 14 Files Affected: - (modified) clang-tools-extra/clangd/ModulesBuilder.cpp (+1-2) - (modi

[clang] [llvm] [RISCV][MC] Add support for Q extension (PR #139369)

2025-05-14 Thread Iris Shi via cfe-commits
https://github.com/el-ev updated https://github.com/llvm/llvm-project/pull/139369 >From eb15367085a381955140982177e95ad94a645e92 Mon Sep 17 00:00:00 2001 From: Iris Shi <0...@owo.li> Date: Mon, 12 May 2025 13:19:06 +0800 Subject: [PATCH 1/2] [RISCV][MC] Add support for Q extension --- .../Driv

[clang] [llvm] [RISCV][MC] Add support for Q extension (PR #139369)

2025-05-14 Thread Iris Shi via cfe-commits
el-ev wrote: ### Merge activity * **May 14, 10:50 PM EDT**: A user started a stack merge that includes this pull request via [Graphite](https://app.graphite.dev/github/pr/llvm/llvm-project/139369). https://github.com/llvm/llvm-project/pull/139369 _

[clang] 1e503d0 - [RISCV][MC] Add support for Q extension (#139369)

2025-05-14 Thread via cfe-commits
Author: Iris Shi Date: 2025-05-15T10:51:06+08:00 New Revision: 1e503d08e1b6a285608e266acafd40eb2be5ca83 URL: https://github.com/llvm/llvm-project/commit/1e503d08e1b6a285608e266acafd40eb2be5ca83 DIFF: https://github.com/llvm/llvm-project/commit/1e503d08e1b6a285608e266acafd40eb2be5ca83.diff LOG:

[clang] [clang] Fix a segfault when M is a nullptr (PR #130712)

2025-05-14 Thread via cfe-commits
github-actions[bot] wrote: @matts1 Congratulations on having your first Pull Request (PR) merged into the LLVM Project! Your changes will be combined with recent changes from other authors, then tested by our [build bots](https://lab.llvm.org/buildbot/). If there is a problem with a build,

[clang] 4630d46 - [clang] Fix a segfault when M is a nullptr (#130712)

2025-05-14 Thread via cfe-commits
Author: Matt Date: 2025-05-15T10:50:45+08:00 New Revision: 4630d464c5cfd3f2ccdf3ac167694977736ce00e URL: https://github.com/llvm/llvm-project/commit/4630d464c5cfd3f2ccdf3ac167694977736ce00e DIFF: https://github.com/llvm/llvm-project/commit/4630d464c5cfd3f2ccdf3ac167694977736ce00e.diff LOG: [cl

[clang] [clang] Fix a segfault when M is a nullptr (PR #130712)

2025-05-14 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 closed https://github.com/llvm/llvm-project/pull/130712 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV][MC] Add Q support for Zfa (PR #139508)

2025-05-14 Thread Iris Shi via cfe-commits
https://github.com/el-ev edited https://github.com/llvm/llvm-project/pull/139508 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV][Scheduler] Add scheduler definitions for the Q extension (PR #139495)

2025-05-14 Thread Iris Shi via cfe-commits
https://github.com/el-ev edited https://github.com/llvm/llvm-project/pull/139495 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix a segfault when M is a nullptr (PR #130712)

2025-05-14 Thread Chuanqi Xu via cfe-commits
https://github.com/ChuanqiXu9 approved this pull request. https://github.com/llvm/llvm-project/pull/130712 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV][MC] Add support for Q extension (PR #139369)

2025-05-14 Thread Iris Shi via cfe-commits
https://github.com/el-ev closed https://github.com/llvm/llvm-project/pull/139369 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV][MC] Add Q support for Zfa (PR #139508)

2025-05-14 Thread Iris Shi via cfe-commits
https://github.com/el-ev updated https://github.com/llvm/llvm-project/pull/139508 >From eb15367085a381955140982177e95ad94a645e92 Mon Sep 17 00:00:00 2001 From: Iris Shi <0...@owo.li> Date: Mon, 12 May 2025 13:19:06 +0800 Subject: [PATCH 1/3] [RISCV][MC] Add support for Q extension --- .../Driv

[clang] [llvm] [RISCV][Scheduler] Add scheduler definitions for the Q extension (PR #139495)

2025-05-14 Thread Iris Shi via cfe-commits
el-ev wrote: ### Merge activity * **May 14, 10:53 PM EDT**: [Graphite](https://app.graphite.dev/github/pr/llvm/llvm-project/139495) couldn't merge this PR because it had conflicts with the trunk branch. https://github.com/llvm/llvm-project/pull/139495

[clang] [llvm] [CMake] Add a linker test for -Bsymbolic-functions to AddLLVM (PR #79539)

2025-05-14 Thread Brad Smith via cfe-commits
https://github.com/brad0 updated https://github.com/llvm/llvm-project/pull/79539 >From 03859cb1b4eb4132c831fdc8a36909df2981292d Mon Sep 17 00:00:00 2001 From: Brad Smith Date: Thu, 25 Jan 2024 16:20:47 -0500 Subject: [PATCH] [CMake] Add a linker test for -Bsymbolic-functions to AddLLVM Add a li

[clang] [clang] Enforce 1-based indexing for command line source locations (PR #139457)

2025-05-14 Thread Naveen Seth Hanig via cfe-commits
https://github.com/naveen-seth updated https://github.com/llvm/llvm-project/pull/139457 >From 5f246435b9784113ada3f82328433487391f40ab Mon Sep 17 00:00:00 2001 From: naveen-seth Date: Sun, 11 May 2025 14:24:00 + Subject: [PATCH 1/7] [clang] Enforce 1-based indexing for command line source

[clang] [RISCV] Implement intrinsics for XAndesVPackFPH (PR #140007)

2025-05-14 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-risc-v Author: Jim Lin (tclin914) Changes This patch implements clang intrinsic support for XAndesVPackFPH. The document for the intrinsics can be found at: https://github.com/andestech/andes-vector-intrinsic-doc/blob/ast-v5_4_0-release-v5/auto-

[clang] [RISCV] Implement intrinsics for XAndesVPackFPH (PR #140007)

2025-05-14 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Jim Lin (tclin914) Changes This patch implements clang intrinsic support for XAndesVPackFPH. The document for the intrinsics can be found at: https://github.com/andestech/andes-vector-intrinsic-doc/blob/ast-v5_4_0-release-v5/auto-generated

[clang] [Serialization] Fix lazy template loading (PR #133057)

2025-05-14 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: > @emaxx-google, @ilya-biryukov, do you think we can move forward even though > don't have a reproducer yet? It feels we are stuck on that one case on a > downstream client -- worst case maybe the devs can work it around by changing > source code for that one case? Yes, I'm

[libclc] [libclc] Improving vector code generated from scalar code (PR #140008)

2025-05-14 Thread Wenju He via cfe-commits
https://github.com/wenju-he created https://github.com/llvm/llvm-project/pull/140008 The previous method splits vector data into two halves. shuffle_vector concatenates the two results into a vector data of original size. This PR eliminates the use of shuffle_vector. >From c17e8d57045e32d4602

[libclc] [libclc] Improving vector code generated from scalar code (PR #140008)

2025-05-14 Thread Wenju He via cfe-commits
wenju-he wrote: @frasercrmck please help to review, thanks. https://github.com/llvm/llvm-project/pull/140008 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [RISCV] Implement intrinsics for XAndesVPackFPH (PR #140007)

2025-05-14 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff HEAD~1 HEAD --extensions cpp,c,h -- clang/lib/Headers/andes_vector.h clang/test/Code

[clang] [llvm] [llvm] properly guard dump methods in Support lib classes (PR #139938)

2025-05-14 Thread Andrew Rogers via cfe-commits
https://github.com/andrurogerz created https://github.com/llvm/llvm-project/pull/139938 ## Purpose Add proper preprocessor guards for all `dump()` methods in the LLVM support library. This change ensures these methods are not part of the public ABI for release builds. ## Overview * Annotates

[clang] baf2cfa - Revert "[clang][analyzer] Fix a nullptr dereference when `-ftime-trace` is used" (#139936)

2025-05-14 Thread via cfe-commits
Author: Fangyi Zhou Date: 2025-05-14T13:45:05-04:00 New Revision: baf2cfa299ea62f3bdb717c8f464f824257527ff URL: https://github.com/llvm/llvm-project/commit/baf2cfa299ea62f3bdb717c8f464f824257527ff DIFF: https://github.com/llvm/llvm-project/commit/baf2cfa299ea62f3bdb717c8f464f824257527ff.diff L

[clang] Revert "[clang][analyzer] Fix a nullptr dereference when `-ftime-trace` is used" (PR #139936)

2025-05-14 Thread Qinkun Bao via cfe-commits
https://github.com/qinkunbao closed https://github.com/llvm/llvm-project/pull/139936 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Revert "[lit][clang] Avoid realpath on Windows due to MAX_PATH limitations" (PR #139739)

2025-05-14 Thread Saleem Abdulrasool via cfe-commits
compnerd wrote: The patch is meant to support the following pattern (which IMO is actually the proper way to deal with the path canonicalisation): ```cmd subst X: %UserProfile%\SourceCache X: cmake -B X:\b -G Ninja -S llvm-project\llvm ninja -C \b ``` Everything is being built in `S:`, there i

[clang] [WIP][analyzer] Refactor `ExplodedGraph::trim()` (PR #139939)

2025-05-14 Thread Donát Nagy via cfe-commits
https://github.com/NagyDonat created https://github.com/llvm/llvm-project/pull/139939 ...because its implementation was using a complicated two-pass graph traversal while in fact one pass is sufficient for performing that trimming operation. Note that this commit changes the interface of `trim

[clang] [WIP][analyzer] Refactor `ExplodedGraph::trim()` (PR #139939)

2025-05-14 Thread Donát Nagy via cfe-commits
NagyDonat wrote: This is the cleanup of `ExplodedGraph::trim()` that I promised at https://github.com/llvm/llvm-project/commit/31e981ca1dc323c8a32012cb60a0a8fe3985db1a. This significantly simplifies the algorithm and should be equivalent in a theoretical sense, but unfortunately it changes the

[clang] [Preprocessor] Do not expand macros if the input is already preprocessed (PR #137665)

2025-05-14 Thread Juan Manuel Martinez Caamaño via cfe-commits
https://github.com/jmmartinez edited https://github.com/llvm/llvm-project/pull/137665 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libcxx] [llvm] [Clang] Add warnings when mixing different charN_t types (PR #138708)

2025-05-14 Thread via cfe-commits
@@ -0,0 +1,155 @@ +// RUN: %clang_cc1 -verify -fsyntax-only -std=c++20 -Wconversion %s + +void c8(char8_t); +void c16(char16_t); +void c32(char32_t); + +void test(char8_t u8, char16_t u16, char32_t u32) { +c8(u8); +c8(u16); // expected-warning {{implicit conversion from 'c

[clang] Implement src:*=sanitize for UBSan (PR #139772)

2025-05-14 Thread Qinkun Bao via cfe-commits
https://github.com/qinkunbao updated https://github.com/llvm/llvm-project/pull/139772 >From 99dfb74ada8922218afcca173c1fc3b69315fc4f Mon Sep 17 00:00:00 2001 From: Qinkun Bao Date: Tue, 13 May 2025 17:16:53 + Subject: [PATCH] Implement src:*=sanitize for UBSan --- clang/lib/Basic/NoSaniti

[clang] [clang-tools-extra] [Clang] Add builtins that deduplicate and sort types (PR #106730)

2025-05-14 Thread Ilya Biryukov via cfe-commits
@@ -1666,6 +1685,21 @@ namespace { return inherited::TransformTemplateArgument(Input, Output, Uneval); } +using TreeTransform::TransformTemplateSpecializationType; +QualType +TransformTemplateSpecializationType(TypeLocBuilder &TLB, +

[clang] [llvm] [DebugInfo] Place local ODR-uniqued types in decl DISubprograms (PR #119001)

2025-05-14 Thread Vladislav Dzhidzhoev via cfe-commits
https://github.com/dzhidzhoev edited https://github.com/llvm/llvm-project/pull/119001 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Add macro to suppress -Wunnecessary-virtual-specifier (PR #139614)

2025-05-14 Thread Devon Loehr via cfe-commits
https://github.com/DKLoehr updated https://github.com/llvm/llvm-project/pull/139614 Rate limit · GitHub body { background-color: #f6f8fa; color: #24292e; font-family: -apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,Arial,sans-s

[clang] [llvm] Add macro to suppress -Wunnecessary-virtual-specifier (PR #139614)

2025-05-14 Thread Devon Loehr via cfe-commits
@@ -710,4 +710,17 @@ void AnnotateIgnoreWritesEnd(const char *file, int line); #define LLVM_PREFERRED_TYPE(T) #endif +/// \macro LLVM_VIRTUAL_ANCHOR_FUNCTION +/// This macro is used to adhere to LLVM's policy that each class with a vtable +/// must have at least one out-of-lin

[clang] [clang-tools-extra] [lldb] [clang] Remove intrusive reference count from `DiagnosticOptions` (PR #139584)

2025-05-14 Thread Jan Svoboda via cfe-commits
https://github.com/jansvoboda11 updated https://github.com/llvm/llvm-project/pull/139584 Rate limit · GitHub body { background-color: #f6f8fa; color: #24292e; font-family: -apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,Arial,s

[clang] Implement src:*=sanitize for UBSan (PR #139772)

2025-05-14 Thread Qinkun Bao via cfe-commits
https://github.com/qinkunbao edited https://github.com/llvm/llvm-project/pull/139772 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Constant-evaluate format strings as last resort (PR #135864)

2025-05-14 Thread via cfe-commits
apple-fcloutier wrote: @AaronBallman, @cor3ntin, what do you think? Split this in two, [like Oliver suggests](https://github.com/llvm/llvm-project/pull/135864#issuecomment-2879466843)? https://github.com/llvm/llvm-project/pull/135864 ___ cfe-commits m

[clang] [llvm] [DebugInfo] Place local ODR-uniqued types in decl DISubprograms (PR #119001)

2025-05-14 Thread Vladislav Dzhidzhoev via cfe-commits
@@ -3901,6 +3903,57 @@ CGDebugInfo::getOrCreateLimitedType(const RecordType *Ty) { return Res; } +llvm::DIScope *CGDebugInfo::PickCompositeTypeScope(llvm::DIScope *S, + StringRef Identifier) { + using llvm::DISubprogram; +

[clang] [llvm] [DebugInfo] Place local ODR-uniqued types in decl DISubprograms (PR #119001)

2025-05-14 Thread Vladislav Dzhidzhoev via cfe-commits
https://github.com/dzhidzhoev edited https://github.com/llvm/llvm-project/pull/119001 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [Clang] Add builtins that deduplicate and sort types (PR #106730)

2025-05-14 Thread Matheus Izvekov via cfe-commits
@@ -1666,6 +1685,21 @@ namespace { return inherited::TransformTemplateArgument(Input, Output, Uneval); } +using TreeTransform::TransformTemplateSpecializationType; +QualType +TransformTemplateSpecializationType(TypeLocBuilder &TLB, +

[clang] [llvm] [clang][IR] Overload @llvm.thread.pointer to support non-AS0 targets (PR #132489)

2025-05-14 Thread Jessica Clarke via cfe-commits
https://github.com/jrtc27 updated https://github.com/llvm/llvm-project/pull/132489 >From 778502b697d7fe547e827f7d7394a7013a1c9ffb Mon Sep 17 00:00:00 2001 From: Jessica Clarke Date: Fri, 21 Mar 2025 23:15:23 + Subject: [PATCH 1/3] [clang][IR] Overload @llvm.thread.pointer to support non-AS

[clang] [clang] Compound Literal Statement Constant Expression Assertion Fix (PR #139479)

2025-05-14 Thread via cfe-commits
https://github.com/Mr-Anyone updated https://github.com/llvm/llvm-project/pull/139479 >From 86029ca424ddee771b95182b53d5bbdfd7fd049d Mon Sep 17 00:00:00 2001 From: Vincent Date: Sun, 11 May 2025 19:01:34 -0400 Subject: [PATCH 1/3] [clang] Compound Literal Statement Constant Expression Assertio

[clang] [llvm] [clang][IR] Overload @llvm.thread.pointer to support non-AS0 targets (PR #132489)

2025-05-14 Thread Eli Friedman via cfe-commits
https://github.com/efriedma-quic commented: Please update LangRef with the new overload and verifier rule. https://github.com/llvm/llvm-project/pull/132489 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/l

[clang] [llvm] [clang][IR] Overload @llvm.thread.pointer to support non-AS0 targets (PR #132489)

2025-05-14 Thread Jessica Clarke via cfe-commits
https://github.com/jrtc27 updated https://github.com/llvm/llvm-project/pull/132489 >From 778502b697d7fe547e827f7d7394a7013a1c9ffb Mon Sep 17 00:00:00 2001 From: Jessica Clarke Date: Fri, 21 Mar 2025 23:15:23 + Subject: [PATCH 1/2] [clang][IR] Overload @llvm.thread.pointer to support non-AS

[clang] [llvm] [clang][IR] Overload @llvm.thread.pointer to support non-AS0 targets (PR #132489)

2025-05-14 Thread Jessica Clarke via cfe-commits
jrtc27 wrote: > I'm mostly concerned about the case where the lowered node has the wrong > type. For example, AArch64TargetLowering::LowerINTRINSIC_WO_CHAIN always > creates a value with the pointer width of addrspace 0, but address spaces > exist which don't have the native pointer width (arm

[clang] [clang] Compound Literal Statement Constant Expression Assertion Fix (PR #139479)

2025-05-14 Thread via cfe-commits
@@ -7241,10 +7241,21 @@ Sema::BuildCompoundLiteralExpr(SourceLocation LParenLoc, TypeSourceInfo *TInfo, ? VK_PRValue : VK_LValue; + // C99 6.5.2.5 + // "If the compound literal occurs outside the body of a function, the + // initializer list shall con

[clang] [llvm] [llvm][DebugInfo][clang] Finalize all declaration subprograms in DIBuilder::finalize() (PR #139914)

2025-05-14 Thread Vladislav Dzhidzhoev via cfe-commits
https://github.com/dzhidzhoev edited https://github.com/llvm/llvm-project/pull/139914 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [llvm][DebugInfo][clang] Finalize all declaration subprograms in DIBuilder::finalize() (PR #139914)

2025-05-14 Thread Vladislav Dzhidzhoev via cfe-commits
https://github.com/dzhidzhoev edited https://github.com/llvm/llvm-project/pull/139914 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [WIP][analyzer] Refactor `ExplodedGraph::trim()` (PR #139939)

2025-05-14 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff HEAD~1 HEAD --extensions cpp -- clang/lib/StaticAnalyzer/Core/BugReporter.cpp clang/

[clang] [sanitizer][NFCI] Add 'SanitizerAnnotateDebugInfo' (PR #139965)

2025-05-14 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang @llvm/pr-subscribers-clang-codegen Author: Thurston Dang (thurstond) Changes This generalizes the debug info annotation code from https://github.com/llvm/llvm-project/pull/139149 and moves it into a helper function, SanitizerAnnotateDebugInfo().

[clang] [llvm] [HLSL] Add resource constructor with implicit binding for global resources (PR #138976)

2025-05-14 Thread Justin Bogner via cfe-commits
https://github.com/bogner approved this pull request. https://github.com/llvm/llvm-project/pull/138976 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL] Add resource constructor with implicit binding for global resources (PR #138976)

2025-05-14 Thread Justin Bogner via cfe-commits
@@ -3296,27 +3312,42 @@ static bool initVarDeclWithCtor(Sema &S, VarDecl *VD, return true; } -static bool initGlobalResourceDecl(Sema &S, VarDecl *VD) { +bool SemaHLSL::initGlobalResourceDecl(VarDecl *VD) { + std::optional RegisterSlot; + uint32_t SpaceNo = 0; HLSLResou

[clang] [llvm] [SPIRV] Add PreLegalizer instCombine for `faceforward` (PR #139959)

2025-05-14 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm edited https://github.com/llvm/llvm-project/pull/139959 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [SPIRV] Add PreLegalizer instCombine for `faceforward` (PR #139959)

2025-05-14 Thread Matt Arsenault via cfe-commits
@@ -127,11 +127,7 @@ template constexpr vector lit_impl(T NDotL, T NDotH, T M) { } template constexpr T faceforward_impl(T N, T I, T Ng) { -#if (__has_builtin(__builtin_spirv_faceforward)) - return __builtin_spirv_faceforward(N, I, Ng); -#else return select(dot(I, Ng) <

[clang] [llvm] [SPIRV] Add PreLegalizer instCombine for `faceforward` (PR #139959)

2025-05-14 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm commented: Description mentions instcombine but this has nothing to do with instcombine https://github.com/llvm/llvm-project/pull/139959 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/m

[clang] [sanitizer][NFCI] Add 'SanitizerAnnotateDebugInfo' (PR #139965)

2025-05-14 Thread Thurston Dang via cfe-commits
https://github.com/thurstond created https://github.com/llvm/llvm-project/pull/139965 This generalizes the debug info annotation code from https://github.com/llvm/llvm-project/pull/139149 and moves it into a helper function, SanitizerAnnotateDebugInfo(). Future work can use 'ApplyDebugLocatio

[clang] [cfi] Enable -fsanitize-annotate-debug-info functionality for CFI checks (PR #139809)

2025-05-14 Thread Thurston Dang via cfe-commits
@@ -1217,6 +1217,35 @@ void CodeGenFunction::EmitBoundsCheck(const Expr *E, const Expr *Base, EmitBoundsCheckImpl(E, Bound, Index, IndexType, IndexedType, Accessed); } +llvm::DILocation *CodeGenFunction::SanitizerAnnotateDebugInfo( thurstond wrote: Spun of

[clang] [sanitizer][NFCI] Add 'SanitizerAnnotateDebugInfo' (PR #139965)

2025-05-14 Thread Florian Mayer via cfe-commits
https://github.com/fmayer approved this pull request. https://github.com/llvm/llvm-project/pull/139965 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] 960afcc - [clang][modules] Timestamp-less validation API (#138983)

2025-05-14 Thread via cfe-commits
Author: Jan Svoboda Date: 2025-05-14T14:31:23-07:00 New Revision: 960afcc90e8fb75b725ed331f4bc60eb2398d6e5 URL: https://github.com/llvm/llvm-project/commit/960afcc90e8fb75b725ed331f4bc60eb2398d6e5 DIFF: https://github.com/llvm/llvm-project/commit/960afcc90e8fb75b725ed331f4bc60eb2398d6e5.diff L

[clang] [clang-tools-extra] [clang][modules] Timestamp-less validation API (PR #138983)

2025-05-14 Thread Jan Svoboda via cfe-commits
https://github.com/jansvoboda11 closed https://github.com/llvm/llvm-project/pull/138983 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Update Sema Checking Diagnostics for builtins (PR #138429)

2025-05-14 Thread Justin Bogner via cfe-commits
https://github.com/bogner approved this pull request. https://github.com/llvm/llvm-project/pull/138429 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libcxx] [llvm] [Clang] Add warnings when mixing different charN_t types (PR #138708)

2025-05-14 Thread via cfe-commits
https://github.com/EricWF edited https://github.com/llvm/llvm-project/pull/138708 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libcxx] [llvm] [Clang] Add warnings when mixing different charN_t types (PR #138708)

2025-05-14 Thread via cfe-commits
@@ -34,6 +34,6 @@ int main(int, char**) { assert(from_next - from == 9); assert(to_next - to == 9); for (unsigned i = 0; i < 9; ++i) -assert(to[i] == from[i]); +assert(static_cast(to[i]) == static_cast(from[i])); EricWF wrote: Why are we casting

[clang] [libcxx] [llvm] [Clang] Add warnings when mixing different charN_t types (PR #138708)

2025-05-14 Thread via cfe-commits
@@ -618,7 +618,7 @@ template void utf8_to_utf16_in_error(const std::codecvt& cvt) { // UTF-8 string of 1-byte CP, 2-byte CP, 3-byte CP, 4-byte CP const unsigned char input[] = "b\u0448\uD700\U0010"; - const char16_t expected[] = {'b', 0x0448, 0xD700, 0xDBEA, 0xDEAA

[clang] [libcxx] [llvm] [Clang] Add warnings when mixing different charN_t types (PR #138708)

2025-05-14 Thread via cfe-commits
@@ -618,7 +618,7 @@ template void utf8_to_utf16_in_error(const std::codecvt& cvt) { // UTF-8 string of 1-byte CP, 2-byte CP, 3-byte CP, 4-byte CP const unsigned char input[] = "b\u0448\uD700\U0010"; - const char16_t expected[] = {'b', 0x0448, 0xD700, 0xDBEA, 0xDEAA

[clang] [libcxx] [llvm] [Clang] Add warnings when mixing different charN_t types (PR #138708)

2025-05-14 Thread via cfe-commits
@@ -484,7 +484,7 @@ template void utf8_to_utf16_in_ok(const std::codecvt& cvt) { // UTF-8 string of 1-byte CP, 2-byte CP, 3-byte CP and 4-byte CP const unsigned char input[] = "b\u0448\u\U0010"; - const char16_t expected[] = {'b', 0x0448, 0x, 0xDBEA, 0xDEAA

[clang] [libcxx] [llvm] [Clang] Add warnings when mixing different charN_t types (PR #138708)

2025-05-14 Thread via cfe-commits
@@ -123,7 +123,7 @@ _LIBCPP_HIDE_FROM_ABI constexpr void __encode(_OutIt& __out_it, char32_t __value _LIBCPP_ASSERT_UNCATEGORIZED(__is_scalar_value(__value), "an invalid unicode scalar value results in invalid UTF-16"); if (__value < 0x1) { -*__out_it++ = __value

[clang] [libcxx] [llvm] [Clang] Add warnings when mixing different charN_t types (PR #138708)

2025-05-14 Thread via cfe-commits
@@ -123,7 +123,7 @@ _LIBCPP_HIDE_FROM_ABI constexpr void __encode(_OutIt& __out_it, char32_t __value _LIBCPP_ASSERT_UNCATEGORIZED(__is_scalar_value(__value), "an invalid unicode scalar value results in invalid UTF-16"); if (__value < 0x1) { -*__out_it++ = __value

[clang] [libcxx] [llvm] [Clang] Add warnings when mixing different charN_t types (PR #138708)

2025-05-14 Thread via cfe-commits
https://github.com/EricWF commented: I don't mean to be difficult, but I'm always weary about removing test coverage, and I'm not yet convinced that the tests didn't intend to test these sketchy conversions. The way it uses the typedefs elsewhere in the same tests, while pinning some of the t

[clang] [Cygwin] Export global symbols, template instantiations, RTTI and VTable are exported correctly (PR #138773)

2025-05-14 Thread Tomohiro Kashiwada via cfe-commits
https://github.com/kikairoya closed https://github.com/llvm/llvm-project/pull/138773 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [CMake] Add a linker test for -Bsymbolic-functions to AddLLVM (PR #79539)

2025-05-14 Thread Brad Smith via cfe-commits
brad0 wrote: @rorth Can you please check this on Solaris? https://github.com/llvm/llvm-project/pull/79539 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 86ba681 - [Clang][Sema] Disable checking invalid template id in initializer of primary variable template `std::format_kind` with libstdc++ (#139560)

2025-05-14 Thread via cfe-commits
Author: Yanzuo Liu Date: 2025-05-14T10:25:01+02:00 New Revision: 86ba681e286d0a377830d2cbbc5e58bb5fad442c URL: https://github.com/llvm/llvm-project/commit/86ba681e286d0a377830d2cbbc5e58bb5fad442c DIFF: https://github.com/llvm/llvm-project/commit/86ba681e286d0a377830d2cbbc5e58bb5fad442c.diff LO

[clang] [Clang][Sema] Disable checking invalid template id in initializer of primary variable template `std::format_kind` with libstdc++ (PR #139560)

2025-05-14 Thread via cfe-commits
https://github.com/cor3ntin closed https://github.com/llvm/llvm-project/pull/139560 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [Clang] Add builtins that deduplicate and sort types (PR #106730)

2025-05-14 Thread Younan Zhang via cfe-commits
@@ -5054,95 +5089,128 @@ bool TreeTransform::TransformTemplateArguments( } if (In.getArgument().isPackExpansion()) { - // We have a pack expansion, for which we will be substituting into - // the pattern. - SourceLocation Ellipsis; - UnsignedOrNone

[clang] [clang-tools-extra] [Clang] Add builtins that deduplicate and sort types (PR #106730)

2025-05-14 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 deleted https://github.com/llvm/llvm-project/pull/106730 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][Sema] Diagnose exceptions only in non-dependent context in discarded `try/catch/throw` blocks (PR #139859)

2025-05-14 Thread Rajveer Singh Bharadwaj via cfe-commits
https://github.com/Rajveer100 created https://github.com/llvm/llvm-project/pull/139859 Resolves #138939 When enabling `--fno-exceptions` flag, discarded statements containing `try/catch/throw` in an independent context can be avoided from being rejected. >From 552e394608f8c8d70ddef70a32dd9bd4

[clang] [clang][Sema] Diagnose exceptions only in non-dependent context in discarded `try/catch/throw` blocks (PR #139859)

2025-05-14 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Rajveer Singh Bharadwaj (Rajveer100) Changes Resolves #138939 When enabling `--fno-exceptions` flag, discarded statements containing `try/catch/throw` in an independent context can be avoided from being rejected. --- Full diff: https://g

[clang] [clang][Sema] Diagnose exceptions only in non-dependent context in discarded `try/catch/throw` blocks (PR #139859)

2025-05-14 Thread Rajveer Singh Bharadwaj via cfe-commits
Rajveer100 wrote: @erichkeane As expected the following case is being accepted, which shouldn't happen, let me know what you recommend to diagnose this: ```c++ template void foo() { try { } catch (...) { } throw 1; } void bar2() { foo(); } ``` https://github.com/llvm/llvm-project/pul

  1   2   3   4   5   >