[clang] Add option to generate additional debug info for expression dereferencing pointer to pointers. (PR #81545)

2024-02-12 Thread William Junda Huang via cfe-commits
https://github.com/huangjd created https://github.com/llvm/llvm-project/pull/81545 Such expression does not correspond to a variable in the source code thus does not have a debug location. When the user collects perf data on the program, if the intermediate memory load instruction is sampled,

[clang] [clang] Remove #undef alloca (PR #81534)

2024-02-12 Thread Arthur Eubanks via cfe-commits
https://github.com/aeubanks edited https://github.com/llvm/llvm-project/pull/81534 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Remove #undef alloca workaround (PR #81534)

2024-02-12 Thread Arthur Eubanks via cfe-commits
https://github.com/aeubanks edited https://github.com/llvm/llvm-project/pull/81534 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Add option to generate additional debug info for expression dereferencing pointer to pointers. (PR #81545)

2024-02-12 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 9261ab708e37c2d6499ac063045f816d25a5919c f2c82758e1cba7773e41d941d2812c829c339675 --

[clang] [clang] Remove #undef alloca workaround (PR #81534)

2024-02-12 Thread Arthur Eubanks via cfe-commits
https://github.com/aeubanks edited https://github.com/llvm/llvm-project/pull/81534 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Add -Wmissing-designated-field-initializers (PR #81364)

2024-02-12 Thread Vadim D. via cfe-commits
@@ -120,6 +120,10 @@ Non-comprehensive list of changes in this release New Compiler Flags -- +- ``-Wmissing-designated-field-initializers``, grouped under ``-Wmissing-designated-field-initializers``. vvd170501 wrote: Would it be ok to also ad

[clang] [clang-tools-extra] [codegen] Emit missing cleanups when an expression contains a branch (PR #80698)

2024-02-12 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 edited https://github.com/llvm/llvm-project/pull/80698 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [codegen] Emit missing cleanups when an expression contains a branch (PR #80698)

2024-02-12 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 edited https://github.com/llvm/llvm-project/pull/80698 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AMDGPU] Emit a waitcnt instruction after each memory instruction (PR #79236)

2024-02-12 Thread Jun Wang via cfe-commits
@@ -605,12 +606,197 @@ class SIGfx12CacheControl : public SIGfx11CacheControl { bool IsNonTemporal) const override; }; +class SIPreciseMemorySupport { jwanggit86 wrote: Merged with SICacheControl. https://github.com/llvm

[clang] 93cdd1b - [PGO] Add ability to mark cold functions as optsize/minsize/optnone (#69030)

2024-02-12 Thread via cfe-commits
Author: Arthur Eubanks Date: 2024-02-12T14:52:08-08:00 New Revision: 93cdd1b5cfa3735c599949b77e24dbfbe570441a URL: https://github.com/llvm/llvm-project/commit/93cdd1b5cfa3735c599949b77e24dbfbe570441a DIFF: https://github.com/llvm/llvm-project/commit/93cdd1b5cfa3735c599949b77e24dbfbe570441a.diff

[clang] [llvm] [PGO] Add ability to mark cold functions as optsize/minsize/optnone (PR #69030)

2024-02-12 Thread Arthur Eubanks via cfe-commits
https://github.com/aeubanks closed https://github.com/llvm/llvm-project/pull/69030 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AMDGPU] Emit a waitcnt instruction after each memory instruction (PR #79236)

2024-02-12 Thread Jun Wang via cfe-commits
@@ -167,6 +167,10 @@ def FeatureCuMode : SubtargetFeature<"cumode", "Enable CU wavefront execution mode" >; +def FeaturePreciseMemory jwanggit86 wrote: As it is, we have a clang command-line option "-mamdgpu-precise-memory-op". When specified, "+amdgpu-pre

[clang] 85507f1 - [analyzer] Ignore assignment to Ref / RefPtr in alpha.webkit.UncountedCallArgsChecker. (#80810)

2024-02-12 Thread via cfe-commits
Author: Ryosuke Niwa Date: 2024-02-12T14:59:14-08:00 New Revision: 85507f17cfc42e29f956de6b3e0924c3cf7b4469 URL: https://github.com/llvm/llvm-project/commit/85507f17cfc42e29f956de6b3e0924c3cf7b4469 DIFF: https://github.com/llvm/llvm-project/commit/85507f17cfc42e29f956de6b3e0924c3cf7b4469.diff

[clang] Ignore assignment to Ref / RefPtr in alpha.webkit.UncountedCallArgsChecker. (PR #80810)

2024-02-12 Thread Artem Dergachev via cfe-commits
https://github.com/haoNoQ closed https://github.com/llvm/llvm-project/pull/80810 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 8256804 - [analyzer] Add the support for calling Ref::ptr accessor. (#80919)

2024-02-12 Thread via cfe-commits
Author: Ryosuke Niwa Date: 2024-02-12T15:00:12-08:00 New Revision: 82568046e6761f961002ea6c48b5160ba6c7576f URL: https://github.com/llvm/llvm-project/commit/82568046e6761f961002ea6c48b5160ba6c7576f DIFF: https://github.com/llvm/llvm-project/commit/82568046e6761f961002ea6c48b5160ba6c7576f.diff

[clang] Add the support for calling Ref::ptr accessor. (PR #80919)

2024-02-12 Thread Artem Dergachev via cfe-commits
https://github.com/haoNoQ closed https://github.com/llvm/llvm-project/pull/80919 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 9df7189 - [test] Replace aarch64-*-{eabi, gnueabi} with aarch64

2024-02-12 Thread Fangrui Song via cfe-commits
Author: Fangrui Song Date: 2024-02-12T15:00:45-08:00 New Revision: 9df71899bd5dbbaf0640c74cc82a6330dc7760cf URL: https://github.com/llvm/llvm-project/commit/9df71899bd5dbbaf0640c74cc82a6330dc7760cf DIFF: https://github.com/llvm/llvm-project/commit/9df71899bd5dbbaf0640c74cc82a6330dc7760cf.diff

[clang] [llvm] [AMDGPU] Emit a waitcnt instruction after each memory instruction (PR #79236)

2024-02-12 Thread Jun Wang via cfe-commits
@@ -0,0 +1,362 @@ +; RUN: llc -mtriple=amdgcn -mcpu=gfx900 -mattr=+amdgpu-precise-memory-op < %s | FileCheck %s -check-prefixes=GFX9 +; RUN: llc -mtriple=amdgcn -mcpu=gfx90a -mattr=+amdgpu-precise-memory-op < %s | FileCheck %s -check-prefixes=GFX90A +; RUN: llc -mtriple=amdgcn -

[clang] f63da47 - [analyzer] Fix an implicit cast to a base ref counted class generates a false positive. (#80934)

2024-02-12 Thread via cfe-commits
Author: Ryosuke Niwa Date: 2024-02-12T15:01:16-08:00 New Revision: f63da479ae2f5e0d747430f268ae7b458c02455c URL: https://github.com/llvm/llvm-project/commit/f63da479ae2f5e0d747430f268ae7b458c02455c DIFF: https://github.com/llvm/llvm-project/commit/f63da479ae2f5e0d747430f268ae7b458c02455c.diff

[clang] Fix an implicit cast to a base ref counted class generates a false positive. (PR #80934)

2024-02-12 Thread Artem Dergachev via cfe-commits
https://github.com/haoNoQ closed https://github.com/llvm/llvm-project/pull/80934 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 2dbfa84 - [analyzer] Allow default arguments to be evaluated like other arguments. (#80956)

2024-02-12 Thread via cfe-commits
Author: Ryosuke Niwa Date: 2024-02-12T15:01:40-08:00 New Revision: 2dbfa8407e7d2f4293add33b5ead3f2d5fcd04e9 URL: https://github.com/llvm/llvm-project/commit/2dbfa8407e7d2f4293add33b5ead3f2d5fcd04e9 DIFF: https://github.com/llvm/llvm-project/commit/2dbfa8407e7d2f4293add33b5ead3f2d5fcd04e9.diff

[clang] Allow default arguments to be evaluated like other arguments. (PR #80956)

2024-02-12 Thread Artem Dergachev via cfe-commits
https://github.com/haoNoQ closed https://github.com/llvm/llvm-project/pull/80956 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AMDGPU] Emit a waitcnt instruction after each memory instruction (PR #79236)

2024-02-12 Thread Jun Wang via cfe-commits
@@ -605,12 +606,197 @@ class SIGfx12CacheControl : public SIGfx11CacheControl { bool IsNonTemporal) const override; }; +class SIPreciseMemorySupport { +protected: + const GCNSubtarget &ST; + const SIInstrInfo *TII = nullptr; + + IsaVers

[clang] [llvm] [RFC][AMDGPU] Use `bf16` instead of `i16` for bfloat (PR #80908)

2024-02-12 Thread Shilei Tian via cfe-commits
https://github.com/shiltian updated https://github.com/llvm/llvm-project/pull/80908 >From df3dbb6b9c257157c4afb407e40447a25c27a2a8 Mon Sep 17 00:00:00 2001 From: Shilei Tian Date: Mon, 12 Feb 2024 18:03:57 -0500 Subject: [PATCH] [RFC][WIP][AMDGPU] Use `bf16` instead of `i16` for bfloat Current

[clang] [clang-tools-extra] [codegen] Emit missing cleanups when an expression contains a branch (PR #80698)

2024-02-12 Thread Eli Friedman via cfe-commits
https://github.com/efriedma-quic commented: Do we need to add handling for `new int[](co_await foo())` (CodeGenFunction::EmitNewArrayInitializer)? https://github.com/llvm/llvm-project/pull/80698 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [clang-tools-extra] [codegen] Emit missing cleanups when an expression contains a branch (PR #80698)

2024-02-12 Thread Eli Friedman via cfe-commits
@@ -627,9 +627,11 @@ CodeGenFunction::getJumpDestForLabel(const LabelDecl *D) { if (Dest.isValid()) return Dest; // Create, but don't insert, the new block. + // FIXME: We do not know `BranchInExprDepth` for the destination and currently + // emit *all* the BranchInExpr

[clang] [clang-tools-extra] [codegen] Emit missing cleanups when an expression contains a branch (PR #80698)

2024-02-12 Thread Eli Friedman via cfe-commits
https://github.com/efriedma-quic edited https://github.com/llvm/llvm-project/pull/80698 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [codegen] Emit missing cleanups when an expression contains a branch (PR #80698)

2024-02-12 Thread Eli Friedman via cfe-commits
@@ -592,10 +590,14 @@ void AggExprEmitter::EmitArrayInit(Address DestPtr, llvm::ArrayType *AType, // observed to be unnecessary. if (endOfInit.isValid()) Builder.CreateStore(element, endOfInit); } - -LValue elementLV = CGF.MakeAddrLValue( -Address(e

[clang] [llvm] [Clang][SME] Detect always_inline used with mismatched streaming attributes (PR #77936)

2024-02-12 Thread Dinar Temirbulatov via cfe-commits
https://github.com/dtemirbulatov approved this pull request. LGTM. https://github.com/llvm/llvm-project/pull/77936 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [-Wunsafe-buffer-usage] Introduce std::array fixits (PR #80084)

2024-02-12 Thread via cfe-commits
https://github.com/jkorous-apple updated https://github.com/llvm/llvm-project/pull/80084 >From 463a9904c1ae85fbdc0bd6029c6effea3fb16ea6 Mon Sep 17 00:00:00 2001 From: Jan Korous Date: Tue, 23 Jan 2024 16:16:10 -0800 Subject: [PATCH 01/17] [-Wunsafe-buffer-usage] Move Strategy class to the head

[clang] [-Wunsafe-buffer-usage] Introduce std::array fixits (PR #80084)

2024-02-12 Thread via cfe-commits
@@ -61,6 +61,7 @@ void testArraySubscripts(int *p, int **pp) { ); int a[10]; // expected-warning{{'a' is an unsafe buffer that does not perform bounds checks}} +// expected-note@-1{{change type of 'a' to 'std::array' to harden it}}

[clang] 644ac2a - [-Wunsafe-buffer-usage] Introduce std::array fixits (#80084)

2024-02-12 Thread via cfe-commits
Author: jkorous-apple Date: 2024-02-12T15:52:20-08:00 New Revision: 644ac2a018c9bf83c9ba256074e552ad7f1fe941 URL: https://github.com/llvm/llvm-project/commit/644ac2a018c9bf83c9ba256074e552ad7f1fe941 DIFF: https://github.com/llvm/llvm-project/commit/644ac2a018c9bf83c9ba256074e552ad7f1fe941.diff

[clang] [-Wunsafe-buffer-usage] Introduce std::array fixits (PR #80084)

2024-02-12 Thread via cfe-commits
https://github.com/jkorous-apple closed https://github.com/llvm/llvm-project/pull/80084 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [llvm] Add bazel support for clangd as a library. (PR #81556)

2024-02-12 Thread via cfe-commits
https://github.com/josh11b created https://github.com/llvm/llvm-project/pull/81556 Both creates a `BUILD.bazel` file for the `clangd` directory in the project overlay, and removes an unnecessary `#include "Feature.h"` to reduce the dependencies from `Transport.h`. This upstreams the patch tha

[clang-tools-extra] [llvm] Add bazel support for clangd as a library. (PR #81556)

2024-02-12 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-tools-extra] [llvm] Add bazel support for clangd as a library. (PR #81556)

2024-02-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clangd Author: None (josh11b) Changes Both creates a `BUILD.bazel` file for the `clangd` directory in the project overlay, and removes an unnecessary `#include "Feature.h"` to reduce the dependencies from `Transport.h`. This upstreams the patch that a

[clang-tools-extra] [llvm] Add bazel support for clangd as a library. (PR #81556)

2024-02-12 Thread via cfe-commits
github-actions[bot] wrote: ⚠️ We detected that you are using a GitHub private e-mail address to contribute to the repo. Please turn off [Keep my email addresses private](https://github.com/settings/emails) setting in your account. See [LLVM Discourse](https://discourse.llvm.org/t/hidden-em

[clang-tools-extra] Add support for renaming objc methods, even those with multiple selector pieces (PR #76466)

2024-02-12 Thread Alex Hoppen via cfe-commits
https://github.com/ahoppen commented: The outstanding comments from last review are: - Use `SymbolName` instead of `StringRef` - https://github.com/llvm/llvm-project/pull/76466#discussion_r1476409221 - https://github.com/llvm/llvm-project/pull/76466#discussion_r1476427027 - Don’t re-lex the s

[clang-tools-extra] Add support for renaming objc methods, even those with multiple selector pieces (PR #76466)

2024-02-12 Thread Alex Hoppen via cfe-commits
https://github.com/ahoppen edited https://github.com/llvm/llvm-project/pull/76466 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] Add support for renaming objc methods, even those with multiple selector pieces (PR #76466)

2024-02-12 Thread Alex Hoppen via cfe-commits
@@ -538,11 +564,222 @@ std::optional checkName(const NamedDecl &RenameDecl, Conflict->getLocation().printToString(ASTCtx.getSourceManager())}; } } - if (Result) + if (Result) { InvalidNameMetric.record(1, toString(Result->K)); +return makeError(*Re

[clang-tools-extra] Add support for renaming objc methods, even those with multiple selector pieces (PR #76466)

2024-02-12 Thread Alex Hoppen via cfe-commits
@@ -538,11 +564,222 @@ std::optional checkName(const NamedDecl &RenameDecl, Conflict->getLocation().printToString(ASTCtx.getSourceManager())}; } } - if (Result) + if (Result) { InvalidNameMetric.record(1, toString(Result->K)); +return makeError(*Re

[clang-tools-extra] Add support for renaming objc methods, even those with multiple selector pieces (PR #76466)

2024-02-12 Thread Alex Hoppen via cfe-commits
@@ -538,11 +564,222 @@ std::optional checkName(const NamedDecl &RenameDecl, Conflict->getLocation().printToString(ASTCtx.getSourceManager())}; } } - if (Result) + if (Result) { InvalidNameMetric.record(1, toString(Result->K)); +return makeError(*Re

[clang-tools-extra] [llvm] Add bazel support for clangd as a library. (PR #81556)

2024-02-12 Thread via cfe-commits
https://github.com/josh11b updated https://github.com/llvm/llvm-project/pull/81556 >From e2b83f086e51d7144d8e6ac1d1850300de55f01f Mon Sep 17 00:00:00 2001 From: Josh L Date: Mon, 12 Feb 2024 22:59:21 + Subject: [PATCH] Add bazel support for clangd as a library. --- clang-tools-extra/clang

[clang] [clang] Remove #undef alloca workaround (PR #81534)

2024-02-12 Thread Nico Weber via cfe-commits
https://github.com/nico approved this pull request. LG, great investigation! https://github.com/llvm/llvm-project/pull/81534 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [RISCV] Add canonical ISA string as Module metadata in IR. (PR #80760)

2024-02-12 Thread Jessica Clarke via cfe-commits
jrtc27 wrote: That's fair. I just imagine this is going to result in people forgetting about the underlying issue and adding their own patchwork fixes to work around it in their targets, so it would be a nice motivation to fix it properly. https://github.com/llvm/llvm-project/pull/80760 __

[clang] [llvm] [Clang][SME] Detect always_inline used with mismatched streaming attributes (PR #77936)

2024-02-12 Thread Dinar Temirbulatov via cfe-commits
https://github.com/dtemirbulatov edited https://github.com/llvm/llvm-project/pull/77936 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Clang][SME] Detect always_inline used with mismatched streaming attributes (PR #77936)

2024-02-12 Thread Dinar Temirbulatov via cfe-commits
@@ -814,6 +820,49 @@ Address AArch64ABIInfo::EmitMSVAArg(CodeGenFunction &CGF, Address VAListAddr, /*allowHigherAlign*/ false); } +class SMEAttributes { +public: + bool IsStreaming = false; + bool IsStreamingCompatible = false; + bool HasNewZA = f

[clang] [llvm] [Clang][SME] Detect always_inline used with mismatched streaming attributes (PR #77936)

2024-02-12 Thread Dinar Temirbulatov via cfe-commits
https://github.com/dtemirbulatov requested changes to this pull request. https://github.com/llvm/llvm-project/pull/77936 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] fix incorrect hint for InitListExpr in prefer-member-initializer (PR #81560)

2024-02-12 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 created https://github.com/llvm/llvm-project/pull/81560 Fixes: #77684. >From 35dba54b1d6d158118c34d0f1bd8038b64c9bda4 Mon Sep 17 00:00:00 2001 From: Congcong Cai Date: Tue, 13 Feb 2024 09:11:06 +0800 Subject: [PATCH] [clang-tidy] fix incorrect hint for InitListEx

[clang-tools-extra] [clang-tidy] fix incorrect hint for InitListExpr in prefer-member-initializer (PR #81560)

2024-02-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tidy @llvm/pr-subscribers-clang-tools-extra Author: Congcong Cai (HerrCai0907) Changes Fixes: #77684. --- Full diff: https://github.com/llvm/llvm-project/pull/81560.diff 3 Files Affected: - (modified) clang-tools-extra/clang-tidy/cppcoreguidel

[clang] [-Wunsafe-buffer-usage] Fixits for array decayed to pointer (PR #80347)

2024-02-12 Thread via cfe-commits
https://github.com/jkorous-apple updated https://github.com/llvm/llvm-project/pull/80347 >From 245ea0a82fdd1b24a5c7175fc90379a86df77fe8 Mon Sep 17 00:00:00 2001 From: Jan Korous Date: Wed, 24 Jan 2024 17:35:47 -0800 Subject: [PATCH 1/2] [-Wunsafe-buffer-usage] Emit fixits for array used as a p

[clang] [-Wunsafe-buffer-usage] Fixits for array decayed to pointer (PR #80347)

2024-02-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-analysis @llvm/pr-subscribers-clang Author: None (jkorous-apple) Changes depends on https://github.com/llvm/llvm-project/pull/80084 --- Full diff: https://github.com/llvm/llvm-project/pull/80347.diff 2 Files Affected: - (modified) clang/lib/An

[clang] [-Wunsafe-buffer-usage] Add fixits for array to pointer assignment (PR #81343)

2024-02-12 Thread via cfe-commits
https://github.com/jkorous-apple converted_to_draft https://github.com/llvm/llvm-project/pull/81343 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] ignore local variable with [maybe_unused] attribute in bugprone-unused-local-non-trivial-variable (PR #81563)

2024-02-12 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 created https://github.com/llvm/llvm-project/pull/81563 Fixes: #81419. >From fefe52614837d14858d056783dca8b08745de9d4 Mon Sep 17 00:00:00 2001 From: Congcong Cai Date: Tue, 13 Feb 2024 09:47:52 +0800 Subject: [PATCH] [clang-tidy] ignore local variable with [maybe

[clang-tools-extra] [clang-tidy] ignore local variable with [maybe_unused] attribute in bugprone-unused-local-non-trivial-variable (PR #81563)

2024-02-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tools-extra Author: Congcong Cai (HerrCai0907) Changes Fixes: #81419. --- Full diff: https://github.com/llvm/llvm-project/pull/81563.diff 4 Files Affected: - (modified) clang-tools-extra/clang-tidy/bugprone/UnusedLocalNonTrivialVariableCheck.c

[clang] [compiler-rt] [Sanitizer] add signed-integer-wrap sanitizer (PR #80089)

2024-02-12 Thread Kees Cook via cfe-commits
kees wrote: I've tested this with the Linux kernel, and it is working as expected. It is ready and waiting for this option to gain back a bunch of sanitizer coverage for CIs and likely in production kernels. :) https://github.com/llvm/llvm-project/pull/80089 ___

[clang] [Clang][Sema] fix crash in codegen stage when an lambda expression declared in an unevaluated context (PR #80802)

2024-02-12 Thread Qizhi Hu via cfe-commits
https://github.com/jcsxky updated https://github.com/llvm/llvm-project/pull/80802 >From 2f09be514adff0c5e19494b14fbe4cc9588fea9c Mon Sep 17 00:00:00 2001 From: huqizhi Date: Tue, 6 Feb 2024 14:06:40 +0800 Subject: [PATCH] [Clang][Sema] fix crash in codegen stage when an lambda expression decla

[clang] [llvm] [HLSL] Implementation of dot intrinsic (PR #81190)

2024-02-12 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl updated https://github.com/llvm/llvm-project/pull/81190 >From 5082bc7fb49761424c7984a594a5afad9a03f04d Mon Sep 17 00:00:00 2001 From: Farzon Lotfi Date: Thu, 8 Feb 2024 11:08:59 -0500 Subject: [PATCH] [HLSL] Implementation of dot intrinsic This change implements #700

[clang] [llvm] [HLSL] Implementation of dot intrinsic (PR #81190)

2024-02-12 Thread Farzon Lotfi via cfe-commits
@@ -4518,6 +4518,12 @@ def HLSLCreateHandle : LangBuiltin<"HLSL_LANG"> { let Prototype = "void*(unsigned char)"; } +def HLSLDotProduct : LangBuiltin<"HLSL_LANG"> { + let Spellings = ["__builtin_hlsl_dot"]; + let Attributes = [NoThrow, Const, CustomTypeChecking]; --

[clang] [llvm] [HLSL] Implementation of dot intrinsic (PR #81190)

2024-02-12 Thread Farzon Lotfi via cfe-commits
@@ -144,6 +144,92 @@ double3 cos(double3); _HLSL_BUILTIN_ALIAS(__builtin_elementwise_cos) double4 cos(double4); +//===--===// +// dot product builtins +//===

[clang] [llvm] [HLSL] Implementation of dot intrinsic (PR #81190)

2024-02-12 Thread Farzon Lotfi via cfe-commits
@@ -19,4 +19,9 @@ def int_dx_flattened_thread_id_in_group : Intrinsic<[llvm_i32_ty], [], [IntrNoMe def int_dx_create_handle : ClangBuiltin<"__builtin_hlsl_create_handle">, Intrinsic<[ llvm_ptr_ty ], [llvm_i8_ty], [IntrWillReturn]>; -} + +def int_dx_dot : +Intrinsic<[

[clang] [llvm] [HLSL] Implementation of dot intrinsic (PR #81190)

2024-02-12 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl edited https://github.com/llvm/llvm-project/pull/81190 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL] Implementation of dot intrinsic (PR #81190)

2024-02-12 Thread Farzon Lotfi via cfe-commits
@@ -19,4 +19,9 @@ def int_dx_flattened_thread_id_in_group : Intrinsic<[llvm_i32_ty], [], [IntrNoMe def int_dx_create_handle : ClangBuiltin<"__builtin_hlsl_create_handle">, Intrinsic<[ llvm_ptr_ty ], [llvm_i8_ty], [IntrWillReturn]>; -} + +def int_dx_dot : +Intrinsic<[

[clang] [llvm] [HLSL] Implementation of dot intrinsic (PR #81190)

2024-02-12 Thread Farzon Lotfi via cfe-commits
@@ -144,6 +144,92 @@ double3 cos(double3); _HLSL_BUILTIN_ALIAS(__builtin_elementwise_cos) double4 cos(double4); +//===--===// +// dot product builtins +//===

[clang] [llvm] [HLSL] Implementation of dot intrinsic (PR #81190)

2024-02-12 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl updated https://github.com/llvm/llvm-project/pull/81190 >From 4103940b5a2578efc08df554ccdf80cb34925d09 Mon Sep 17 00:00:00 2001 From: Farzon Lotfi Date: Thu, 8 Feb 2024 11:08:59 -0500 Subject: [PATCH] [HLSL] Implementation of dot intrinsic This change implements #700

[clang] [llvm] [HLSL] Implementation of dot intrinsic (PR #81190)

2024-02-12 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl updated https://github.com/llvm/llvm-project/pull/81190 >From 73cc9fde36a44ba1715a3c9fc6d48196602d5dc4 Mon Sep 17 00:00:00 2001 From: Farzon Lotfi Date: Thu, 8 Feb 2024 11:08:59 -0500 Subject: [PATCH] [HLSL] Implementation of dot intrinsic This change implements #700

[clang] [clang-format] Rename option AlwaysBreakAfterReturnType. (PR #80827)

2024-02-12 Thread Owen Pan via cfe-commits
@@ -677,6 +677,23 @@ TEST(ConfigParseTest, ParsesConfiguration) { " AfterControlStatement: false", BraceWrapping.AfterControlStatement, FormatStyle::BWACS_Never); + Style.AlwaysBreakAfterReturnType = FormatStyle::RTBS_All; + CHECK_PARSE("BreakAft

[clang] 4af24d4 - [clang-format] Don't remove parentheses in macro definitions (#81444)

2024-02-12 Thread via cfe-commits
Author: Owen Pan Date: 2024-02-12T19:20:26-08:00 New Revision: 4af24d4ab76539706bfbceec4b3923426fb1b9e7 URL: https://github.com/llvm/llvm-project/commit/4af24d4ab76539706bfbceec4b3923426fb1b9e7 DIFF: https://github.com/llvm/llvm-project/commit/4af24d4ab76539706bfbceec4b3923426fb1b9e7.diff LOG:

[clang] [clang-format] Don't remove parentheses in macro definitions (PR #81444)

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

[clang] [clang-format] Don't remove parentheses in macro definitions (PR #81444)

2024-02-12 Thread Owen Pan via cfe-commits
https://github.com/owenca milestoned https://github.com/llvm/llvm-project/pull/81444 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Don't remove parentheses in macro definitions (PR #81444)

2024-02-12 Thread Owen Pan via cfe-commits
owenca wrote: /cherry-pick 4af24d4ab765 https://github.com/llvm/llvm-project/pull/81444 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [ObjC] Check entire chain of superclasses to see if class layout can be statically known (PR #81335)

2024-02-12 Thread John McCall via cfe-commits
https://github.com/rjmccall requested changes to this pull request. > @rjmccall Are these tests adequate? No. You need to test the behavior of ivar accesses in the subclass when there is an intermediate superclass that has ivars declared in all the ways I identified. Your test has many tests

[clang] [ObjC] Check entire chain of superclasses to see if class layout can be statically known (PR #81335)

2024-02-12 Thread John McCall via cfe-commits
rjmccall wrote: > Alright. I think the LTO should be done as a follow-up PR since it will > likely take some time and multiple reviews to get right. Yes, that's a fine plan. I expect that that'll be a significant amount of work. https://github.com/llvm/llvm-project/pull/81335

[clang] Add option to generate additional debug info for expression dereferencing pointer to pointers. (PR #81545)

2024-02-12 Thread Snehasish Kumar via cfe-commits
snehasish wrote: Any measurements of impact to compile time, memory etc on a reasonable size benchmark (e.g. clang)? https://github.com/llvm/llvm-project/pull/81545 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin

[clang] [clang-format] Don't remove parentheses in macro definitions (PR #81444)

2024-02-12 Thread via cfe-commits
llvmbot wrote: /pull-request llvm/llvm-project#81566 https://github.com/llvm/llvm-project/pull/81444 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Don't remove parentheses in macro definitions (PR #81444)

2024-02-12 Thread Owen Pan via cfe-commits
owenca wrote: > Any hope that this lands in 18.1? Thanks anyway! Most likely. https://github.com/llvm/llvm-project/pull/81444 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [LLVM] Add `__builtin_readsteadycounter` intrinsic and builtin for realtime clocks (PR #81331)

2024-02-12 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm commented: Add to release notes? https://github.com/llvm/llvm-project/pull/81331 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Rename option AlwaysBreakAfterReturnType. (PR #80827)

2024-02-12 Thread Owen Pan via cfe-commits
https://github.com/owenca updated https://github.com/llvm/llvm-project/pull/80827 >From 3c3e167711dccfcc0a56c5b465b20c17854451a4 Mon Sep 17 00:00:00 2001 From: rmarker Date: Tue, 6 Feb 2024 21:53:20 +1030 Subject: [PATCH 1/2] [clang-format] Rename option AlwaysBreakAfterReturnType. --- clang/

[clang] [llvm] [LLVM] Add `__builtin_readsteadycounter` intrinsic and builtin for realtime clocks (PR #81331)

2024-02-12 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/81331 >From 4a0ee4be9690e0665ca93d63ffdd2dea404fd72d Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Fri, 9 Feb 2024 16:13:42 -0600 Subject: [PATCH] [LLVM] Add `__builtin_readsteadycounter` intrinsic and buiiltin S

[clang] [llvm] [LLVM] Add `__builtin_readsteadycounter` intrinsic and builtin for realtime clocks (PR #81331)

2024-02-12 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > Add to release notes? Done https://github.com/llvm/llvm-project/pull/81331 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [PGO] Add ability to mark cold functions as optsize/minsize/optnone (PR #69030)

2024-02-12 Thread via cfe-commits
@@ -0,0 +1,61 @@ +//===--===// +// +// 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: Apac

[clang] [llvm] [PGO] Add ability to mark cold functions as optsize/minsize/optnone (PR #69030)

2024-02-12 Thread via cfe-commits
WenleiHe wrote: > > > > Good example. This pass should be run post-inline. @aeubanks, any > > > > reason we want to run it early in the pipeline? > > > > > > > > > We want the main function simplification pipeline to see these function > > > attributes because some optimizations trigger or do

[clang] [llvm] [clang][MBD] set up module build daemon infrastructure (PR #67562)

2024-02-12 Thread Connor Sughrue via cfe-commits
https://github.com/cpsughrue updated https://github.com/llvm/llvm-project/pull/67562 >From 03d3310ca300630a94517fa300858d1f2645e843 Mon Sep 17 00:00:00 2001 From: cpsughrue Date: Sun, 9 Jul 2023 23:19:58 -0400 Subject: [PATCH 01/17] [clang][MBD] set up module build daemon infrastructure The mo

[clang] [llvm] [clang][MBD] set up module build daemon infrastructure (PR #67562)

2024-02-12 Thread Connor Sughrue via cfe-commits
https://github.com/cpsughrue updated https://github.com/llvm/llvm-project/pull/67562 >From 03d3310ca300630a94517fa300858d1f2645e843 Mon Sep 17 00:00:00 2001 From: cpsughrue Date: Sun, 9 Jul 2023 23:19:58 -0400 Subject: [PATCH 01/17] [clang][MBD] set up module build daemon infrastructure The mo

[clang] [llvm] [PowerPC] Support local-dynamic TLS relocation on AIX (PR #66316)

2024-02-12 Thread Amy Kwan via cfe-commits
@@ -145,9 +164,94 @@ namespace { .addImm(0); if (IsAIX) { - // The variable offset and region handle are copied in r4 and r3. The - // copies are followed by GETtlsADDR32AIX/GETtlsADDR64AIX

[clang] [llvm] [PowerPC] Support local-dynamic TLS relocation on AIX (PR #66316)

2024-02-12 Thread Amy Kwan via cfe-commits
@@ -145,9 +164,94 @@ namespace { .addImm(0); if (IsAIX) { - // The variable offset and region handle are copied in r4 and r3. The - // copies are followed by GETtlsADDR32AIX/GETtlsADDR64AIX

[clang] [llvm] [PowerPC] Support local-dynamic TLS relocation on AIX (PR #66316)

2024-02-12 Thread Amy Kwan via cfe-commits
https://github.com/amy-kwan commented: I believe some of the test cases also require updates as a result of https://github.com/llvm/llvm-project/pull/80162. https://github.com/llvm/llvm-project/pull/66316 ___ cfe-commits mailing list cfe-commits@lists

[clang] [llvm] [PowerPC] Support local-dynamic TLS relocation on AIX (PR #66316)

2024-02-12 Thread Amy Kwan via cfe-commits
https://github.com/amy-kwan edited https://github.com/llvm/llvm-project/pull/66316 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [PowerPC] Support local-dynamic TLS relocation on AIX (PR #66316)

2024-02-12 Thread Amy Kwan via cfe-commits
@@ -145,9 +164,94 @@ namespace { .addImm(0); if (IsAIX) { - // The variable offset and region handle are copied in r4 and r3. The - // copies are followed by GETtlsADDR32AIX/GETtlsADDR64AIX

[clang] [llvm] [PowerPC] Support local-dynamic TLS relocation on AIX (PR #66316)

2024-02-12 Thread Amy Kwan via cfe-commits
@@ -145,9 +164,94 @@ namespace { .addImm(0); if (IsAIX) { - // The variable offset and region handle are copied in r4 and r3. The - // copies are followed by GETtlsADDR32AIX/GETtlsADDR64AIX

[clang] 91dcf53 - [clang-format] Rename option AlwaysBreakAfterReturnType. (#80827)

2024-02-12 Thread via cfe-commits
Author: rmarker Date: 2024-02-12T20:28:33-08:00 New Revision: 91dcf53abd34fa836a126c706f87b810d299d802 URL: https://github.com/llvm/llvm-project/commit/91dcf53abd34fa836a126c706f87b810d299d802 DIFF: https://github.com/llvm/llvm-project/commit/91dcf53abd34fa836a126c706f87b810d299d802.diff LOG:

[clang] [clang-format] Rename option AlwaysBreakAfterReturnType. (PR #80827)

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

[clang] [clang-tools-extra] [codegen] Emit missing cleanups when an expression contains a branch (PR #80698)

2024-02-12 Thread James Y Knight via cfe-commits
jyknight wrote: Is there a valid use for having "EHCleanup" that _doesn't_ handle branches across it? That is, do we _ever_ need a cleanup to be called only for an exception thrown, and not otherwise leaving the scope? I'm just wondering if we can simplify things conceptually here and remove a

[clang] [clang] Implement `__is_layout_compatible` (PR #81506)

2024-02-12 Thread Timm Baeder via cfe-commits
@@ -14040,6 +14040,8 @@ class Sema final { bool SemaValueIsRunOfOnes(CallExpr *TheCall, unsigned ArgNum); public: + bool SemaIsLayoutCompatible(QualType T1, QualType T2); tbaederr wrote: Can this function no be `const`? And I guess the "Sema" prefix is to

[clang] [clang][InstallAPI] Introduce basic driver to write out tbd files (PR #81571)

2024-02-12 Thread Cyndy Ishida via cfe-commits
https://github.com/cyndyishida created https://github.com/llvm/llvm-project/pull/81571 This introduces a basic outline of installapi as a clang driver option. It captures relevant information as cc1 args, which are common arguments already passed to the linker to encode into TBD file outputs.

[clang] [clang][InstallAPI] Introduce basic driver to write out tbd files (PR #81571)

2024-02-12 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-driver Author: Cyndy Ishida (cyndyishida) Changes This introduces a basic outline of installapi as a clang driver option. It captures relevant information as cc1 args, which are common arguments already passed to the linker to encode into TBD fil

[clang] [clang][InstallAPI] Introduce basic driver to write out tbd files (PR #81571)

2024-02-12 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 4af24d4ab76539706bfbceec4b3923426fb1b9e7 0f938ae8480f74a44bf6fe4aac6105e457315bb9 --

[clang] [clang][InstallAPI] Introduce basic driver to write out tbd files (PR #81571)

2024-02-12 Thread Cyndy Ishida via cfe-commits
cyndyishida wrote: In case anyone is interested, Here are relevant links for upstreaming `tapi` in LLVM: * [Inital RFC](https://discourse.llvm.org/t/rfc-open-sourcing-and-contributing-tapi-back-to-the-llvm-community/46214/24) * [Continued RFC](https://discourse.llvm.org/t/rfc-continuation-of-

[clang] Avoid printing overly large integer. (PR #75902)

2024-02-12 Thread Nhat Nguyen via cfe-commits
=?utf-8?q?“Nhat?= , =?utf-8?q?“Nhat?= , =?utf-8?q?“Nhat?= , =?utf-8?q?“Nhat?= , =?utf-8?q?“Nhat?= ,Nhat Nguyen Message-ID: In-Reply-To: changkhothuychung wrote: > Looks like all the tests disappeared? Only thing I see is the code change. > Also, no release note is currently present. Hi I am

[clang] [clang][Interp] Handle complex values in visitBool() (PR #79452)

2024-02-12 Thread Timm Baeder via cfe-commits
Timm =?utf-8?q?B=C3=A4der?= Message-ID: In-Reply-To: tbaederr wrote: Ping https://github.com/llvm/llvm-project/pull/79452 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

<    1   2   3   4   5   >