[clang] [Clang] Only check exprs that might be immediate escalating in evaluated contexts (PR #93187)

2024-05-23 Thread via cfe-commits
https://github.com/cor3ntin updated https://github.com/llvm/llvm-project/pull/93187 >From faecc5c3d88f2e205c62424e4c76df92f66ea4fe Mon Sep 17 00:00:00 2001 From: Corentin Jabot Date: Thu, 23 May 2024 14:58:49 +0200 Subject: [PATCH 1/2] [Clang] Only check exprs that might be immediate

[clang] [llvm] [AArch64][SME] Add intrinsics for vector groups ZERO (PR #88114)

2024-05-23 Thread via cfe-commits
https://github.com/Lukacma updated https://github.com/llvm/llvm-project/pull/88114 >From c44bd42f8011dd09771fda50a76a7321342c2b2f Mon Sep 17 00:00:00 2001 From: Marian Lukac Date: Thu, 4 Apr 2024 14:36:54 + Subject: [PATCH 1/5] WIP --- clang/include/clang/Basic/arm_sme.td | 29

[clang] [Clang] Only check exprs that might be immediate escalating in evaluated contexts (PR #93187)

2024-05-23 Thread via cfe-commits
@@ -5146,6 +5153,12 @@ class Sema final : public SemaBase { return ExprEvalContexts.back(); }; + const ExpressionEvaluationContextRecord () const { +assert(ExprEvalContexts.size() >= 2 && + "Must be in an expression evaluation context"); +return

[clang] [llvm] [AArch64][SME] Add intrinsics for vector groups ZERO (PR #88114)

2024-05-23 Thread via cfe-commits
https://github.com/Lukacma updated https://github.com/llvm/llvm-project/pull/88114 >From c44bd42f8011dd09771fda50a76a7321342c2b2f Mon Sep 17 00:00:00 2001 From: Marian Lukac Date: Thu, 4 Apr 2024 14:36:54 + Subject: [PATCH 1/4] WIP --- clang/include/clang/Basic/arm_sme.td | 29

[clang] [Clang] Only check exprs that might be immediate escalating in evaluated contexts (PR #93187)

2024-05-23 Thread Mariya Podchishchaeva via cfe-commits
@@ -769,6 +769,8 @@ Bug Fixes to C++ Support - Fixed a crash when trying to emit captures in a lambda call operator with an explicit object parameter that is called on a derived type of the lambda. Fixes (#GH87210), (GH89541). +- Clang no longer try to check if an

[clang] [Clang] Only check exprs that might be immediate escalating in evaluated contexts (PR #93187)

2024-05-23 Thread Mariya Podchishchaeva via cfe-commits
@@ -5146,6 +5153,12 @@ class Sema final : public SemaBase { return ExprEvalContexts.back(); }; + const ExpressionEvaluationContextRecord () const { +assert(ExprEvalContexts.size() >= 2 && + "Must be in an expression evaluation context"); +return

[clang] 05c154f - [SME] Add intrinsics for FCVT(wid.) and FCVTL (#90215)

2024-05-23 Thread via cfe-commits
Author: Lukacma Date: 2024-05-23T14:32:34+01:00 New Revision: 05c154f2bcba34f002b1f0c22c7a9e9614e9d83c URL: https://github.com/llvm/llvm-project/commit/05c154f2bcba34f002b1f0c22c7a9e9614e9d83c DIFF: https://github.com/llvm/llvm-project/commit/05c154f2bcba34f002b1f0c22c7a9e9614e9d83c.diff LOG:

[clang] [llvm] [SME] Add intrinsics for FCVT(wid.) and FCVTL (PR #90215)

2024-05-23 Thread via cfe-commits
https://github.com/Lukacma closed https://github.com/llvm/llvm-project/pull/90215 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] Fix more diagnostic wording for style; NFC (PR #93190)

2024-05-23 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: All of the issues were found using some new tooling I've not yet put up for review. The changes were largely mechanical (uppercase->lowercase, remove trailing punctuation), but there were some surgical fixes to grammar, punctuation, etc. Also, if the diagnostic was not

[clang] [llvm] [AMDGPU][WIP] Extend readlane, writelane and readfirstlane intrinsic lowering for generic types (PR #89217)

2024-05-23 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm commented: Should lose the [WIP] in the title https://github.com/llvm/llvm-project/pull/89217 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Analyzer][CFG] Correctly handle rebuilt default arg and default init expression (PR #91879)

2024-05-23 Thread via cfe-commits
https://github.com/yronglin updated https://github.com/llvm/llvm-project/pull/91879 >From f7b2ae00eebb272e0e5e221608ec3a36146a5d21 Mon Sep 17 00:00:00 2001 From: yronglin Date: Sun, 12 May 2024 14:42:09 +0800 Subject: [PATCH 1/5] [Analyzer][CFG] Correctly handle rebuilted default arg and

[clang] [flang] Fix more diagnostic wording for style; NFC (PR #93190)

2024-05-23 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Aaron Ballman (AaronBallman) Changes This tries to fix all of the places where a diagnostic message starts with a capital letter (other than acroynyms or proper nouns) or ends with punctuation (other than a question mark). This is in

[clang] [Analyzer][CFG] Correctly handle rebuilt default arg and default init expression (PR #91879)

2024-05-23 Thread via cfe-commits
@@ -1114,17 +1114,16 @@ void fCXX11MemberInitTest1() { CXX11MemberInitTest1(); } +#ifdef PEDANTIC yronglin wrote: done https://github.com/llvm/llvm-project/pull/91879 ___ cfe-commits mailing list

[clang] [Analyzer][CFG] Correctly handle rebuilt default arg and default init expression (PR #91879)

2024-05-23 Thread via cfe-commits
@@ -1964,39 +1964,55 @@ void ExprEngine::Visit(const Stmt *S, ExplodedNode *Pred, case Stmt::CXXDefaultArgExprClass: case Stmt::CXXDefaultInitExprClass: { Bldr.takeNodes(Pred); - ExplodedNodeSet PreVisit; -

[clang] [Analyzer][CFG] Correctly handle rebuilt default arg and default init expression (PR #91879)

2024-05-23 Thread via cfe-commits
@@ -1964,39 +1964,55 @@ void ExprEngine::Visit(const Stmt *S, ExplodedNode *Pred, case Stmt::CXXDefaultArgExprClass: case Stmt::CXXDefaultInitExprClass: { Bldr.takeNodes(Pred); - ExplodedNodeSet PreVisit; -

[clang] [Analyzer][CFG] Correctly handle rebuilt default arg and default init expression (PR #91879)

2024-05-23 Thread via cfe-commits
@@ -1964,39 +1964,55 @@ void ExprEngine::Visit(const Stmt *S, ExplodedNode *Pred, case Stmt::CXXDefaultArgExprClass: case Stmt::CXXDefaultInitExprClass: { Bldr.takeNodes(Pred); - ExplodedNodeSet PreVisit; -

[clang] [llvm] [AMDGPU][Clang] Add check of size for __builtin_amdgcn_global_load_lds (PR #93064)

2024-05-23 Thread Matt Arsenault via cfe-commits
@@ -12385,4 +12385,8 @@ def err_acc_reduction_composite_type def err_acc_reduction_composite_member_type :Error< "OpenACC 'reduction' composite variable must not have non-scalar field">; def note_acc_reduction_composite_member_loc : Note<"invalid field is here">; + +//

[clang] [llvm] [AMDGPU][Clang] Add check of size for __builtin_amdgcn_global_load_lds (PR #93064)

2024-05-23 Thread Matt Arsenault via cfe-commits
@@ -0,0 +1,13 @@ +// RUN: %clang_cc1 -cl-std=CL2.0 -O0 -triple amdgcn-unknown-unknown -target-cpu gfx940 -S -verify -o - %s +// REQUIRES: amdgpu-registered-target + +typedef unsigned int u32; + +void test_global_load_lds_unsupported_size(global u32* src, local u32 *dst, u32

[clang] [Analyzer][CFG] Correctly handle rebuilt default arg and default init expression (PR #91879)

2024-05-23 Thread via cfe-commits
https://github.com/yronglin updated https://github.com/llvm/llvm-project/pull/91879 >From f7b2ae00eebb272e0e5e221608ec3a36146a5d21 Mon Sep 17 00:00:00 2001 From: yronglin Date: Sun, 12 May 2024 14:42:09 +0800 Subject: [PATCH 1/4] [Analyzer][CFG] Correctly handle rebuilted default arg and

[clang] [llvm] [AMDGPU][Clang] Add check of size for __builtin_amdgcn_global_load_lds (PR #93064)

2024-05-23 Thread Shilei Tian via cfe-commits
https://github.com/shiltian updated https://github.com/llvm/llvm-project/pull/93064 >From e12473d466d7b354ecff0b8ea553b64d3059e1cf Mon Sep 17 00:00:00 2001 From: Shilei Tian Date: Thu, 23 May 2024 09:07:31 -0400 Subject: [PATCH] [AMDGPU][Clang] Add check of size for

[clang] [lldb] [llvm] Remove some `try_compile` CMake checks for compiler flags (PR #92953)

2024-05-23 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll closed https://github.com/llvm/llvm-project/pull/92953 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 4feae05 - Remove some `try_compile` CMake checks for compiler flags (#92953)

2024-05-23 Thread via cfe-commits
Author: Vlad Serebrennikov Date: 2024-05-23T17:05:41+04:00 New Revision: 4feae05c6abda364a9295aecfa600d7d4e7dfeb6 URL: https://github.com/llvm/llvm-project/commit/4feae05c6abda364a9295aecfa600d7d4e7dfeb6 DIFF:

[clang] [Clang] Only check exprs that might be immediate escalating in evaluated contexts (PR #93187)

2024-05-23 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: cor3ntin (cor3ntin) Changes As per https://eel.is/c++draft/expr.const#17 Fixes #91308 --- Full diff: https://github.com/llvm/llvm-project/pull/93187.diff 4 Files Affected: - (modified) clang/docs/ReleaseNotes.rst (+2) - (modified)

[clang] [Clang] Only check exprs that might be immediate escalating in evaluated contexts (PR #93187)

2024-05-23 Thread via cfe-commits
https://github.com/cor3ntin created https://github.com/llvm/llvm-project/pull/93187 As per https://eel.is/c++draft/expr.const#17 Fixes #91308 >From faecc5c3d88f2e205c62424e4c76df92f66ea4fe Mon Sep 17 00:00:00 2001 From: Corentin Jabot Date: Thu, 23 May 2024 14:58:49 +0200 Subject: [PATCH]

[clang] [llvm] [clang] Introduce target-specific `Sema` components (PR #93179)

2024-05-23 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: > Should update the GitHub autolabeler paths for the targets if they don't get > caught talready AMDGPU has been already caught, I updated the rest. Thank you! https://github.com/llvm/llvm-project/pull/93179 ___ cfe-commits mailing

[clang] [llvm] Reland "[X86] Remove knl/knm specific ISAs supports (#92883)" (PR #93136)

2024-05-23 Thread Simon Pilgrim via cfe-commits
RKSimon wrote: Not sure - CI checks aren't running either https://github.com/llvm/llvm-project/pull/93136 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Introduce target-specific `Sema` components (PR #93179)

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

[clang] [clang] Introduce target-specific `Sema` components (PR #93179)

2024-05-23 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm commented: Should update the GitHub autolabeler paths for the targets https://github.com/llvm/llvm-project/pull/93179 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] 01f143d - [clang] fix printing of canonical template template parameters (#93124)

2024-05-23 Thread via cfe-commits
Author: Matheus Izvekov Date: 2024-05-23T09:27:40-03:00 New Revision: 01f143dd39dc14029943dcf6eb2f7bbc2d82d6d4 URL: https://github.com/llvm/llvm-project/commit/01f143dd39dc14029943dcf6eb2f7bbc2d82d6d4 DIFF:

[clang] [clang] fix printing of canonical template template parameters (PR #93124)

2024-05-23 Thread Matheus Izvekov via cfe-commits
https://github.com/mizvekov closed https://github.com/llvm/llvm-project/pull/93124 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Introduce target-specific `Sema` components (PR #93179)

2024-05-23 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: The only thing clang-format complain about is switches for builtins for ARM, Hexagon, MIPS, and SystemZ. I don't feel like it makes improvements there, but open for input from contributors in those areas. https://github.com/llvm/llvm-project/pull/93179

[clang] [clang-tools-extra] [clang-tidy][dataflow] Add `bugprone-null-check-after-dereference` check (PR #84166)

2024-05-23 Thread via cfe-commits
Discookie wrote: gentle ping @martinboehme @gribozavr https://github.com/llvm/llvm-project/pull/84166 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Introduce target-specific `Sema` components (PR #93179)

2024-05-23 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 781b13538e55a42b2d02bb4d21779f15ff8a640c 6e68c960bde622eb244f726d97982219b08a68bf --

[clang] [clang] Introduce target-specific `Sema` components (PR #93179)

2024-05-23 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-systemz Author: Vlad Serebrennikov (Endilll) Changes This patch introduces `SemaAMDGPU`, `SemaARM`, `SemaBPF`, `SemaHexagon`, `SemaLoongArch`, `SemaMIPS`, `SemaNVPTX`, `SemaPPC`, `SemaSystemZ`, `SemaWasm`. This continues previous efforts to

[clang] [clang] Introduce target-specific `Sema` components (PR #93179)

2024-05-23 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-amdgpu Author: Vlad Serebrennikov (Endilll) Changes This patch introduces `SemaAMDGPU`, `SemaARM`, `SemaBPF`, `SemaHexagon`, `SemaLoongArch`, `SemaMIPS`, `SemaNVPTX`, `SemaPPC`, `SemaSystemZ`, `SemaWasm`. This continues previous efforts to

[clang] [clang][dataflow] Fix handling of cyclical data structures in HTMLLogger. (PR #66887)

2024-05-23 Thread via cfe-commits
@@ -88,10 +88,12 @@ class ModelDumper { void dump(Value ) { JOS.attribute("value_id", llvm::to_string()); -if (!Visited.insert().second) - return; - JOS.attribute("kind", debugString(V.getKind())); +if (!Visited.insert().second) { +

[clang] fbd643f - [clang][Interp] Don't try to activate root pointers

2024-05-23 Thread Timm Bäder via cfe-commits
Author: Timm Bäder Date: 2024-05-23T14:01:32+02:00 New Revision: fbd643fb22607b933a4e129ae86a7334b62c9b55 URL: https://github.com/llvm/llvm-project/commit/fbd643fb22607b933a4e129ae86a7334b62c9b55 DIFF: https://github.com/llvm/llvm-project/commit/fbd643fb22607b933a4e129ae86a7334b62c9b55.diff

[clang] 84729c9 - [clang][Interp] Don't diagnose ObjCIvarDecls as invalid reads

2024-05-23 Thread Timm Bäder via cfe-commits
Author: Timm Bäder Date: 2024-05-23T13:47:54+02:00 New Revision: 84729c9df30b29d5f4e903ad71235a6aa0c764d6 URL: https://github.com/llvm/llvm-project/commit/84729c9df30b29d5f4e903ad71235a6aa0c764d6 DIFF: https://github.com/llvm/llvm-project/commit/84729c9df30b29d5f4e903ad71235a6aa0c764d6.diff

[clang] [clang] fix printing of canonical template template parameters (PR #93124)

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

[clang] [llvm] [AMDGPU][WIP] Extend readlane, writelane and readfirstlane intrinsic lowering for generic types (PR #89217)

2024-05-23 Thread Vikram Hegde via cfe-commits
vikramRH wrote: > > 1. What's the proper way to legalize f16 and bf16 for SDAG case without > > bitcasts ? (I would think "fp_extend -> LaneOp -> Fptrunc" is wrong) > > Bitcast to i16, anyext to i32, laneop, trunc to i16, bitcast to original type. > > Why wouldn't you use bitcasts? Just a

[clang] 1d0e8b2 - [clang][Interp] Remove a no longer needed dummy check

2024-05-23 Thread Timm Bäder via cfe-commits
Author: Timm Bäder Date: 2024-05-23T13:10:58+02:00 New Revision: 1d0e8b24001d854a848a3810b90244a6bc94cf03 URL: https://github.com/llvm/llvm-project/commit/1d0e8b24001d854a848a3810b90244a6bc94cf03 DIFF: https://github.com/llvm/llvm-project/commit/1d0e8b24001d854a848a3810b90244a6bc94cf03.diff

[clang] [clang][analyzer] Move checker 'cert.pos.34c' (in alpha.security) into 'PutenvStackArray' (PR #92424)

2024-05-23 Thread Balázs Kéri via cfe-commits
https://github.com/balazske closed https://github.com/llvm/llvm-project/pull/92424 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 3c23047 - [clang][analyzer] Move checker 'cert.pos.34c' (in alpha.security) into 'PutenvStackArray' (#92424)

2024-05-23 Thread via cfe-commits
Author: Balázs Kéri Date: 2024-05-23T12:56:16+02:00 New Revision: 3c23047413957024294872e38c27707c71d05805 URL: https://github.com/llvm/llvm-project/commit/3c23047413957024294872e38c27707c71d05805 DIFF: https://github.com/llvm/llvm-project/commit/3c23047413957024294872e38c27707c71d05805.diff

[clang] [llvm] [coro] Lower `llvm.coro.await.suspend.handle` to resume with tail call (PR #89751)

2024-05-23 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: Oh, it looks like some bots are not happy. I send the PR at https://github.com/llvm/llvm-project/pull/93167 https://github.com/llvm/llvm-project/pull/89751 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [clang] Add /Zc:__STDC__ flag to clang-cl (PR #68690)

2024-05-23 Thread via cfe-commits
https://github.com/xbjfk updated https://github.com/llvm/llvm-project/pull/68690 >From 26fdd2ef8b94d78c295afe5c6b811225b56e9f4e Mon Sep 17 00:00:00 2001 From: Reagan Bohan Date: Sun, 10 Mar 2024 01:49:37 + Subject: [PATCH] [clang] Add /Zc:__STDC__ flag to clang-cl This commit adds the

[clang] [clang] Introduce `SemaX86` (PR #93098)

2024-05-23 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: @RKSimon Not at the moment. The current goal is to reduce amount of declarations in `Sema`, and target-specific functions are easy to move out and, importantly, teach where new ones should be placed. No functional changes intended. I don't know much about our CodeGen, so I'm

[clang] [llvm] [coro] Lower `llvm.coro.await.suspend.handle` to resume with tail call (PR #89751)

2024-05-23 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: I land it directly given it looks straightforward and trivial in https://github.com/llvm/llvm-project/commit/31f1590e4fb324c43dc36199587c453e27b6f6fa See the commit message if you're interested. https://github.com/llvm/llvm-project/pull/89751

[clang] [llvm] IR: Add module level attribution language-standard (PR #93159)

2024-05-23 Thread YunQiang Su via cfe-commits
https://github.com/wzssyqa closed https://github.com/llvm/llvm-project/pull/93159 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] IR: Add module level attribution language-standard (PR #93159)

2024-05-23 Thread YunQiang Su via cfe-commits
wzssyqa wrote: Let's close it. https://github.com/llvm/llvm-project/pull/93159 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AMDGPU][WIP] Extend readlane, writelane and readfirstlane intrinsic lowering for generic types (PR #89217)

2024-05-23 Thread Matt Arsenault via cfe-commits
@@ -6086,6 +6086,62 @@ static SDValue lowerBALLOTIntrinsic(const SITargetLowering , SDNode *N, DAG.getConstant(0, SL, MVT::i32), DAG.getCondCode(ISD::SETNE)); } +static SDValue lowerLaneOp(const SITargetLowering , SDNode *N, + SelectionDAG ) {

[clang] [llvm] [AMDGPU][WIP] Extend readlane, writelane and readfirstlane intrinsic lowering for generic types (PR #89217)

2024-05-23 Thread Matt Arsenault via cfe-commits
@@ -5456,43 +5444,32 @@ bool AMDGPULegalizerInfo::legalizeLaneOp(LegalizerHelper , if ((Size % 32) == 0) { SmallVector PartialRes; unsigned NumParts = Size / 32; -auto IsS16Vec = Ty.isVector() && Ty.getElementType() == S16; +bool IsS16Vec = Ty.isVector() &&

[clang] 45a95c3 - [clang][Interp] Fix DeclRefExprs of void-typed dummy pointers

2024-05-23 Thread Timm Bäder via cfe-commits
Author: Timm Bäder Date: 2024-05-23T11:56:23+02:00 New Revision: 45a95c3c543c88a669cffd3f7ee2a1b7e02b44e8 URL: https://github.com/llvm/llvm-project/commit/45a95c3c543c88a669cffd3f7ee2a1b7e02b44e8 DIFF: https://github.com/llvm/llvm-project/commit/45a95c3c543c88a669cffd3f7ee2a1b7e02b44e8.diff

[clang] [llvm] IR: Add module level attribution language-standard (PR #93159)

2024-05-23 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm requested changes to this pull request. You cannot encode language standards in this. We should simply have different operations that provide the range of semantics and not make the IR modal https://github.com/llvm/llvm-project/pull/93159

[clang] 10dc3a8 - [clang][Interp] Fix empty InitListExprs for unions

2024-05-23 Thread Timm Bäder via cfe-commits
Author: Timm Bäder Date: 2024-05-23T11:48:33+02:00 New Revision: 10dc3a8e916d73291269e5e2b82dd22681489aa1 URL: https://github.com/llvm/llvm-project/commit/10dc3a8e916d73291269e5e2b82dd22681489aa1 DIFF: https://github.com/llvm/llvm-project/commit/10dc3a8e916d73291269e5e2b82dd22681489aa1.diff

[clang] [clang] Introduce `SemaX86` (PR #93098)

2024-05-23 Thread Simon Pilgrim via cfe-commits
RKSimon wrote: @endilll Thanks for working on this - out of interest are you intending to do this for CGBuiltin as well? Is the plan to no longer have to include all target builtins in all clang builds? https://github.com/llvm/llvm-project/pull/93098

[clang] f81da75 - [Clang][AArch64] Use __clang_arm_builtin_alias for overloaded svreinterpret's (#92427)

2024-05-23 Thread via cfe-commits
Author: Sander de Smalen Date: 2024-05-23T10:42:11+01:00 New Revision: f81da75693fff6c2ffefbb3883e08f11b21ee643 URL: https://github.com/llvm/llvm-project/commit/f81da75693fff6c2ffefbb3883e08f11b21ee643 DIFF:

[clang] [Clang][AArch64] Use __clang_arm_builtin_alias for overloaded svreinterpret's (PR #92427)

2024-05-23 Thread Sander de Smalen via cfe-commits
https://github.com/sdesmalen-arm closed https://github.com/llvm/llvm-project/pull/92427 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] IR: Add module level attribution language-standard (PR #93159)

2024-05-23 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-codegen Author: YunQiang Su (wzssyqa) Changes The backend may have interest on the language-standard level of source file. Let's pass it to IR. In a ll file, it looks like language-standard = "gnu17" --- Full diff:

[clang] [llvm] IR: Add module level attribution language-standard (PR #93159)

2024-05-23 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-llvm-ir Author: YunQiang Su (wzssyqa) Changes The backend may have interest on the language-standard level of source file. Let's pass it to IR. In a ll file, it looks like language-standard = "gnu17" --- Full diff:

[clang] [llvm] IR: Add module level attribution language-standard (PR #93159)

2024-05-23 Thread YunQiang Su via cfe-commits
https://github.com/wzssyqa converted_to_draft https://github.com/llvm/llvm-project/pull/93159 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] IR: Add module level attribution language-standard (PR #93159)

2024-05-23 Thread YunQiang Su via cfe-commits
https://github.com/wzssyqa created https://github.com/llvm/llvm-project/pull/93159 The backend may have interest on the language-standard level of source file. Let's pass it to IR. In a ll file, it looks like language-standard = "gnu17" >From 3e413bae6ba18276e4d47075d48d656e4f732b5e Mon

[clang] [llvm] [MC,llvm-readobj,yaml2obj] Support CREL relocation format (PR #91280)

2024-05-23 Thread James Henderson via cfe-commits
@@ -934,10 +943,51 @@ void ELFWriter::WriteSecHdrEntry(uint32_t Name, uint32_t Type, uint64_t Flags, WriteWord(EntrySize); // sh_entsize } +template +static void encodeCrel(ArrayRef Relocs, raw_ostream ) { jh7370 wrote: Nit: `os` -> `OS`

[clang] [analyzer] Adding taint analysis capability to unix.Malloc checker (PR #92420)

2024-05-23 Thread Daniel Krupp via cfe-commits
dkrupp wrote: Thanks for the reviews. I updated the patch. @haoNoQ - I changed the report to non-fatal - I factored out the warning into a new checker optin.taint.TaintMalloc. This way the checker can be enabled separately. Of course, the alpha.security.taint.TaintPropagation checker is a

[clang] [llvm] [MC,llvm-readobj,yaml2obj] Support CREL relocation format (PR #91280)

2024-05-23 Thread James Henderson via cfe-commits
@@ -259,7 +260,7 @@ class ELFObjectWriter : public MCObjectWriter { void recordRelocation(MCAssembler , const MCAsmLayout , const MCFragment *Fragment, const MCFixup , MCValue Target, uint64_t ) override; - bool usesRela(const

[clang] [llvm] [MC,llvm-readobj,yaml2obj] Support CREL relocation format (PR #91280)

2024-05-23 Thread James Henderson via cfe-commits
@@ -86,6 +86,8 @@ DYNAMIC_TAG(RELRSZ, 35) // Size of Relr relocation table. DYNAMIC_TAG(RELR, 36)// Address of relocation table (Relr entries). DYNAMIC_TAG(RELRENT, 37) // Size of a Relr relocation entry. +DYNAMIC_TAG(CREL, 38) // CREL relocation table +

[clang] [llvm] [MC,llvm-readobj,yaml2obj] Support CREL relocation format (PR #91280)

2024-05-23 Thread James Henderson via cfe-commits
@@ -392,6 +393,70 @@ ELFFile::decode_relrs(Elf_Relr_Range relrs) const { return Relocs; } +template +uint64_t ELFFile::crelHeader(ArrayRef Content) const { + DataExtractor Data(Content, true, 8); // endian/class is irrelevant jh7370 wrote: Endian/class

[clang] [llvm] [MC,llvm-readobj,yaml2obj] Support CREL relocation format (PR #91280)

2024-05-23 Thread James Henderson via cfe-commits
@@ -474,9 +480,28 @@ struct Elf_Rel_Impl, true> : public Elf_Rel_Impl, false> { LLVM_ELF_IMPORT_TYPES(Endianness, true) static const bool IsRela = true; + static const bool IsCrel = false; Elf_Sxword r_addend; // Compute value for relocatable field by adding this.

[clang] [llvm] [MC,llvm-readobj,yaml2obj] Support CREL relocation format (PR #91280)

2024-05-23 Thread James Henderson via cfe-commits
@@ -392,6 +393,70 @@ ELFFile::decode_relrs(Elf_Relr_Range relrs) const { return Relocs; } +template +uint64_t ELFFile::crelHeader(ArrayRef Content) const { + DataExtractor Data(Content, true, 8); // endian/class is irrelevant + DataExtractor::Cursor Cur(0); + uint64_t

[clang] [llvm] [MC,llvm-readobj,yaml2obj] Support CREL relocation format (PR #91280)

2024-05-23 Thread James Henderson via cfe-commits
@@ -392,6 +393,70 @@ ELFFile::decode_relrs(Elf_Relr_Range relrs) const { return Relocs; } +template +uint64_t ELFFile::crelHeader(ArrayRef Content) const { + DataExtractor Data(Content, true, 8); // endian/class is irrelevant + DataExtractor::Cursor Cur(0); + uint64_t

[clang] [llvm] [MC,llvm-readobj,yaml2obj] Support CREL relocation format (PR #91280)

2024-05-23 Thread James Henderson via cfe-commits
@@ -61,6 +61,9 @@ class MCTargetOptions { bool Dwarf64 : 1; + // Use CREL relocation format for ELF. + bool Crel = false; jh7370 wrote: Nit here and elsewhere: Is "Crel" a correct way of spelling this? Should it be "CRel" (for "CompressedRelocations")?

[clang] [llvm] [MC,llvm-readobj,yaml2obj] Support CREL relocation format (PR #91280)

2024-05-23 Thread James Henderson via cfe-commits
@@ -474,9 +480,28 @@ struct Elf_Rel_Impl, true> : public Elf_Rel_Impl, false> { LLVM_ELF_IMPORT_TYPES(Endianness, true) static const bool IsRela = true; + static const bool IsCrel = false; Elf_Sxword r_addend; // Compute value for relocatable field by adding this.

[clang] [llvm] [MC,llvm-readobj,yaml2obj] Support CREL relocation format (PR #91280)

2024-05-23 Thread James Henderson via cfe-commits
@@ -934,10 +943,51 @@ void ELFWriter::WriteSecHdrEntry(uint32_t Name, uint32_t Type, uint64_t Flags, WriteWord(EntrySize); // sh_entsize } +template +static void encodeCrel(ArrayRef Relocs, raw_ostream ) { + uint OffsetMask = 8, Offset = 0, Addend = 0; + uint32_t Symidx

[clang] [llvm] [MC,llvm-readobj,yaml2obj] Support CREL relocation format (PR #91280)

2024-05-23 Thread James Henderson via cfe-commits
https://github.com/jh7370 commented: I've made a start on this, but have run out of time. Will come back to reviewing it another day. https://github.com/llvm/llvm-project/pull/91280 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [llvm] [MC,llvm-readobj,yaml2obj] Support CREL relocation format (PR #91280)

2024-05-23 Thread James Henderson via cfe-commits
@@ -321,6 +321,11 @@ class ELFFile { std::vector decode_relrs(Elf_Relr_Range relrs) const; + uint64_t crelHeader(ArrayRef Content) const; jh7370 wrote: It's not clear without looking at the method definition what the return value actually represents.

[clang] [llvm] [MC,llvm-readobj,yaml2obj] Support CREL relocation format (PR #91280)

2024-05-23 Thread James Henderson via cfe-commits
https://github.com/jh7370 edited https://github.com/llvm/llvm-project/pull/91280 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [coro] Lower `llvm.coro.await.suspend.handle` to resume with tail call (PR #89751)

2024-05-23 Thread Chuanqi Xu via cfe-commits
ChuanqiXu9 wrote: It is pretty interesting that I can pass the test by: ``` $git diff -U10 diff --git a/llvm/lib/Transforms/Coroutines/CoroSplit.cpp b/llvm/lib/Transforms/Coroutines/CoroSplit.cpp index 450ea8234371..003bfbf7138a 100644 --- a/llvm/lib/Transforms/Coroutines/CoroSplit.cpp +++

[clang] [analyzer] Adding taint analysis capability to unix.Malloc checker (PR #92420)

2024-05-23 Thread Daniel Krupp via cfe-commits
https://github.com/dkrupp updated https://github.com/llvm/llvm-project/pull/92420 >From 80767176cbe8e5717c5f42b113f305d81b635cb9 Mon Sep 17 00:00:00 2001 From: Daniel Krupp Date: Tue, 30 Apr 2024 15:20:52 +0200 Subject: [PATCH 1/2] [analyzer] Adding taint analysis capability to unix.Malloc

[clang] [llvm] [AMDGPU][WIP] Extend readlane, writelane and readfirstlane intrinsic lowering for generic types (PR #89217)

2024-05-23 Thread Jay Foad via cfe-commits
jayfoad wrote: > 1. What's the proper way to legalize f16 and bf16 for SDAG case without > bitcasts ? (I would think "fp_extend -> LaneOp -> Fptrunc" is wrong) Bitcast to i16, anyext to i32, laneop, trunc to i16, bitcast to original type. Why wouldn't you use bitcasts?

[clang] [clang][FMV] Allow declaration of function versions in namespaces. (PR #93044)

2024-05-23 Thread Alexandros Lamprineas via cfe-commits
https://github.com/labrinea closed https://github.com/llvm/llvm-project/pull/93044 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 8930ba9 - [clang][FMV] Allow declaration of function versions in namespaces. (#93044)

2024-05-23 Thread via cfe-commits
Author: Alexandros Lamprineas Date: 2024-05-23T10:09:22+01:00 New Revision: 8930ba98e01bc66949e482b396f8389d64388359 URL: https://github.com/llvm/llvm-project/commit/8930ba98e01bc66949e482b396f8389d64388359 DIFF:

[clang] [llvm] [AMDGPU][WIP] Extend readlane, writelane and readfirstlane intrinsic lowering for generic types (PR #89217)

2024-05-23 Thread Vikram Hegde via cfe-commits
vikramRH wrote: updated the GIsel legalizer, I still have couple of questions for SDAG case though, 1. What's the proper way to legalize f16 and bf16 for SDAG case without bitcasts ? (I would think "fp_extend -> LaneOp -> Fptrunc" is wrong) 2. For scalar cases such as i64, f64, i128 .. (i.e

[clang-tools-extra] [clang-tidy] Add new check bugprone-tagged-union-member-count (PR #89925)

2024-05-23 Thread via cfe-commits
___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Add new check bugprone-tagged-union-member-count (PR #89925)

2024-05-23 Thread via cfe-commits
=?utf-8?b?R8OhYm9yIFTDs3RodsOhcmk=?= Message-ID: In-Reply-To: @@ -0,0 +1,145 @@ +//===--- TaggedUnionMemberCountCheck.cpp - clang-tidy -===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See

[clang-tools-extra] [clang-tidy] Add new check bugprone-tagged-union-member-count (PR #89925)

2024-05-23 Thread via cfe-commits
___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Add new check bugprone-tagged-union-member-count (PR #89925)

2024-05-23 Thread via cfe-commits
=?utf-8?b?R8OhYm9yIFTDs3RodsOhcmk=?= Message-ID: In-Reply-To: @@ -0,0 +1,145 @@ +//===--- TaggedUnionMemberCountCheck.cpp - clang-tidy -===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See

[clang-tools-extra] [clang-tidy] Add new check bugprone-tagged-union-member-count (PR #89925)

2024-05-23 Thread via cfe-commits
=?utf-8?b?R8OhYm9yIFTDs3RodsOhcmk=?= Message-ID: In-Reply-To: @@ -0,0 +1,37 @@ +//===--- TaggedUnionMemberCountCheck.h - clang-tidy -*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See

[clang-tools-extra] [clang-tidy] Add new check bugprone-tagged-union-member-count (PR #89925)

2024-05-23 Thread via cfe-commits
=?utf-8?b?R8OhYm9yIFTDs3RodsOhcmk=?= Message-ID: In-Reply-To: @@ -0,0 +1,37 @@ +//===--- TaggedUnionMemberCountCheck.h - clang-tidy -*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See

[clang-tools-extra] [clang-tidy] Add new check bugprone-tagged-union-member-count (PR #89925)

2024-05-23 Thread via cfe-commits
=?utf-8?b?R8OhYm9yIFTDs3RodsOhcmk=?= Message-ID: In-Reply-To: https://github.com/whisperity edited https://github.com/llvm/llvm-project/pull/89925 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang-tools-extra] [clang-tidy] Add new check bugprone-tagged-union-member-count (PR #89925)

2024-05-23 Thread via cfe-commits
=?utf-8?b?R8OhYm9yIFTDs3RodsOhcmk=?= Message-ID: In-Reply-To: @@ -0,0 +1,150 @@ +// RUN: %check_clang_tidy -std=c++98-or-later %s bugprone-tagged-union-member-count %t \ +// RUN: -config='{CheckOptions: { \ +// RUN: bugprone-tagged-union-member-count.StrictMode: 1, \

[clang-tools-extra] [clang-tidy] Add new check bugprone-tagged-union-member-count (PR #89925)

2024-05-23 Thread via cfe-commits
=?utf-8?b?R8OhYm9yIFTDs3RodsOhcmk=?= Message-ID: In-Reply-To: https://github.com/whisperity requested changes to this pull request. https://github.com/llvm/llvm-project/pull/89925 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[clang] [clang][analyzer] Move checker 'cert.pos.34c' (in alpha.security) into 'PutenvStackArray' (PR #92424)

2024-05-23 Thread Balázs Kéri via cfe-commits
https://github.com/balazske updated https://github.com/llvm/llvm-project/pull/92424 From 769523d392204eac6c48cb80a2282212f3edbbe4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bal=C3=A1zs=20K=C3=A9ri?= Date: Fri, 10 May 2024 17:30:23 +0200 Subject: [PATCH 1/4] [clang][analyzer] Move checker

[clang] [llvm] [AMDGPU][WIP] Extend readlane, writelane and readfirstlane intrinsic lowering for generic types (PR #89217)

2024-05-23 Thread Vikram Hegde via cfe-commits
@@ -5387,6 +5387,192 @@ bool AMDGPULegalizerInfo::legalizeDSAtomicFPIntrinsic(LegalizerHelper , return true; } +bool AMDGPULegalizerInfo::legalizeLaneOp(LegalizerHelper , + MachineInstr , +

[clang] [clang][FMV] Allow declaration of function versions in namespaces. (PR #93044)

2024-05-23 Thread Alexandros Lamprineas via cfe-commits
https://github.com/labrinea updated https://github.com/llvm/llvm-project/pull/93044 >From ba2b8b53d80e17b1477a7d6fed51f0450bc539a3 Mon Sep 17 00:00:00 2001 From: Alexandros Lamprineas Date: Wed, 22 May 2024 15:55:58 +0100 Subject: [PATCH] [clang][FMV] Allow declaration of function versions in

[clang] [clang][FMV] Allow declaration of function versions in namespaces. (PR #93044)

2024-05-23 Thread Alexandros Lamprineas via cfe-commits
https://github.com/labrinea updated https://github.com/llvm/llvm-project/pull/93044 >From 730c8c5081862b330d66455a0495e9d317da1795 Mon Sep 17 00:00:00 2001 From: Alexandros Lamprineas Date: Wed, 22 May 2024 15:55:58 +0100 Subject: [PATCH] [clang][FMV] Allow declaration of function versions in

[clang] [clang][FMV] Allow declaration of function versions in namespaces. (PR #93044)

2024-05-23 Thread Alexandros Lamprineas via cfe-commits
@@ -11868,8 +11868,10 @@ static bool CheckMultiVersionFunction(Sema , FunctionDecl *NewFD, return false; if (!OldDecl || !OldDecl->getAsFunction() || - OldDecl->getDeclContext()->getRedeclContext() != - NewFD->getDeclContext()->getRedeclContext()) { +

[clang] 335e00f - [clang][Interp][NFC] Add another union test case

2024-05-23 Thread Timm Bäder via cfe-commits
Author: Timm Bäder Date: 2024-05-23T10:21:02+02:00 New Revision: 335e00faaf74f3f7463b32a415d39af0973f521f URL: https://github.com/llvm/llvm-project/commit/335e00faaf74f3f7463b32a415d39af0973f521f DIFF: https://github.com/llvm/llvm-project/commit/335e00faaf74f3f7463b32a415d39af0973f521f.diff

[clang] 951b13d - [clang][Interp][NFC] Save IsUnion bit for Records

2024-05-23 Thread Timm Bäder via cfe-commits
Author: Timm Bäder Date: 2024-05-23T10:21:02+02:00 New Revision: 951b13d9a7220d761b1ee0dc09a50b635692ecf8 URL: https://github.com/llvm/llvm-project/commit/951b13d9a7220d761b1ee0dc09a50b635692ecf8 DIFF: https://github.com/llvm/llvm-project/commit/951b13d9a7220d761b1ee0dc09a50b635692ecf8.diff

[clang] [analyzer] Adding taint analysis capability to unix.Malloc checker (PR #92420)

2024-05-23 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 1cde1240ed6e45012d7510f4aa39badbdb4a4721 b31ec694c88635404b252f00472140e83083fd02 --

[clang] [analyzer] Adding taint analysis capability to unix.Malloc checker (PR #92420)

2024-05-23 Thread Daniel Krupp via cfe-commits
https://github.com/dkrupp updated https://github.com/llvm/llvm-project/pull/92420 >From 80767176cbe8e5717c5f42b113f305d81b635cb9 Mon Sep 17 00:00:00 2001 From: Daniel Krupp Date: Tue, 30 Apr 2024 15:20:52 +0200 Subject: [PATCH 1/2] [analyzer] Adding taint analysis capability to unix.Malloc

[clang] Reland #90786 ([BoundsSafety] Allow 'counted_by' attribute on pointers in structs in C) (PR #93121)

2024-05-23 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll commented: `Sema.h` changes look good. https://github.com/llvm/llvm-project/pull/93121 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

<    5   6   7   8   9   10   11   12   13   14   >