[clang] [Clang][TableGen] Use StringRef::str() instead of std::string() cast (PR #113645)

2024-10-25 Thread Kazu Hirata via cfe-commits
@@ -54,19 +54,18 @@ class FlattenedSpelling { const Record &OriginalSpelling; public: - FlattenedSpelling(const std::string &Variety, const std::string &Name, + FlattenedSpelling(const std::string &Variety, StringRef Name, const std::string &Namespace,

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

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

[clang] [llvm] [BPF] Add load-acquire and store-release instructions under -mcpu=v4 (PR #108636)

2024-10-25 Thread Peilin Ye via cfe-commits
@@ -703,6 +715,39 @@ SDValue BPFTargetLowering::LowerSELECT_CC(SDValue Op, SelectionDAG &DAG) const { return DAG.getNode(BPFISD::SELECT_CC, DL, VTs, Ops); } +SDValue BPFTargetLowering::LowerATOMIC_LOAD(SDValue Op, +SelectionDAG &D

[clang] [llvm] Expose format (attribute) info for function declarations in Clang Index API (PR #113754)

2024-10-25 Thread AR Visions via cfe-commits
https://github.com/ar-visions edited https://github.com/llvm/llvm-project/pull/113754 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Expose format (attribute) info for function declarations in Clang Index API (PR #113754)

2024-10-25 Thread AR Visions via cfe-commits
https://github.com/ar-visions edited https://github.com/llvm/llvm-project/pull/113754 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Expose format (attribute) info for function declarations in Clang Index API (PR #113754)

2024-10-25 Thread AR Visions via cfe-commits
https://github.com/ar-visions edited https://github.com/llvm/llvm-project/pull/113754 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Expose format (attribute) info for function declarations in Clang Index API (PR #113754)

2024-10-25 Thread AR Visions via cfe-commits
https://github.com/ar-visions edited https://github.com/llvm/llvm-project/pull/113754 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Expose format (attribute) info for function declarations in Clang Index API (PR #113754)

2024-10-25 Thread AR Visions via cfe-commits
https://github.com/ar-visions edited https://github.com/llvm/llvm-project/pull/113754 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Expose C format (attribute) info for function declarations in Clang Index API (PR #113754)

2024-10-25 Thread AR Visions via cfe-commits
https://github.com/ar-visions edited https://github.com/llvm/llvm-project/pull/113754 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Expose C format (attribute) info for C function declarations in Clang Index API (PR #113754)

2024-10-25 Thread AR Visions via cfe-commits
https://github.com/ar-visions edited https://github.com/llvm/llvm-project/pull/113754 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Enable format info for C function declarations in Clang Index API, so we may have this context (PR #113754)

2024-10-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: AR Visions (ar-visions) Changes Enable format info for C function declarations in Clang Index API, so we may have this context clang_Cursor_getFormatAttr Get FormatAttr at Function Declaration clang_FormatAttr_getType

[clang] [llvm] Enable format info for C function declarations in Clang Index API, so we may have this context (PR #113754)

2024-10-25 Thread AR Visions via cfe-commits
https://github.com/ar-visions edited https://github.com/llvm/llvm-project/pull/113754 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Enable format info for C function declarations in Clang Index API, so we may have this context (PR #113754)

2024-10-25 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] [llvm] Enable format info for C function declarations in Clang Index API, so we may have this context (PR #113754)

2024-10-25 Thread AR Visions via cfe-commits
https://github.com/ar-visions created https://github.com/llvm/llvm-project/pull/113754 Enable format info for C function declarations in Clang Index API, so we may have this context clang_Cursor_getFormatAttr Get FormatAttr at Function Declaration clang_FormatAttr_getType

[clang] [llvm] [BPF] Add load-acquire and store-release instructions under -mcpu=v4 (PR #108636)

2024-10-25 Thread Peilin Ye via cfe-commits
@@ -48,6 +48,13 @@ def BPF_END : BPFArithOp<0xd>; def BPF_XCHG: BPFArithOp<0xe>; def BPF_CMPXCHG : BPFArithOp<0xf>; +class BPFAtomicLoadStoreOp val> { + bits<4> Value = val; +} + +def BPF_LOAD_ACQ : BPFAtomicLoadStoreOp<0x1>; +def BPF_STORE_REL : BPFAtomicLoadStoreOp<0xb

[clang] [clang-format] Print the names of unfound files in error messages (PR #113640)

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

[clang] [clang-format] Print the names of unfound files in error messages (PR #113640)

2024-10-25 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `fuchsia-x86_64-linux` running on `fuchsia-debian-64-us-central1-a-1` while building `clang` at step 4 "annotate". Full details are available at: https://lab.llvm.org/buildbot/#/builders/11/builds/7171 Here is the relevant p

[clang] 801f3a5 - [clang-format] Print the names of unfound files in error messages (#113640)

2024-10-25 Thread via cfe-commits
Author: Owen Pan Date: 2024-10-25T19:29:21-07:00 New Revision: 801f3a5400ca2fbcfdeb73fd744e8cce0cebc722 URL: https://github.com/llvm/llvm-project/commit/801f3a5400ca2fbcfdeb73fd744e8cce0cebc722 DIFF: https://github.com/llvm/llvm-project/commit/801f3a5400ca2fbcfdeb73fd744e8cce0cebc722.diff LOG:

[clang] [clang-format] Print the names of unfound files in error messages (PR #113640)

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

[clang] [ObjC] Insert method parameters in scope as they are parsed (PR #113745)

2024-10-25 Thread via cfe-commits
apple-fcloutier wrote: Failing test seems to be failing on main. https://github.com/llvm/llvm-project/pull/113745 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AMDGPU] Allow overload of __builtin_amdgcn_mov_dpp8 (PR #113610)

2024-10-25 Thread Matt Arsenault via cfe-commits
@@ -152,6 +115,44 @@ bool SemaAMDGPU::CheckAMDGCNBuiltinFunctionCall(unsigned BuiltinID, return false; } +bool SemaAMDGPU::CheckMovDPPFunctionCall(CallExpr *TheCall, unsigned NumArgs, arsenm wrote: Start with lowercase https://github.com/llvm/llvm-projec

[clang] [llvm] [BPF] Add load-acquire and store-release instructions under -mcpu=v4 (PR #108636)

2024-10-25 Thread Peilin Ye via cfe-commits
@@ -703,6 +715,39 @@ SDValue BPFTargetLowering::LowerSELECT_CC(SDValue Op, SelectionDAG &DAG) const { return DAG.getNode(BPFISD::SELECT_CC, DL, VTs, Ops); } +SDValue BPFTargetLowering::LowerATOMIC_LOAD(SDValue Op, +SelectionDAG &D

[clang] [llvm] [BPF] Add load-acquire and store-release instructions under -mcpu=v4 (PR #108636)

2024-10-25 Thread Peilin Ye via cfe-commits
@@ -703,6 +715,39 @@ SDValue BPFTargetLowering::LowerSELECT_CC(SDValue Op, SelectionDAG &DAG) const { return DAG.getNode(BPFISD::SELECT_CC, DL, VTs, Ops); } +SDValue BPFTargetLowering::LowerATOMIC_LOAD(SDValue Op, +SelectionDAG &D

[clang] [llvm] [BPF] Add load-acquire and store-release instructions under -mcpu=v4 (PR #108636)

2024-10-25 Thread Peilin Ye via cfe-commits
@@ -703,6 +715,39 @@ SDValue BPFTargetLowering::LowerSELECT_CC(SDValue Op, SelectionDAG &DAG) const { return DAG.getNode(BPFISD::SELECT_CC, DL, VTs, Ops); } +SDValue BPFTargetLowering::LowerATOMIC_LOAD(SDValue Op, +SelectionDAG &D

[clang] [Clang][Driver][AArch64] Add support for aarch64-amazon-linux triple (PR #109263)

2024-10-25 Thread Benjamin Herrenschmidt via cfe-commits
ozbenh wrote: So what should we (Amazon Linux) do to help with this ? I'm not the most familiar with autotools and cmake, I know we did some tweaking of triples in the version of llvm/clang we ship as part of the distro and it's very possible that we did something wrong. I would love to help m

[clang] [llvm] [BPF] Add load-acquire and store-release instructions under -mcpu=v4 (PR #108636)

2024-10-25 Thread Peilin Ye via cfe-commits
@@ -703,6 +715,39 @@ SDValue BPFTargetLowering::LowerSELECT_CC(SDValue Op, SelectionDAG &DAG) const { return DAG.getNode(BPFISD::SELECT_CC, DL, VTs, Ops); } +SDValue BPFTargetLowering::LowerATOMIC_LOAD(SDValue Op, +SelectionDAG &D

[clang] [Clang] Disable use of the counted_by attribute for whole struct pointers (PR #112636)

2024-10-25 Thread Jan Hendrik Farr via cfe-commits
Cydox wrote: But for now, I think we should merge #112786 into 19.1.3 so that the we can have that be the cutoff in the kernel. https://github.com/llvm/llvm-project/pull/112636 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm

[clang] [clang][CodeGen] Emit improved memory effects and return status for AsmStmt (PR #110510)

2024-10-25 Thread Bruno De Fraine via cfe-commits
brunodf-snps wrote: > Do we want nocapture markings on memory operands? I had a chance to discuss this with @nikic and he brought up the LEA instruction. The following would capture the address the `b` field: ``` asm("lea %0, %1" : "=r" (r) : "m" (p[i].b)); ``` I could not find back if you ar

[clang-tools-extra] [clangd] Support symbolTags for document symbol (PR #113669)

2024-10-25 Thread via cfe-commits
https://github.com/chouzz updated https://github.com/llvm/llvm-project/pull/113669 >From 02124e4cfd7dbc395d4974c7561d5f110980aaa5 Mon Sep 17 00:00:00 2001 From: chouzz Date: Fri, 25 Oct 2024 17:42:04 +0800 Subject: [PATCH] [clangd] Support symbolTags for document symbol --- clang-tools-extra/

[clang] [Clang] Disable use of the counted_by attribute for whole struct pointers (PR #112636)

2024-10-25 Thread Jan Hendrik Farr via cfe-commits
Cydox wrote: > ``` > struct S { > int foo; > char fam[N]; > }; > ``` > > Well, for N = 4 we have `sizeof(struct S) == 8` and for N = 5 we have > `sizeof(struct S) == 12` (due to alignment padding), therefore N = 4. That > makes `s->fam[4]` out-of-bounds. Am I wrong? Using this example

[clang] [Clang] Disable use of the counted_by attribute for whole struct pointers (PR #112636)

2024-10-25 Thread Jan Hendrik Farr via cfe-commits
Cydox wrote: We do have to consider though that when `__bdos` is for one of the maximum types (`type & 2 == 0`), it should actually return the largest allowed object that is consistent with the count. https://github.com/llvm/llvm-project/blob/3b88805ca20018ae202afd3aea39f4fa856a8c64/clang/docs

[clang] [lld] [llvm] [WebAssembly] Enable nontrapping-fptoint and bulk-memory by default. (PR #112049)

2024-10-25 Thread Derek Schuff via cfe-commits
https://github.com/dschuff approved this pull request. I think Emscripten is ready for this now, thanks for working on this! https://github.com/llvm/llvm-project/pull/112049 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org

[clang] [llvm] Adding splitdouble HLSL function (PR #109331)

2024-10-25 Thread Tex Riddell via cfe-commits
@@ -95,6 +99,126 @@ static void initializeAlloca(CodeGenFunction &CGF, AllocaInst *AI, Value *Size, I->addAnnotationMetadata("auto-init"); } +static Value *handleHlslSplitdouble(const CallExpr *E, CodeGenFunction *CGF) { + Value *Op0 = CGF->EmitScalarExpr(E->getArg(0)); +

[clang] [Clang] Disable use of the counted_by attribute for whole struct pointers (PR #112636)

2024-10-25 Thread Jan Hendrik Farr via cfe-commits
Cydox wrote: Example of both cases: https://godbolt.org/z/dhzG69sab https://github.com/llvm/llvm-project/pull/112636 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [BPF] Add load-acquire and store-release instructions under -mcpu=v4 (PR #108636)

2024-10-25 Thread Matt Arsenault via cfe-commits
@@ -703,6 +715,39 @@ SDValue BPFTargetLowering::LowerSELECT_CC(SDValue Op, SelectionDAG &DAG) const { return DAG.getNode(BPFISD::SELECT_CC, DL, VTs, Ops); } +SDValue BPFTargetLowering::LowerATOMIC_LOAD(SDValue Op, +SelectionDAG &D

[clang] [llvm] [BPF] Add load-acquire and store-release instructions under -mcpu=v4 (PR #108636)

2024-10-25 Thread Matt Arsenault via cfe-commits
@@ -703,6 +715,39 @@ SDValue BPFTargetLowering::LowerSELECT_CC(SDValue Op, SelectionDAG &DAG) const { return DAG.getNode(BPFISD::SELECT_CC, DL, VTs, Ops); } +SDValue BPFTargetLowering::LowerATOMIC_LOAD(SDValue Op, +SelectionDAG &D

[clang-tools-extra] [clang-tidy] Fix crash in modernize-use-designated-initializers check (PR #113688)

2024-10-25 Thread via cfe-commits
z1nke wrote: @nicovank Thanks! Release note has been added. What do others think about the argument? https://github.com/llvm/llvm-project/pull/113688 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/list

[clang] [llvm] [BPF] Add load-acquire and store-release instructions under -mcpu=v4 (PR #108636)

2024-10-25 Thread Peilin Ye via cfe-commits
https://github.com/peilin-ye edited https://github.com/llvm/llvm-project/pull/108636 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] add IsLineVectorLayoutCompatible type trait (PR #113730)

2024-10-25 Thread Finn Plummer via cfe-commits
inbelic wrote: Typo in filename: `TypeErros` -> `TypeErrors` https://github.com/llvm/llvm-project/pull/113730 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe

[clang] [Clang] Disable use of the counted_by attribute for whole struct pointers (PR #112636)

2024-10-25 Thread Jan Hendrik Farr via cfe-commits
Cydox wrote: > It's probably worthwhile to perform some analysis to see if using that to > calculate the new size results in allocation size changes in the kernel. If > not, then perhaps we could reinstate the "whole struct" code. This can calculation can result in both larger and smaller size

[clang] [llvm] [BPF] Add load-acquire and store-release instructions under -mcpu=v4 (PR #108636)

2024-10-25 Thread Peilin Ye via cfe-commits
@@ -703,6 +715,39 @@ SDValue BPFTargetLowering::LowerSELECT_CC(SDValue Op, SelectionDAG &DAG) const { return DAG.getNode(BPFISD::SELECT_CC, DL, VTs, Ops); } +SDValue BPFTargetLowering::LowerATOMIC_LOAD(SDValue Op, +SelectionDAG &D

[clang-tools-extra] [clang-tidy] Fix crash in modernize-use-designated-initializers check (PR #113688)

2024-10-25 Thread via cfe-commits
https://github.com/z1nke updated https://github.com/llvm/llvm-project/pull/113688 >From a2184027393c9e9605aaa08f1d1eef4b11cd9be1 Mon Sep 17 00:00:00 2001 From: czn Date: Fri, 25 Oct 2024 21:48:50 +0800 Subject: [PATCH 1/3] [clang-tidy] Fix crash in modernize-use-designated-initializers check

[clang] [llvm] Adding splitdouble HLSL function (PR #109331)

2024-10-25 Thread Justin Bogner via cfe-commits
@@ -0,0 +1,99 @@ +// RUN: %clang_cc1 -finclude-default-header -x hlsl -triple dxil-pc-shadermodel6.3-library %s -fnative-half-type -emit-llvm -O1 -o - | FileCheck %s +// RUN: %clang_cc1 -finclude-default-header -x hlsl -triple spirv-vulkan-library %s -fnative-half-type -emit-ll

[clang] [llvm] Adding splitdouble HLSL function (PR #109331)

2024-10-25 Thread Justin Bogner via cfe-commits
@@ -95,6 +99,126 @@ static void initializeAlloca(CodeGenFunction &CGF, AllocaInst *AI, Value *Size, I->addAnnotationMetadata("auto-init"); } +static Value *handleHlslSplitdouble(const CallExpr *E, CodeGenFunction *CGF) { + Value *Op0 = CGF->EmitScalarExpr(E->getArg(0)); +

[clang] [ObjC] Insert method parameters in scope as they are parsed (PR #113745)

2024-10-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (apple-fcloutier) Changes Before this change, ParseObjc would call the closing `MaybeParseAttributes` before it had created Objective-C `ParmVarDecl` objects (and associated name lookup entries), meaning that you could not reference

[clang] [ObjC] Insert method parameters in scope as they are parsed (PR #113745)

2024-10-25 Thread via cfe-commits
https://github.com/apple-fcloutier created https://github.com/llvm/llvm-project/pull/113745 Before this change, ParseObjc would call the closing `MaybeParseAttributes` before it had created Objective-C `ParmVarDecl` objects (and associated name lookup entries), meaning that you could not refer

[clang] [clang] constexpr built-in fma function. (PR #113020)

2024-10-25 Thread via cfe-commits
c8ef wrote: Hi @cor3ntin @tbaederr, since @hubert-reinterpretcast is unavailable for review, could you please help me find someone else who is capable and available to review this? Thank you! https://github.com/llvm/llvm-project/pull/113020 ___ cfe-c

[clang] [libc] [Clang] Implement resource directory headers for common GPU intrinsics (PR #110179)

2024-10-25 Thread Joseph Huber via cfe-commits
@@ -0,0 +1,76 @@ +//===-- gpuintrin.h - Generic GPU intrinsic functions -===// +// +// 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: Apa

[clang] [libc] [Clang] Implement resource directory headers for common GPU intrinsics (PR #110179)

2024-10-25 Thread Matt Arsenault via cfe-commits
@@ -0,0 +1,154 @@ +//===-- amdgpuintrin.h - AMDPGU intrinsic functions ---===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang] [WIP][Wunsafe-buffer-usage] False positives for & expression indexing constant size array (arr[anything & 0]) (PR #112284)

2024-10-25 Thread Malavika Samak via cfe-commits
https://github.com/malavikasamak updated https://github.com/llvm/llvm-project/pull/112284 >From 7e00765481784324450982e4789bf61bf66dbfdf Mon Sep 17 00:00:00 2001 From: MalavikaSamak Date: Fri, 11 Oct 2024 12:24:58 -0700 Subject: [PATCH] [Wunsafe-buffer-usage] False positives for & expression i

[clang] [clang][Driver][HIP] Add support for mixing AMDGCNSPIRV & concrete `offload-arch`s. (PR #113509)

2024-10-25 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > It's how it works today, I believe: `--offload-arch` unambiguously > establishes the toolchain It's pretty ambiguous, right now it mostly works through a combination of the file type and good guessing because the targets people care about now have distinct names. For OpenMP,

[clang] Add CHECK-LABEL to avoid source tree path sensitivity in test (PR #112461)

2024-10-25 Thread Finn Plummer via cfe-commits
https://github.com/inbelic approved this pull request. https://github.com/llvm/llvm-project/pull/112461 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] add IsLineVectorLayoutCompatible type trait (PR #113730)

2024-10-25 Thread Finn Plummer via cfe-commits
@@ -2163,6 +2163,49 @@ static void BuildFlattenedTypeList(QualType BaseTy, } } +bool SemaHLSL::IsLineVectorLayoutCompatibleType(clang::QualType QT) { + if (QT.isNull()) +return false; + + llvm::SmallVector QTTypes; + BuildFlattenedTypeList(QT, QTTypes); + + QualType

[clang] [libc] [Clang] Implement resource directory headers for common GPU intrinsics (PR #110179)

2024-10-25 Thread Joseph Huber via cfe-commits
@@ -0,0 +1,154 @@ +//===-- amdgpuintrin.h - AMDPGU intrinsic functions ---===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang] [libc] [Clang] Implement resource directory headers for common GPU intrinsics (PR #110179)

2024-10-25 Thread Joseph Huber via cfe-commits
@@ -0,0 +1,154 @@ +//===-- amdgpuintrin.h - AMDPGU intrinsic functions ---===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang] [Clang] Add a flag to include GPU startup files (PR #112025)

2024-10-25 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm approved this pull request. https://github.com/llvm/llvm-project/pull/112025 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Add a flag to include GPU startup files (PR #112025)

2024-10-25 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/112025 >From a02a27171801ad3f5618099b5035ef8185c2f835 Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Fri, 11 Oct 2024 12:21:49 -0500 Subject: [PATCH 1/5] [Clang] Add a flag to include GPU startup files Summary: The

[clang] [WIP][Wunsafe-buffer-usage] False positives for & expression indexing constant size array (arr[anything & 0]) (PR #112284)

2024-10-25 Thread Malavika Samak via cfe-commits
https://github.com/malavikasamak updated https://github.com/llvm/llvm-project/pull/112284 >From 80e593f62c9f00e6d639b870ec4912de2b971864 Mon Sep 17 00:00:00 2001 From: MalavikaSamak Date: Fri, 11 Oct 2024 12:24:58 -0700 Subject: [PATCH] [Wunsafe-buffer-usage] False positives for & expression i

[clang] [Clang] Add a flag to include GPU startup files (PR #112025)

2024-10-25 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 updated https://github.com/llvm/llvm-project/pull/112025 >From a02a27171801ad3f5618099b5035ef8185c2f835 Mon Sep 17 00:00:00 2001 From: Joseph Huber Date: Fri, 11 Oct 2024 12:21:49 -0500 Subject: [PATCH 1/4] [Clang] Add a flag to include GPU startup files Summary: The

[clang] [CLANG] bump NUM_PREDEF_TYPE_IDS (PR #113728)

2024-10-25 Thread Gang Chen via cfe-commits
cmc-rep wrote: Duplicate https://github.com/llvm/llvm-project/pull/113728 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] add IsLineVectorLayoutCompatible type trait (PR #113730)

2024-10-25 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 updated https://github.com/llvm/llvm-project/pull/113730 >From a31199224c19c1087b114de29d864125b720e6d8 Mon Sep 17 00:00:00 2001 From: Joshua Batista Date: Fri, 25 Oct 2024 12:33:05 -0700 Subject: [PATCH 1/3] add type trait --- .../clang/AST/CXXRecordDeclDefinition

[clang] [llvm] [AMDGPU] Add a type for the named barrier (PR #113614)

2024-10-25 Thread Gang Chen via cfe-commits
cmc-rep wrote: fix to the test no-external-type-id.cppm: https://github.com/llvm/llvm-project/pull/113738 https://github.com/llvm/llvm-project/pull/113614 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/l

[clang] [HLSL] add IsLineVectorLayoutCompatible type trait (PR #113730)

2024-10-25 Thread Finn Plummer via cfe-commits
https://github.com/inbelic approved this pull request. https://github.com/llvm/llvm-project/pull/113730 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Driver][SYCL] Add initial SYCL offload compilation support (PR #107493)

2024-10-25 Thread Alexey Bader via cfe-commits
https://github.com/bader approved this pull request. Thanks. No other comments from my side. https://github.com/llvm/llvm-project/pull/107493 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-co

[clang] [AMDGPU] Allow overload of __builtin_amdgcn_mov_dpp8 (PR #113610)

2024-10-25 Thread Stanislav Mekhanoshin via cfe-commits
https://github.com/rampitec updated https://github.com/llvm/llvm-project/pull/113610 >From edda0e600abeabff4d44e8b0b897104efacc8f98 Mon Sep 17 00:00:00 2001 From: Stanislav Mekhanoshin Date: Thu, 24 Oct 2024 11:31:52 -0700 Subject: [PATCH 1/2] [AMDGPU] Allow overload of __builtin_amdgcn_mov_dpp

[clang] Fix amdgpu-arch for dll name on Windows (PR #101350)

2024-10-25 Thread Matt Arsenault via cfe-commits
@@ -31,16 +44,118 @@ typedef hipError_t (*hipGetDeviceCount_t)(int *); typedef hipError_t (*hipDeviceGet_t)(int *, int); typedef hipError_t (*hipGetDeviceProperties_t)(hipDeviceProp_t *, int); -int printGPUsByHIP() { +extern cl::opt Verbose; + #ifdef _WIN32 - constexpr const

[clang] [llvm] [HLSL][SPIRV][DXIL] Implement `dot4add_i8packed` intrinsic (PR #113623)

2024-10-25 Thread Finn Plummer via cfe-commits
https://github.com/inbelic ready_for_review https://github.com/llvm/llvm-project/pull/113623 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] add IsLineVectorLayoutCompatible type trait (PR #113730)

2024-10-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-hlsl Author: Joshua Batista (bob80905) Changes This PR implements a new type trait as a builtin, `__builtin_hlsl_is_line_vector_layout_compatible` This type traits verifies that the given input type is suitable as a typed resource element type. It chec

[clang] Update std symbols mapping (PR #113612)

2024-10-25 Thread Vadim D. via cfe-commits
https://github.com/vvd170501 updated https://github.com/llvm/llvm-project/pull/113612 >From 96662cb7f681e7158c05a0190894de70eee03d67 Mon Sep 17 00:00:00 2001 From: Vadim Dudkin Date: Thu, 24 Oct 2024 23:18:52 +0300 Subject: [PATCH 1/6] Update std symbol mapping to v20230810; Move assertion to

[clang] [AMDGPU] Allow overload of __builtin_amdgcn_mov_dpp8 (PR #113610)

2024-10-25 Thread Stanislav Mekhanoshin via cfe-commits
@@ -152,6 +115,44 @@ bool SemaAMDGPU::CheckAMDGCNBuiltinFunctionCall(unsigned BuiltinID, return false; } +bool SemaAMDGPU::CheckMovDPPFunctionCall(CallExpr *TheCall, unsigned NumArgs, rampitec wrote: Done https://github.com/llvm/llvm-project/pull/113610 _

[clang] 242ccd2 - [clang] update the number in no-external-type-id.cppm (#113738)

2024-10-25 Thread via cfe-commits
Author: Gang Chen Date: 2024-10-25T15:52:31-07:00 New Revision: 242ccd2eb1069c817d44545010dfe185a4c3d0b1 URL: https://github.com/llvm/llvm-project/commit/242ccd2eb1069c817d44545010dfe185a4c3d0b1 DIFF: https://github.com/llvm/llvm-project/commit/242ccd2eb1069c817d44545010dfe185a4c3d0b1.diff LOG

[clang] Reland "[Utils] add update-verify-tests.py" (#108630)" (PR #108658)

2024-10-25 Thread Jon Roelofs via cfe-commits
jroelofs wrote: oh, right. nvm https://github.com/llvm/llvm-project/pull/108658 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lld] [llvm] [WebAssembly] Define a new "Trail1" CPU (PR #112035)

2024-10-25 Thread Dan Gohman via cfe-commits
https://github.com/sunfishcode updated https://github.com/llvm/llvm-project/pull/112035 >From 0c5970fd26c5d36a1eec986396d2a7192d5feb29 Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Fri, 11 Oct 2024 04:30:32 -0700 Subject: [PATCH 1/8] [WebAssembly] Define a new "Trail1" CPU First, define some

[clang] [Clang] Add a flag to include GPU startup files (PR #112025)

2024-10-25 Thread Matt Arsenault via cfe-commits
@@ -648,6 +648,17 @@ void amdgpu::Linker::ConstructJob(Compilation &C, const JobAction &JA, Args.MakeArgString("-plugin-opt=-mattr=" + llvm::join(Features, ","))); } + if (Args.hasArg(options::OPT_stdlib)) +CmdArgs.append({"-lc", "-lm"}); + if (Args.hasArg(opt

[clang] [clang][deps] Improve timing output (PR #113726)

2024-10-25 Thread Ben Langmuir via cfe-commits
@@ -34,6 +34,7 @@ def deprecated_driver_command : F<"deprecated-driver-command", "use a single dri defm resource_dir_recipe : Eq<"resource-dir-recipe", "How to produce missing '-resource-dir' argument">; def print_timing : F<"print-timing", "Print timing information">; +def

[clang] [Clang] Disable use of the counted_by attribute for whole struct pointers (PR #112636)

2024-10-25 Thread Bill Wendling via cfe-commits
bwendling wrote: I think the calculation in https://github.com/llvm/llvm-project/pull/112636#issuecomment-2436559387 is correct. It's probably worthwhile to perform some analysis to see if using that to calculate the new size results in allocation size changes in the kernel. If not, then perh

[clang] [clang] update the number in no-external-type-id.cppm (PR #113738)

2024-10-25 Thread Gang Chen via cfe-commits
https://github.com/cmc-rep closed https://github.com/llvm/llvm-project/pull/113738 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Driver][SYCL] Add initial SYCL offload compilation support (PR #107493)

2024-10-25 Thread Michael Toguchi via cfe-commits
mdtoguchi wrote: Thanks for the review @bader, I have made updates and hope to have addressed your concerns. https://github.com/llvm/llvm-project/pull/107493 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailma

[clang-tools-extra] [clangd] fix extract-to-function for overloaded operators (PR #81640)

2024-10-25 Thread via cfe-commits
BenBlumer wrote: @5chmidti I'm excited for this to be mainlined. Give me a thumbs up if you want me to fix the typo and rebase for you -- happy to do it this weekend. https://github.com/llvm/llvm-project/pull/81640 ___ cfe-commits mailing list cfe-co

[clang] [HLSL] add IsLineVectorLayoutCompatible type trait (PR #113730)

2024-10-25 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 updated https://github.com/llvm/llvm-project/pull/113730 >From a915def0c7cb69d8c910c697aa610fa37278d032 Mon Sep 17 00:00:00 2001 From: Joshua Batista Date: Fri, 25 Oct 2024 12:33:05 -0700 Subject: [PATCH 1/3] add type trait --- .../clang/AST/CXXRecordDeclDefinition

[clang] Reland "[Utils] add update-verify-tests.py" (#108630)" (PR #108658)

2024-10-25 Thread Henrik G. Olsson via cfe-commits
hnrklssn wrote: > > The ; did you mean to use BAR? version was accidentally emitted in some > > cases where it didn't make sense to do so, but the tests still passed > > because the diagnostic did contain cannot use FOO in context asdf. > > > > There's a `FileCheck` flag to enforce this: `-

[clang] [llvm] [Driver][SYCL] Add initial SYCL offload compilation support (PR #107493)

2024-10-25 Thread Michael Toguchi via cfe-commits
https://github.com/mdtoguchi updated https://github.com/llvm/llvm-project/pull/107493 >From 411203429a789330f044d6d7b2c0216cf21d816b Mon Sep 17 00:00:00 2001 From: Michael D Toguchi Date: Thu, 29 Aug 2024 16:39:42 -0700 Subject: [PATCH 1/7] [Driver][SYCL] Add initial SYCL offload compilation s

[clang] Reland "[Utils] add update-verify-tests.py" (#108630)" (PR #108658)

2024-10-25 Thread Jon Roelofs via cfe-commits
jroelofs wrote: > The ; did you mean to use BAR? version was accidentally emitted in some > cases where it didn't make sense to do so, but the tests still passed because > the diagnostic did contain cannot use FOO in context asdf. There's a `FileCheck` flag to enforce this: `--match-full-line

[clang] [llvm] [Driver][SYCL] Add initial SYCL offload compilation support (PR #107493)

2024-10-25 Thread Michael Toguchi via cfe-commits
https://github.com/mdtoguchi updated https://github.com/llvm/llvm-project/pull/107493 >From 411203429a789330f044d6d7b2c0216cf21d816b Mon Sep 17 00:00:00 2001 From: Michael D Toguchi Date: Thu, 29 Aug 2024 16:39:42 -0700 Subject: [PATCH 1/6] [Driver][SYCL] Add initial SYCL offload compilation s

[clang] [llvm] [clang-format] Add CI check confirming ClangFormatStyleOptions.rst is up-to-date. (PR #111513)

2024-10-25 Thread Aiden Grossman via cfe-commits
boomanaiden154 wrote: #113739 should fix this problem by just adding the options as part of the build and omitting them from the documentation source. https://github.com/llvm/llvm-project/pull/111513 ___ cfe-commits mailing list cfe-commits@lists.llvm

[clang] [llvm] [Driver][SYCL] Add initial SYCL offload compilation support (PR #107493)

2024-10-25 Thread Michael Toguchi via cfe-commits
@@ -767,6 +768,27 @@ Driver::OpenMPRuntimeKind Driver::getOpenMPRuntime(const ArgList &Args) const { return RT; } +static const char *getDefaultSYCLArch(Compilation &C) { + // If -fsycl is supplied we will assume SPIR-V + if (C.getDefaultToolChain().getTriple().getArch()

[clang] Respect the [[clang::unsafe_buffer_usage]] attribute for field and constructor initializers (PR #91991)

2024-10-25 Thread Ziqing Luo via cfe-commits
ziqingluo-90 wrote: Hi @danakj , we are really looking forward to this change! Will you finish it soon? Or I can pick it up and land it on behalf of you? https://github.com/llvm/llvm-project/pull/91991 ___ cfe-commits mailing list cfe-commits@list

[clang] [llvm] [Clang] Put offloading globals in the `.llvm.rodata.offloading` section (PR #111890)

2024-10-25 Thread Yaxun Liu via cfe-commits
https://github.com/yxsamliu approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/111890 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][modules] Only serialize info for locally-included headers (PR #113718)

2024-10-25 Thread Jan Svoboda via cfe-commits
https://github.com/jansvoboda11 closed https://github.com/llvm/llvm-project/pull/113718 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Update std symbols mapping (PR #113612)

2024-10-25 Thread Vadim D. via cfe-commits
https://github.com/vvd170501 updated https://github.com/llvm/llvm-project/pull/113612 >From 96662cb7f681e7158c05a0190894de70eee03d67 Mon Sep 17 00:00:00 2001 From: Vadim Dudkin Date: Thu, 24 Oct 2024 23:18:52 +0300 Subject: [PATCH 1/4] Update std symbol mapping to v20230810; Move assertion to

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

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

[clang] [clang][modules] Only serialize info for locally-included headers (PR #113718)

2024-10-25 Thread Ben Langmuir via cfe-commits
https://github.com/benlangmuir approved this pull request. https://github.com/llvm/llvm-project/pull/113718 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AMDGPU] Add a type for the named barrier (PR #113614)

2024-10-25 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: How did this get through pre-merge testing, I wonder. https://github.com/llvm/llvm-project/pull/113614 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 590b1e3 - [clang][modules] Only serialize info for locally-included headers (#113718)

2024-10-25 Thread via cfe-commits
Author: Jan Svoboda Date: 2024-10-25T15:00:07-07:00 New Revision: 590b1e31546572b62040066f90a35893a1b64f29 URL: https://github.com/llvm/llvm-project/commit/590b1e31546572b62040066f90a35893a1b64f29 DIFF: https://github.com/llvm/llvm-project/commit/590b1e31546572b62040066f90a35893a1b64f29.diff L

[clang-tools-extra] [clang-tidy] Fix crash in modernize-use-designated-initializers check (PR #113688)

2024-10-25 Thread Nicolas van Kempen via cfe-commits
nicovank wrote: I fixed a similar issue in 0aaac4fe194ae2249e1a01f9d6f5eac0d75c5bb2. There's an argument to be made whether this should be in the matchers (`isPOD`, `isAggregate` like here) versus an `hasDefinition` call in the parent before calling those matchers. I am slightly leaning toward

[clang] [llvm] [HLSL] Re-implement countbits with the correct return type (PR #113189)

2024-10-25 Thread Sarah Spall via cfe-commits
https://github.com/spall updated https://github.com/llvm/llvm-project/pull/113189 >From 12cac48dcc10ef9c5fccba2c22911f420298b98b Mon Sep 17 00:00:00 2001 From: Sarah Spall Date: Wed, 16 Oct 2024 19:00:08 + Subject: [PATCH 1/4] implement countbits correctly --- clang/lib/Headers/hlsl/hlsl_

[clang] Update std symbols mapping (PR #113612)

2024-10-25 Thread Vadim D. via cfe-commits
https://github.com/vvd170501 updated https://github.com/llvm/llvm-project/pull/113612 >From 96662cb7f681e7158c05a0190894de70eee03d67 Mon Sep 17 00:00:00 2001 From: Vadim Dudkin Date: Thu, 24 Oct 2024 23:18:52 +0300 Subject: [PATCH 1/5] Update std symbol mapping to v20230810; Move assertion to

[clang] Update std symbols mapping (PR #113612)

2024-10-25 Thread Vadim D. via cfe-commits
https://github.com/vvd170501 updated https://github.com/llvm/llvm-project/pull/113612 >From 96662cb7f681e7158c05a0190894de70eee03d67 Mon Sep 17 00:00:00 2001 From: Vadim Dudkin Date: Thu, 24 Oct 2024 23:18:52 +0300 Subject: [PATCH 1/7] Update std symbol mapping to v20230810; Move assertion to

[clang] [clang] update the number in no-external-type-id.cppm (PR #113738)

2024-10-25 Thread Gang Chen via cfe-commits
https://github.com/cmc-rep edited https://github.com/llvm/llvm-project/pull/113738 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format][CMake] Generate formatting options docs during build (PR #113739)

2024-10-25 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Aiden Grossman (boomanaiden154) Changes This patch changes up the CMake configuration so that ClangFormatStyleOptions.rst has the format style options section generated by the dump_format_style.py python script during the build rather tha

  1   2   3   4   5   6   >