[clang] [llvm] [LoongArch] Support LA V1.1 feature ld-seq-sa that don't generate dbar 0x700. (PR #116762)

2024-11-19 Thread via cfe-commits
https://github.com/tangaac created https://github.com/llvm/llvm-project/pull/116762 Two options for clang -mld-seq-sa: Do not generate load-load barrier instructions (dbar 0x700) -mno-ld-seq-sa: Generate load-load barrier instructions (dbar 0x700) The default is -mno-ld

[clang] [TargetVersion] Only enable on RISC-V and AArch64 (PR #115991)

2024-11-19 Thread Piyou Chen via cfe-commits
https://github.com/BeMg updated https://github.com/llvm/llvm-project/pull/115991 >From 28f7a2adc055ec6f30790e1e9535c71241a08e29 Mon Sep 17 00:00:00 2001 From: Piyou Chen Date: Tue, 12 Nov 2024 20:56:47 -0800 Subject: [PATCH 1/7] [TargetVersion] Only enable on RISC-V and AArch64 --- clang/inclu

[clang] [Clang] Fix typo 'dereferencable' to 'dereferenceable' (PR #116761)

2024-11-19 Thread via cfe-commits
github-actions[bot] wrote: Thank you for submitting a Pull Request (PR) to the LLVM Project! This PR will be automatically labeled and the relevant teams will be notified. If you wish to, you can add reviewers by using the "Reviewers" section on this page. If this is not working for you, it

[clang] [clang] Improve diagnostic on [[nodiscard]] attribute (PR #112521)

2024-11-19 Thread via cfe-commits
https://github.com/Sirraide updated https://github.com/llvm/llvm-project/pull/112521 >From 59f7dbdd8eed456b76e93f6260bf0e361242e9fd Mon Sep 17 00:00:00 2001 From: Yihe Li Date: Wed, 16 Oct 2024 18:53:04 +0800 Subject: [PATCH 1/5] [clang] Improve diagnostic on [[nodiscard]] attribute --- clang

[clang] [clang] Improve diagnostic on [[nodiscard]] attribute (PR #112521)

2024-11-19 Thread via cfe-commits
https://github.com/Sirraide approved this pull request. LGTM Thanks for contributing! https://github.com/llvm/llvm-project/pull/112521 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Improve diagnostic on [[nodiscard]] attribute (PR #112521)

2024-11-19 Thread via cfe-commits
https://github.com/Sirraide closed https://github.com/llvm/llvm-project/pull/112521 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-repl] Improve flags responsible for generating shared wasm binaries (PR #116735)

2024-11-19 Thread Vassil Vassilev via cfe-commits
https://github.com/vgvassilev closed https://github.com/llvm/llvm-project/pull/116735 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [analyzer] Handle [[assume(cond)]] as __builtin_assume(cond) (PR #116462)

2024-11-19 Thread Balazs Benics via cfe-commits
steakhal wrote: I simplified your implementation, and also identified a shortcoming of the `getSpecificAttr` that it didn't work with const attributes. I'll submit a fix for it separately to this PR. The implementation looks pretty but there is a catch. And this is unfortunately a blocker iss

[clang] 752dbd6 - [clang-repl] Improve flags responsible for generating shared wasm binaries (#116735)

2024-11-19 Thread via cfe-commits
Author: Anutosh Bhat Date: 2024-11-19T09:07:40+01:00 New Revision: 752dbd6112affa418e33910ac08bf9921f9c270b URL: https://github.com/llvm/llvm-project/commit/752dbd6112affa418e33910ac08bf9921f9c270b DIFF: https://github.com/llvm/llvm-project/commit/752dbd6112affa418e33910ac08bf9921f9c270b.diff

[clang] [llvm] [clang] Implement lifetime analysis for lifetime_capture_by(X) (PR #115921)

2024-11-19 Thread Utkarsh Saxena via cfe-commits
@@ -0,0 +1,220 @@ +// RUN: %clang_cc1 --std=c++20 -fsyntax-only -Wdangling -Wdangling-field -Wreturn-stack-address -verify %s + +#include "Inputs/lifetime-analysis.h" usx95 wrote: > > I think it would be much more readable if we would have a namespace per use >

[clang] [llvm] [RISCV] Support `svukte` extension (PR #115657)

2024-11-19 Thread Craig Topper via cfe-commits
@@ -330,6 +329,9 @@ The primary goal of experimental support is to assist in the process of ratifica ``experimental-smctr``, ``experimental-ssctr`` LLVM implements the `1.0-rc3 specification `__.

[clang] [llvm] [RISCV] Support `svukte` extension (PR #115657)

2024-11-19 Thread Craig Topper via cfe-commits
https://github.com/topperc edited https://github.com/llvm/llvm-project/pull/115657 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [LoongArch] Support LA V1.1 feature ld-seq-sa that don't generate dbar 0x700. (PR #116762)

2024-11-19 Thread via cfe-commits
https://github.com/tangaac updated https://github.com/llvm/llvm-project/pull/116762 >From eef0e50043c45ea6ca22af266bcc833ce9bbaf0d Mon Sep 17 00:00:00 2001 From: tangaac Date: Fri, 1 Nov 2024 17:28:38 +0800 Subject: [PATCH] [LoongArch] Support feature ld-seq-sa that don't generate dbar 0x700.

[clang] [Clang] Preserve partially substituted pack indexing type/expressions (PR #116782)

2024-11-19 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 created https://github.com/llvm/llvm-project/pull/116782 Substituting into pack indexing types/expressions can still result in unexpanded types/expressions, such as PackIndexingType or PackIndexingExpr. To handle these cases correctly, we should defer the pack size c

[clang] [Clang] Consider preferred_type in bitfield warnings (#116760) (PR #116784)

2024-11-19 Thread Oliver Hunt via cfe-commits
https://github.com/ojhunt created https://github.com/llvm/llvm-project/pull/116784 Very simply extends the bitfield sema checks for assignment to fields with a preferred type specified to consider the preferred type if the decl storage type is not explicitly an enum type. This does mean that

[clang] [Clang] Consider preferred_type in bitfield warnings (#116760) (PR #116784)

2024-11-19 Thread Oliver Hunt via cfe-commits
https://github.com/ojhunt closed https://github.com/llvm/llvm-project/pull/116784 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Consider preferred_type in bitfield warnings (#116760) (PR #116785)

2024-11-19 Thread Oliver Hunt via cfe-commits
https://github.com/ojhunt created https://github.com/llvm/llvm-project/pull/116785 Very simply extends the bitfield sema checks for assignment to fields with a preferred type specified to consider the preferred type if the decl storage type is not explicitly an enum type. This does mean that

[clang] [Clang] Consider preferred_type in bitfield warnings (#116760) (PR #116785)

2024-11-19 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Oliver Hunt (ojhunt) Changes Very simply extends the bitfield sema checks for assignment to fields with a preferred type specified to consider the preferred type if the decl storage type is not explicitly an enum type. This does mean tha

[clang] [Clang] Consider preferred_type in bitfield warnings (#116760) (PR #116785)

2024-11-19 Thread Oliver Hunt via cfe-commits
https://github.com/ojhunt updated https://github.com/llvm/llvm-project/pull/116785 >From 5f260726253e78a00d2dff02c22837ce02b49075 Mon Sep 17 00:00:00 2001 From: Oliver Hunt Date: Tue, 19 Nov 2024 11:55:11 +0100 Subject: [PATCH] [Clang] Consider preferred_type in bitfield warnings (#116760) Ve

[clang] [Clang] Preserve partially substituted pack indexing type/expressions (PR #116782)

2024-11-19 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 edited https://github.com/llvm/llvm-project/pull/116782 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [LoongArch] Support LA V1.1 feature that div.w[u] and mod.w[u] instructions with inputs not signed-extended. (PR #116764)

2024-11-19 Thread via cfe-commits
@@ -118,6 +118,12 @@ def FeatureLAM_BH "Support amswap[_db].{b/h} and amadd[_db].{b/h} instructions.">; def HasLAM_BH : Predicate<"Subtarget->hasLAM_BH()">; +// Assume div.w[u] and mod.w[u] can handle inputs that are not sign-extended. +def FeatureDiv3

[clang] [llvm] [LoongArch] Support LA V1.1 feature that div.w[u] and mod.w[u] instructions with inputs not signed-extended. (PR #116764)

2024-11-19 Thread via cfe-commits
@@ -121,7 +121,7 @@ define i32 @sdiv_i32(i32 %a, i32 %b) { ; LA64: # %bb.0: # %entry ; LA64-NEXT:addi.w $a1, $a1, 0 ; LA64-NEXT:addi.w $a0, $a0, 0 -; LA64-NEXT:div.d $a0, $a0, $a1 +; LA64-NEXT:div.w $a0, $a0, $a1 heiher wrote: These cases

[clang] [Driver] Remove ignored Flag form of -fauto-profile/-fprofile-sample-use (PR #113528)

2024-11-19 Thread Haohai Wen via cfe-commits
https://github.com/HaohaiWen approved this pull request. https://github.com/llvm/llvm-project/pull/113528 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 91c1699 - [clang] [NFC] Merge conditions (#116612)

2024-11-19 Thread via cfe-commits
Author: Boaz Brickner Date: 2024-11-19T09:57:00+01:00 New Revision: 91c1699943a7f41c337d44b965c63bb6fc96de16 URL: https://github.com/llvm/llvm-project/commit/91c1699943a7f41c337d44b965c63bb6fc96de16 DIFF: https://github.com/llvm/llvm-project/commit/91c1699943a7f41c337d44b965c63bb6fc96de16.diff

[clang] [clang] [NFC] Merge conditions (PR #116612)

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

[clang] [analyzer][Solver] Early return if sym is concrete on assuming (PR #115579)

2024-11-19 Thread Balazs Benics via cfe-commits
steakhal wrote: > > I'm not sure I see why. The logs I linked in the revert only showed a > > single test failure. The new test we added in this PR. This suggests close > > correlations. Maybe the content of the "constraints" map in the State is > > dumped in a non-deterministic order? And we

[clang] [analyzer][Solver] Early return if sym is concrete on assuming (PR #115579)

2024-11-19 Thread Balazs Benics via cfe-commits
steakhal wrote: > > @danix800 Could you please have a look at the failed test, such that we > > could reapply this PR? I reverted this soon after I realized the broken > > test is from this PR. > > The test randomly fails for unknown reason, on VS2019~2022, after > [1c154bd](https://github.co

[clang] [Clang] Consider preferred_type in bitfield warnings (#116760) (PR #116784)

2024-11-19 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Oliver Hunt (ojhunt) Changes Very simply extends the bitfield sema checks for assignment to fields with a preferred type specified to consider the preferred type if the decl storage type is not explicitly an enum type. This does mean tha

[clang] [clang] Generate note on declaration for nodiscard-related attributes (PR #112289)

2024-11-19 Thread Yihe Li via cfe-commits
https://github.com/Mick235711 closed https://github.com/llvm/llvm-project/pull/112289 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][Clang][AArch64]Refactor implementation of Neon vectors MFloat8… (PR #114804)

2024-11-19 Thread Paul Walker via cfe-commits
paulwalker-arm wrote: Thanks @CarolineConcatto this is structurally more what I had in mind. The non-fp8 neon types make use of general vector support within clang but the fp8 based types are completely target specific and so I'd rather keep their spread within common code to a minimum. Neon

[libclc] [libclc] Move several integer functions to CLC library (PR #116786)

2024-11-19 Thread Fraser Cormack via cfe-commits
https://github.com/frasercrmck created https://github.com/llvm/llvm-project/pull/116786 This commit moves over the OpenCL clz, hadd, mad24, mad_hi, mul24, mul_hi, popcount, rhadd, and upsample builtins to the CLC library. There are no changes to any target's CLC libraries. The OpenCL mad_hi b

[clang-tools-extra] b3e2b1a - [clang-tidy][NFC] fix typo in ExceptionAnalyzer; `replace count()>0` with `contains` (#116635)

2024-11-19 Thread via cfe-commits
Author: Congcong Cai Date: 2024-11-19T18:11:41+08:00 New Revision: b3e2b1a7eb258a7c9c55691d08342eface083499 URL: https://github.com/llvm/llvm-project/commit/b3e2b1a7eb258a7c9c55691d08342eface083499 DIFF: https://github.com/llvm/llvm-project/commit/b3e2b1a7eb258a7c9c55691d08342eface083499.diff

[clang] [ARM] Fix NaN behaviour for MVE compare intrinsics (PR #116371)

2024-11-19 Thread Oliver Stannard via cfe-commits
https://github.com/ostannard updated https://github.com/llvm/llvm-project/pull/116371 >From 6bfe667f87da2551e7080af3caede272378e1e4d Mon Sep 17 00:00:00 2001 From: Oliver Stannard Date: Thu, 14 Nov 2024 18:16:12 + Subject: [PATCH 1/2] [ARM] Fix NaN behaviour for MVE compare intrinsics The

[clang] [ARM] Fix NaN behaviour for MVE compare intrinsics (PR #116371)

2024-11-19 Thread Oliver Stannard via cfe-commits
@@ -118,6 +118,8 @@ def fcmp_gt: IRBuilder<"CreateFCmpOGT">; def fcmp_ge: IRBuilder<"CreateFCmpOGE">; def fcmp_lt: IRBuilder<"CreateFCmpOLT">; def fcmp_le: IRBuilder<"CreateFCmpOLE">; ostannard wrote: Done https://github.com/llvm/llvm-project/pull/116371

[clang] [clang-repl] Use default visibility for symbols while building CompilerInstance against emscripten (PR #116779)

2024-11-19 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Anutosh Bhat (anutosh491) Changes When running clang-repl in the browser we end up having something like the following ` "" -cc1 -triple wasm32-unknown-emscripten .. -main-file-name "<<< inputs >>>" -fvisibility=hidden -o "

[clang-tools-extra] [clang-tidy] Improved readability redundant casting with enums (PR #111424)

2024-11-19 Thread Piotr Zegar via cfe-commits
=?utf-8?q?Félix-Antoine?= Constantin, =?utf-8?q?Félix-Antoine?= Constantin, =?utf-8?q?Félix-Antoine?= Constantin Message-ID: In-Reply-To: https://github.com/PiotrZSL requested changes to this pull request. Please implement this change under separate option like: `AllowEnumsBeRecognizedAs Alias

[clang] [flang] [clang][driver] When -fveclib=ArmPL flag is in use, always link against libamath (PR #116432)

2024-11-19 Thread Paul Walker via cfe-commits
@@ -490,6 +490,16 @@ void tools::AddLinkerInputs(const ToolChain &TC, const InputInfoList &Inputs, else A.renderAsInput(Args, CmdArgs); } + if (const Arg *A = Args.getLastArg(options::OPT_fveclib)) { +if (A->getNumValues() == 1) { + StringRef V = A->getVa

[clang] [analyzer][Solver] Early return if sym is concrete on assuming (PR #115579)

2024-11-19 Thread Ding Fei via cfe-commits
danix800 wrote: > I'm not sure I see why. The logs I linked in the revert only showed a single > test failure. The new test we added in this PR. This suggests close > correlations. Maybe the content of the "constraints" map in the State is > dumped in a non-deterministic order? And we just hap

[clang] [lld] [llvm] [X86][MC,LLD][NFC] Rename R_X86_64_REX2_GOTPCRELX (PR #116737)

2024-11-19 Thread Shengchen Kan via cfe-commits
https://github.com/KanRobert approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/116737 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy][NFC] fix typo in ExceptionAnalyzer; `replace count()>0` with `contains` (PR #116635)

2024-11-19 Thread Congcong Cai via cfe-commits
@@ -449,7 +449,8 @@ void ExceptionAnalyzer::ExceptionInfo::reevaluateBehaviour() { ExceptionAnalyzer::ExceptionInfo ExceptionAnalyzer::throwsException( const FunctionDecl *Func, const ExceptionInfo::Throwables &Caught, llvm::SmallSet &CallStack) { - if (!Func || CallS

[clang-tools-extra] [clang-tidy][NFC] fix typo in ExceptionAnalyzer; `replace count()>0` with `contains` (PR #116635)

2024-11-19 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 closed https://github.com/llvm/llvm-project/pull/116635 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Create a check for signed and unsigned integers comparison (PR #113144)

2024-11-19 Thread via cfe-commits
qt-tatiana wrote: Ping :) https://github.com/llvm/llvm-project/pull/113144 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 51ad290 - [Clang] Improve diagnostic on `[[nodiscard]]` attribute (#112521)

2024-11-19 Thread via cfe-commits
Author: Yihe Li Date: 2024-11-19T11:04:53+01:00 New Revision: 51ad2901ca54a01a72db71622b116eb27ea6dcf2 URL: https://github.com/llvm/llvm-project/commit/51ad2901ca54a01a72db71622b116eb27ea6dcf2 DIFF: https://github.com/llvm/llvm-project/commit/51ad2901ca54a01a72db71622b116eb27ea6dcf2.diff LOG:

[clang-tools-extra] [clang-tidy] Improved readability redundant casting with enums (PR #111424)

2024-11-19 Thread Piotr Zegar via cfe-commits
=?utf-8?q?Félix-Antoine?= Constantin, =?utf-8?q?Félix-Antoine?= Constantin, =?utf-8?q?Félix-Antoine?= Constantin Message-ID: In-Reply-To: @@ -221,3 +221,16 @@ void testRedundantDependentNTTPCasting() { // CHECK-MESSAGES: :[[@LINE-4]]:25: note: source type originates from ref

[clang] [clang-repl] Use default visibility for symbols while building CompilerInstance against emscripten (PR #116779)

2024-11-19 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 7e85cb8a8a9de57ed10635b843662148a87b17e5 616ebd6b6487eeaa302e6d33de3a371e6c9843f5 --e

[clang-tools-extra] [clang-tidy] Improved readability redundant casting with enums (PR #111424)

2024-11-19 Thread Piotr Zegar via cfe-commits
=?utf-8?q?Félix-Antoine?= Constantin, =?utf-8?q?Félix-Antoine?= Constantin, =?utf-8?q?Félix-Antoine?= Constantin Message-ID: In-Reply-To: https://github.com/PiotrZSL edited https://github.com/llvm/llvm-project/pull/111424 ___ cfe-commits mailing list

[clang] b2ec416 - [ARM] Fix NaN behaviour for MVE compare intrinsics (#116371)

2024-11-19 Thread via cfe-commits
Author: Oliver Stannard Date: 2024-11-19T10:23:14Z New Revision: b2ec416aa5bcd89c4bc295163d60e5a2ecb99212 URL: https://github.com/llvm/llvm-project/commit/b2ec416aa5bcd89c4bc295163d60e5a2ecb99212 DIFF: https://github.com/llvm/llvm-project/commit/b2ec416aa5bcd89c4bc295163d60e5a2ecb99212.diff LO

[clang] [ARM] Fix NaN behaviour for MVE compare intrinsics (PR #116371)

2024-11-19 Thread Oliver Stannard via cfe-commits
https://github.com/ostannard closed https://github.com/llvm/llvm-project/pull/116371 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix the post-filtering heuristic for GSLPointer. (PR #114044)

2024-11-19 Thread Haojian Wu via cfe-commits
https://github.com/hokein updated https://github.com/llvm/llvm-project/pull/114044 >From ac8f934144cfa657ae7ba0c8797fe058aa0a9c53 Mon Sep 17 00:00:00 2001 From: Haojian Wu Date: Fri, 1 Nov 2024 16:51:03 +0100 Subject: [PATCH 1/5] [clang] Fix the post-filtering heuristics for GSLPointer case.

[clang] [clang] Improve diagnostic on [[nodiscard]] attribute (PR #112521)

2024-11-19 Thread via cfe-commits
github-actions[bot] wrote: @Mick235711 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 bui

[clang] [clang] Fix the post-filtering heuristic for GSLPointer. (PR #114044)

2024-11-19 Thread Haojian Wu via cfe-commits
hokein wrote: > Just discover a new false positive: > > ``` > namespace std { > template > class [[gsl::Pointer]] Iterator2 { > public: > using reference = T&; > Iterator2() {} > reference operator*() const; > }; > } > > template > class AnySpan { > public: > AnySpan() {} > std::I

[clang] [Clang] add single quotes around __builtin_bit_cast (PR #116120)

2024-11-19 Thread via cfe-commits
@@ -12366,7 +12366,7 @@ def err_preserve_enum_value_not_const: Error< "__builtin_preserve_enum_value argument %0 not a constant">; Sirraide wrote: It would probably be nice if someone did a general cleanup pass on all the diagnostics TD files, because I jus

[clang] 6aa80f0 - [Clang] [NFC] Add single quotes around __builtin_bit_cast (#116120)

2024-11-19 Thread via cfe-commits
Author: Oleksandr T. Date: 2024-11-19T10:16:47+01:00 New Revision: 6aa80f00574826a0c2f2972a659517a9bf1efece URL: https://github.com/llvm/llvm-project/commit/6aa80f00574826a0c2f2972a659517a9bf1efece DIFF: https://github.com/llvm/llvm-project/commit/6aa80f00574826a0c2f2972a659517a9bf1efece.diff

[clang] [Clang] add single quotes around __builtin_bit_cast (PR #116120)

2024-11-19 Thread via cfe-commits
https://github.com/Sirraide closed https://github.com/llvm/llvm-project/pull/116120 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] constexpr built-in reduce mul function. (PR #116626)

2024-11-19 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon approved this pull request. LGTM, thanks! https://github.com/llvm/llvm-project/pull/116626 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Prevent Null Pointer Dereference in in sema::​isNormalAssignmentOperator() (PR #115880)

2024-11-19 Thread via cfe-commits
@@ -482,8 +482,8 @@ static bool isNormalAssignmentOperator(const FunctionDecl *FD) { if (RetT->isLValueReferenceType()) { ASTContext &Ctx = FD->getASTContext(); QualType LHST; - auto *MD = dyn_cast(FD); - if (MD && MD->isCXXInstanceMember()) + au

[clang] 4818dd3 - [HLSL] Rename resource's "h" member to "__handle". NFC (#116696)

2024-11-19 Thread via cfe-commits
Author: Justin Bogner Date: 2024-11-19T01:26:52-08:00 New Revision: 4818dd33d84fcf41c08419a9960cadd473d536a9 URL: https://github.com/llvm/llvm-project/commit/4818dd33d84fcf41c08419a9960cadd473d536a9 DIFF: https://github.com/llvm/llvm-project/commit/4818dd33d84fcf41c08419a9960cadd473d536a9.diff

[clang] [Clang] Prevent Null Pointer Dereference in in sema::​isNormalAssignmentOperator() (PR #115880)

2024-11-19 Thread via cfe-commits
https://github.com/Sirraide requested changes to this pull request. https://github.com/llvm/llvm-project/pull/115880 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Rename resource's "h" member to "__handle". NFC (PR #116696)

2024-11-19 Thread Justin Bogner via cfe-commits
https://github.com/bogner closed https://github.com/llvm/llvm-project/pull/116696 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Fix resource kind for RasterizerOrderedStructuredBuffer (PR #116700)

2024-11-19 Thread Justin Bogner via cfe-commits
@@ -480,8 +480,8 @@ void HLSLExternalSemaSource::defineHLSLTypesWithForwardDeclarations() { onCompletion(Decl, [this](CXXRecordDecl *Decl) { setupBufferType(Decl, *SemaPtr, ResourceClass::UAV, -ResourceKind::TypedBuffer, -/*IsROV=

[clang] [HLSL] Fix resource kind for RasterizerOrderedStructuredBuffer (PR #116700)

2024-11-19 Thread Justin Bogner via cfe-commits
@@ -547,9 +543,8 @@ void HLSLExternalSemaSource::defineHLSLTypesWithForwardDeclarations() { .addSimpleTemplateParams(*SemaPtr, {"element_type"}) .Record; onCompletion(Decl, [this](CXXRecordDecl *Decl) { -setupBufferType(Decl, *SemaPtr, ResourceC

[clang] 4bd982d - [HLSL] Fix resource kind for RasterizerOrderedStructuredBuffer (#116700)

2024-11-19 Thread via cfe-commits
Author: Justin Bogner Date: 2024-11-19T01:32:37-08:00 New Revision: 4bd982d528ac2b2cb73d9fe6e534db84cfc16aaf URL: https://github.com/llvm/llvm-project/commit/4bd982d528ac2b2cb73d9fe6e534db84cfc16aaf DIFF: https://github.com/llvm/llvm-project/commit/4bd982d528ac2b2cb73d9fe6e534db84cfc16aaf.diff

[clang] [Clang] avoid adding consteval condition as the last statement to preserve valid CFG (PR #116513)

2024-11-19 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/116513 >From 69689f6ba5ac1715cc1df6cf08b79bb4b8bbe107 Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Sun, 17 Nov 2024 01:34:42 +0200 Subject: [PATCH] [Clang] avoid adding consteval condition as the last statement

[clang] [Clang] skip warnings for constructors marked with the [[noreturn]] attribute (PR #115558)

2024-11-19 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/115558 >From f63263a1aa4873a63918649ea92352eb5cfe66eb Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Sat, 9 Nov 2024 00:41:13 +0200 Subject: [PATCH] [Clang] skip warnings for constructors marked with the [[noretu

[clang] Reland [Clang] skip default argument instantiation for non-defining friend declarations to meet [dcl.fct.default] p4 (PR #115487)

2024-11-19 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/115487 >From 5e24d212f797b5fa1b6da1526c807046373d3c21 Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Fri, 8 Nov 2024 16:13:17 +0200 Subject: [PATCH 1/2] [Clang] skip default argument instantiation for non-definin

[clang] [Clang] Fix name lookup for dependent bases (PR #114978)

2024-11-19 Thread Vladislav Belov via cfe-commits
https://github.com/vbe-sc updated https://github.com/llvm/llvm-project/pull/114978 >From d17588af72f845b758a03637c84752dde733200c Mon Sep 17 00:00:00 2001 From: vb-sc Date: Tue, 5 Nov 2024 15:46:57 +0300 Subject: [PATCH] [clang] Fix name lookup for dependent bases --- clang/docs/ReleaseNotes.

[clang] [Clang] eliminate shadowing warnings for parameters using deducing this (PR #114813)

2024-11-19 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/114813 >From 91ff2b4226110ea35c78f0f1b6ff89b4bec2c788 Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Mon, 4 Nov 2024 17:38:46 +0200 Subject: [PATCH 1/3] [Clang] eliminate shadowing warnings for parameters using d

[clang] [Clang] enhance error recovery with RecoveryExpr for trailing commas in call arguments (PR #114684)

2024-11-19 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/114684 >From d95d0fdb22ae2ad162f89cb211f313cea6c6474a Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Sat, 2 Nov 2024 23:54:35 +0200 Subject: [PATCH] [Clang] enhance error recovery with RecoveryExpr for trailing c

[clang] [Clang] Fix name lookup for dependent bases (PR #114978)

2024-11-19 Thread Vladislav Belov via cfe-commits
vbe-sc wrote: > Can you add a release note I added a release note as you asked https://github.com/llvm/llvm-project/pull/114978 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

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

2024-11-19 Thread Nathan Ridge via cfe-commits
@@ -130,23 +129,40 @@ getFunctionSourceAfterReplacements(const FunctionDecl *FD, return QualifiedFunc.takeError(); std::string TemplatePrefix; + auto AddToTemplatePrefixIfApplicable = [&](const Decl *D, bool append) { +const TemplateParameterList *Params = D->getDes

[clang] [Clang][Parser] Make 'T...[N]' within a function parameter a valid pack expansion prior to C++2c (PR #116332)

2024-11-19 Thread via cfe-commits
Sirraide wrote: > I am not sure we want to keep supporting the old syntax, even in older > language modes (notably, it isn't supported by other compilers and is at best > missleading), I think we should just remove it (maybe make it an error that can be downgraded to a warning for now and the

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

2024-11-19 Thread via cfe-commits
Author: Christian Kandeler Date: 2024-11-19T12:47:15+01:00 New Revision: 8a6a76b1e122536858531a8612cbbe6869803393 URL: https://github.com/llvm/llvm-project/commit/8a6a76b1e122536858531a8612cbbe6869803393 DIFF: https://github.com/llvm/llvm-project/commit/8a6a76b1e122536858531a8612cbbe6869803393.

[clang] [Clang] skip warnings for constructors marked with the [[noreturn]] attribute (PR #115558)

2024-11-19 Thread Aaron Ballman via cfe-commits
@@ -49,3 +49,15 @@ void check() { test_type(g); test_type(h); // expected-note {{instantiation}} } + +namespace GH63009 { +struct S { + [[noreturn]] S() { throw int {}; } +}; + +int test_no_return_constructor() { S(); } // ok AaronBallman wrote: Can you a

[clang] [flang] [clang][driver] When -fveclib=ArmPL flag is in use, always link against libamath (PR #116432)

2024-11-19 Thread David Truby via cfe-commits
@@ -490,6 +490,16 @@ void tools::AddLinkerInputs(const ToolChain &TC, const InputInfoList &Inputs, else A.renderAsInput(Args, CmdArgs); } + if (const Arg *A = Args.getLastArg(options::OPT_fveclib)) { +if (A->getNumValues() == 1) { + StringRef V = A->getVa

[clang] [amdgpu-arch] Replace use of HSA with reading sysfs directly (PR #116651)

2024-11-19 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `sanitizer-ppc64le-linux` running on `ppc64le-sanitizer` while building `clang` at step 2 "annotate". Full details are available at: https://lab.llvm.org/buildbot/#/builders/72/builds/5473 Here is the relevant piece of the bu

[clang] [Clang] enhance error recovery with RecoveryExpr for trailing commas in call arguments (PR #114684)

2024-11-19 Thread Haojian Wu via cfe-commits
https://github.com/hokein commented: Thanks, this is nice. Can you also add a release note? https://github.com/llvm/llvm-project/pull/114684 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-c

[clang] [llvm] [clang] Implement lifetime analysis for lifetime_capture_by(X) (PR #115921)

2024-11-19 Thread Utkarsh Saxena via cfe-commits
usx95 wrote: The contents are moved from `clang/test/Sema/warn-lifetime-analysis-nocfg.cpp`. AFAIK, I don't think git supports branching from a file. https://github.com/llvm/llvm-project/pull/115921 ___ cfe-commits m

[clang] Clarify use of contractions in diagnostic messages (PR #116803)

2024-11-19 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Aaron Ballman (AaronBallman) Changes This dissuades contributors from using contractions when writing diagnostic wording for Clang. Contractions should be avoided because of the potential for visual confusion with single quoting syntactic

[clang] Clarify use of contractions in diagnostic messages (PR #116803)

2024-11-19 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman created https://github.com/llvm/llvm-project/pull/116803 This dissuades contributors from using contractions when writing diagnostic wording for Clang. Contractions should be avoided because of the potential for visual confusion with single quoting syntactic con

[clang] [llvm] [clang] Implement lifetime analysis for lifetime_capture_by(X) (PR #115921)

2024-11-19 Thread Haojian Wu via cfe-commits
@@ -1412,17 +1438,34 @@ static void checkExprLifetimeImpl(Sema &SemaRef, return false; }; + bool HasReferenceBinding = Init->isGLValue(); llvm::SmallVector Path; - if (LK == LK_Assignment && - shouldRunGSLAssignmentAnalysis(SemaRef, *AEntity)) { -Path.push_

[clang] [Clang] skip warnings for constructors marked with the [[noreturn]] attribute (PR #115558)

2024-11-19 Thread Aaron Ballman via cfe-commits
@@ -49,3 +49,15 @@ void check() { test_type(g); test_type(h); // expected-note {{instantiation}} } + +namespace GH63009 { +struct S { + [[noreturn]] S() { throw int {}; } +}; + +int test_no_return_constructor() { S(); } // ok AaronBallman wrote: Also, sin

[clang-tools-extra] [clang-tidy] Enhance modernize-use-starts-ends-with to handle substr patterns (PR #116033)

2024-11-19 Thread Helmut Januschka via cfe-commits
hjanuschka wrote: @EugeneZelenko your comments have been resolved, but i am unable to mark them due to force push https://github.com/llvm/llvm-project/pull/116033 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/m

[clang] [Clang] skip warnings for constructors marked with the [[noreturn]] attribute (PR #115558)

2024-11-19 Thread Oleksandr T. via cfe-commits
https://github.com/a-tarasyuk updated https://github.com/llvm/llvm-project/pull/115558 >From f63263a1aa4873a63918649ea92352eb5cfe66eb Mon Sep 17 00:00:00 2001 From: Oleksandr T Date: Sat, 9 Nov 2024 00:41:13 +0200 Subject: [PATCH] [Clang] skip warnings for constructors marked with the [[noretu

[clang] [flang] [flang] Add UNSIGNED (PR #113504)

2024-11-19 Thread via cfe-commits
@@ -213,6 +213,22 @@ def fir_IntegerType : FIR_Type<"Integer", "int"> { }]; } +def fir_UnsignedType : FIR_Type<"Unsigned", "unsigned"> { jeanPerier wrote: Removing both the type and predicate, I got no failures (I had to help make by deleting some of the t

[clang] [llvm] [clang] Implement lifetime analysis for lifetime_capture_by(X) (PR #115921)

2024-11-19 Thread Boaz Brickner via cfe-commits
bricknerb wrote: I'm not familiar either with such a feature, but it seems it's possible to achieve, though not in a super straight forward way: For example: https://stackoverflow.com/questions/16937359/git-copy-file-preserving-history https://github.com/llvm

[clang] [compiler-rt] [llvm] [SystemZ] Add support for half (fp16) (PR #109164)

2024-11-19 Thread Ulrich Weigand via cfe-commits
@@ -6285,6 +6465,16 @@ SDValue SystemZTargetLowering::LowerOperation(SDValue Op, return lowerAddrSpaceCast(Op, DAG); case ISD::ROTL: return lowerShift(Op, DAG, SystemZISD::VROTL_BY_SCALAR); + case ISD::FP_EXTEND: +//case ISD::STRICT_FP_EXTEND: uweiga

[clang] [clang] Fix the post-filtering heuristic for GSLPointer. (PR #114044)

2024-11-19 Thread Haojian Wu via cfe-commits
https://github.com/hokein edited https://github.com/llvm/llvm-project/pull/114044 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Fix placement of `const` for resource operator[] (PR #116698)

2024-11-19 Thread Justin Bogner via cfe-commits
https://github.com/bogner closed https://github.com/llvm/llvm-project/pull/116698 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Implement -fstrict-bool (PR #116732)

2024-11-19 Thread Eli Friedman via cfe-commits
efriedma-quic wrote: If we're going to document that values other than 0 and 1 are "allowed", I think the documentation needs to explicitly state how values other than 0 and 1 are handled. https://github.com/llvm/llvm-project/pull/116732 ___ cfe-comm

[clang] [HLSL] Add ByteAddressBuffer definition to HLSLExternalSemaSource #113477 (PR #116699)

2024-11-19 Thread via cfe-commits
https://github.com/joaosaffran updated https://github.com/llvm/llvm-project/pull/116699 >From c3b3c87db9b6a47bea9ed69575d4a9a728d1b154 Mon Sep 17 00:00:00 2001 From: Joao Saffran Date: Sat, 9 Nov 2024 01:34:16 + Subject: [PATCH 1/6] adding definition --- clang/lib/Sema/HLSLExternalSemaSou

[clang] [analyzer] Avoid creating LazyCompoundVal when possible (PR #116840)

2024-11-19 Thread Balazs Benics via cfe-commits
steakhal wrote: Btw expect more patches about fixing LCVs and overall PostInitializer events and bindings. Basically, how we model the member initializers and copies. Stay tuned for those, but before that this one is a preparation patch, so I'm excited to see your comments. https://github.com

[clang] 2186a00 - [HLSL] Fix placement of `const` for resource operator[] (#116698)

2024-11-19 Thread via cfe-commits
Author: Justin Bogner Date: 2024-11-19T10:33:54-08:00 New Revision: 2186a008c98e8bb6738fe9120441d6bd15c272f3 URL: https://github.com/llvm/llvm-project/commit/2186a008c98e8bb6738fe9120441d6bd15c272f3 DIFF: https://github.com/llvm/llvm-project/commit/2186a008c98e8bb6738fe9120441d6bd15c272f3.diff

[clang] [ObjC] Name lookup in methods shouldn't allow shadowing types (PR #116683)

2024-11-19 Thread Akira Hatanaka via cfe-commits
https://github.com/ahatanak closed https://github.com/llvm/llvm-project/pull/116683 ___ 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 #116413)

2024-11-19 Thread Chris B via cfe-commits
@@ -323,19 +325,114 @@ struct TemplateParameterListBuilder { return *this; } - BuiltinTypeDeclBuilder &finalizeTemplateArgs() { + // The concept specialization expression (CSE) constructed in + // constructConceptSpecializationExpr is constructed so that it + // matc

[clang] [clang] Add support for `__declspec(no_init_all)` (PR #116847)

2024-11-19 Thread Daniel Paoliello via cfe-commits
dpaoliello wrote: > If we're going to treat `/d1initall` as an alias for > `-ftrivial-auto-var-init`, can we just treat `__declspec(no_init_all)` as an > alias for `__attribute__((uninitialized))`? `uninitialized` currently only applied to local variable declarations, whereas `__declspec(no_i

[clang] [llvm] [aarch64][clang][llvm] Allow AArch64 TLB maintenance instructions to be enabled via -march (PR #116707)

2024-11-19 Thread Eli Friedman via cfe-commits
efriedma-quic wrote: In assembly, you can override the current architecture with a `.arch` directive. https://github.com/llvm/llvm-project/pull/116707 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listin

[clang] [clang][UBSan] Make sure that the implicit-conversion group is compatible with minimal runtime (PR #114865)

2024-11-19 Thread Axel Lundberg via cfe-commits
Zonotora wrote: @vitalybuka This is connected to https://github.com/llvm/llvm-project/pull/75481 that was merged a couple of months ago.. https://github.com/llvm/llvm-project/pull/114865 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https:/

[clang] [llvm] [HLSL] Implement WaveActiveAnyTrue intrinsic (PR #115902)

2024-11-19 Thread Greg Roth via cfe-commits
https://github.com/pow2clk approved this pull request. Thanks for the fixups! https://github.com/llvm/llvm-project/pull/115902 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL] Implement WaveActiveAnyTrue intrinsic (PR #115902)

2024-11-19 Thread Farzon Lotfi via cfe-commits
@@ -2206,6 +2206,15 @@ float4 trunc(float4); // Wave* builtins //===--===// +/// \brief Returns true if the expression is true in any active lane in the +/// current wave. +/// +/// \param Val The boolean exp

[clang] [llvm] [mlir] [LLVM][IR] Use splat syntax when printing ConstantExpr based splats. (PR #116856)

2024-11-19 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Paul Walker (paulwalker-arm) Changes This brings the printing of scalable vector constant splats inline with their fixed length counterparts. --- Patch is 1.04 MiB, truncated to 20.00 KiB below, full version: https://github.com/llvm/llv

  1   2   3   4   5   >