[clang] [PowerPC] Fix incorrect store alignment for __builtin_vsx_build_pair() (PR #108606)

2024-09-17 Thread Lei Huang via cfe-commits
@@ -18197,7 +18197,7 @@ Value *CodeGenFunction::EmitPPCBuiltinExpr(unsigned BuiltinID, CallOps.push_back(Ops[i]); llvm::Function *F = CGM.getIntrinsic(ID); Value *Call = Builder.CreateCall(F, CallOps); -return Builder.CreateAlignedStore(Call, Ops[0], MaybeAli

[clang-tools-extra] [clang-tidy][readability-container-contains] Extend to any class with contains (PR #107521)

2024-09-17 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank updated https://github.com/llvm/llvm-project/pull/107521 >From 533f87937b9888ff0bd1761ecf43d5bb6bfe838d Mon Sep 17 00:00:00 2001 From: Nicolas van Kempen Date: Tue, 17 Sep 2024 16:54:19 -0400 Subject: [PATCH] [clang-tidy][readability-container-contains] Extend to any

[clang-tools-extra] [clang-tidy][readability-container-contains] Extend to any class with contains (PR #107521)

2024-09-17 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank updated https://github.com/llvm/llvm-project/pull/107521 >From 533f87937b9888ff0bd1761ecf43d5bb6bfe838d Mon Sep 17 00:00:00 2001 From: Nicolas van Kempen Date: Tue, 17 Sep 2024 16:54:19 -0400 Subject: [PATCH] [clang-tidy][readability-container-contains] Extend to any

[clang] [clang/AST] Make it possible to use SwiftAttr in type context (PR #108631)

2024-09-17 Thread Pavel Yaskevich via cfe-commits
@@ -5125,24 +5127,54 @@ QualType ASTContext::getUnresolvedUsingType( QualType ASTContext::getAttributedType(attr::Kind attrKind, QualType modifiedType, - QualType equivalentType) const { +

[clang] [PowerPC] Fix incorrect store alignment for __builtin_vsx_build_pair() (PR #108606)

2024-09-17 Thread Nikita Popov via cfe-commits
@@ -18197,7 +18197,7 @@ Value *CodeGenFunction::EmitPPCBuiltinExpr(unsigned BuiltinID, CallOps.push_back(Ops[i]); llvm::Function *F = CGM.getIntrinsic(ID); Value *Call = Builder.CreateCall(F, CallOps); -return Builder.CreateAlignedStore(Call, Ops[0], MaybeAli

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

2024-09-17 Thread Tom Honermann via cfe-commits
@@ -6553,6 +6634,20 @@ const ToolChain &Driver::getOffloadingDeviceToolChain( HostTC, Args); break; } +case Action::OFK_SYCL: + // TODO: Add additional Arch values for Ahead of Time support for SYCL.

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

2024-09-17 Thread Tom Honermann via cfe-commits
@@ -979,6 +1000,44 @@ void Driver::CreateOffloadingDeviceToolChains(Compilation &C, return; } + // + // SYCL + // + // We need to generate a SYCL toolchain if the user specified -fsycl. + // If -fsycl is supplied we will assume SPIR-V. tahonermann

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

2024-09-17 Thread Tom Honermann via cfe-commits
@@ -979,6 +1000,44 @@ void Driver::CreateOffloadingDeviceToolChains(Compilation &C, return; } + // + // SYCL + // + // We need to generate a SYCL toolchain if the user specified -fsycl. + // If -fsycl is supplied we will assume SPIR-V. + bool IsSYCL = + C.get

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

2024-09-17 Thread Tom Honermann via cfe-commits
https://github.com/tahonermann edited 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-commits

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

2024-09-17 Thread Tom Honermann via cfe-commits
@@ -767,6 +768,26 @@ Driver::OpenMPRuntimeKind Driver::getOpenMPRuntime(const ArgList &Args) const { return RT; } +static const char *getDefaultSYCLArch(Compilation &C) { + if (C.getDefaultToolChain().getTriple().getArch() == llvm::Triple::x86) +return "spir"; + retur

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

2024-09-17 Thread Tom Honermann via cfe-commits
@@ -5116,15 +5123,39 @@ void Clang::ConstructJob(Compilation &C, const JobAction &JA, if (const Arg *PF = Args.getLastArg(options::OPT_mprintf_kind_EQ)) PF->claim(); - if (Args.hasFlag(options::OPT_fsycl, options::OPT_fno_sycl, false)) { + Arg *SYCLStdArg = Args.getLa

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

2024-09-17 Thread Tom Honermann via cfe-commits
@@ -831,6 +831,13 @@ class Triple { getArch() == Triple::spirv; } + // Tests whether the target is SPIR-V or SPIR. Currently, we use spir-based + // target triples to represent JIT compilation targets for SYCL. We will + // transition to using spir-v based targ

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

2024-09-17 Thread Tom Honermann via cfe-commits
@@ -0,0 +1,77 @@ +/// +/// Perform several driver tests for SYCL offloading for JIT +/// + +/// Check the phases graph with -fsycl. Use of -fsycl enables offload +// RUN: %clang -ccc-print-phases --target=x86_64-unknown-linux-gnu \ +// RUN: -fsycl %s 2>&1 \ +// RUN: | FileCheck

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

2024-09-17 Thread Tom Honermann via cfe-commits
https://github.com/tahonermann commented: This looks good to me. I have some questions and pointed out some minor concerns. https://github.com/llvm/llvm-project/pull/107493 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org

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

2024-09-17 Thread Tom Honermann via cfe-commits
@@ -5116,15 +5123,39 @@ void Clang::ConstructJob(Compilation &C, const JobAction &JA, if (const Arg *PF = Args.getLastArg(options::OPT_mprintf_kind_EQ)) PF->claim(); - if (Args.hasFlag(options::OPT_fsycl, options::OPT_fno_sycl, false)) { + Arg *SYCLStdArg = Args.getLa

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

2024-09-17 Thread Tom Honermann via cfe-commits
@@ -0,0 +1,77 @@ +/// +/// Perform several driver tests for SYCL offloading for JIT +/// + +/// Check the phases graph with -fsycl. Use of -fsycl enables offload +// RUN: %clang -ccc-print-phases --target=x86_64-unknown-linux-gnu \ +// RUN: -fsycl %s 2>&1 \ +// RUN: | FileCheck

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

2024-09-17 Thread Tom Honermann via cfe-commits
@@ -0,0 +1,202 @@ +//===--- SYCL.cpp - SYCL Tool and ToolChain Implementations -*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

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

2024-09-17 Thread Tom Honermann via cfe-commits
@@ -0,0 +1,82 @@ +//===--- SYCL.h - SYCL ToolChain Implementations *- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apa

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

2024-09-17 Thread Tom Honermann via cfe-commits
@@ -0,0 +1,82 @@ +//===--- SYCL.h - SYCL ToolChain Implementations *- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apa

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

2024-09-17 Thread Tom Honermann via cfe-commits
@@ -0,0 +1,202 @@ +//===--- SYCL.cpp - SYCL Tool and ToolChain Implementations -*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang] [llvm] riscv: Support -mstack-protector-guard=tls (PR #108942)

2024-09-17 Thread Craig Topper via cfe-commits
topperc wrote: > offsetfor offset for https://github.com/llvm/llvm-project/pull/108942 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang/AST] Make it possible to use SwiftAttr in type context (PR #108631)

2024-09-17 Thread Pavel Yaskevich via cfe-commits
@@ -6037,13 +6038,24 @@ class AttributedType : public Type, public llvm::FoldingSetNode { private: friend class ASTContext; // ASTContext creates these + const Attr *Attribute; + QualType ModifiedType; QualType EquivalentType; AttributedType(QualType canon, attr

[clang] [clang/AST] Make it possible to use SwiftAttr in type context (PR #108631)

2024-09-17 Thread Pavel Yaskevich via cfe-commits
@@ -8732,6 +8786,11 @@ static void processTypeAttrs(TypeProcessingState &state, QualType &type, case ParsedAttr::AT_HLSLParamModifier: { HandleHLSLParamModifierAttr(state, type, attr, state.getSema()); attr.setUsedAsTypeAttr(); + break; +

[clang] [llvm] riscv: Support -mstack-protector-guard=tls (PR #108942)

2024-09-17 Thread Craig Topper via cfe-commits
@@ -3644,13 +3645,28 @@ static void RenderSSPOptions(const Driver &D, const ToolChain &TC, << A->getOption().getName() << Value << "sysreg global"; return; } +if (EffectiveTriple.isRISCV()) { + if (Value != "tls" && Value != "global") { +D.

[clang] [llvm] riscv: Support -mstack-protector-guard=tls (PR #108942)

2024-09-17 Thread Craig Topper via cfe-commits
@@ -3664,12 +3680,18 @@ static void RenderSSPOptions(const Driver &D, const ToolChain &TC, << A->getOption().getName() << Value; return; } +if (EffectiveTriple.isRISCV() && (Offset <= -2048 || Offset >= 2048)) { topperc wrote: I don't

[clang] [llvm] riscv: Support -mstack-protector-guard=tls (PR #108942)

2024-09-17 Thread Craig Topper via cfe-commits
@@ -3644,13 +3645,28 @@ static void RenderSSPOptions(const Driver &D, const ToolChain &TC, << A->getOption().getName() << Value << "sysreg global"; return; } +if (EffectiveTriple.isRISCV()) { + if (Value != "tls" && Value != "global") { ---

[clang] [webkit.RefCntblBaseVirtualDtor] ThreadSafeRefCounted still generates warnings (PR #108656)

2024-09-17 Thread Artem Dergachev via cfe-commits
https://github.com/haoNoQ approved this pull request. LGTM! https://github.com/llvm/llvm-project/pull/108656 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [webkit.RefCntblBaseVirtualDtor] ThreadSafeRefCounted still generates warnings (PR #108656)

2024-09-17 Thread Artem Dergachev via cfe-commits
@@ -84,13 +84,22 @@ class DerefFuncDeleteExprVisitor E = E->IgnoreParenCasts(); if (auto *TempE = dyn_cast(E)) E = TempE->getSubExpr(); +E = E->IgnoreParenCasts(); +if (auto *Ref = dyn_cast(E)) { + if (auto *Decl = Ref->getDecl()) { +if (auto

[clang] [webkit.RefCntblBaseVirtualDtor] ThreadSafeRefCounted still generates warnings (PR #108656)

2024-09-17 Thread Artem Dergachev via cfe-commits
@@ -119,6 +119,11 @@ template ensureOnMainThread([this] { delete static_cast(this); }); +} else if constexpr (destructionThread == DestructionThread::MainRunLoop) { +auto deleteThis = [this] { haoNoQ

[clang] [webkit.RefCntblBaseVirtualDtor] ThreadSafeRefCounted still generates warnings (PR #108656)

2024-09-17 Thread Artem Dergachev via cfe-commits
https://github.com/haoNoQ edited https://github.com/llvm/llvm-project/pull/108656 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [webkit.RefCntblBaseVirtualDtor] ThreadSafeRefCounted still generates warnings (PR #108656)

2024-09-17 Thread Artem Dergachev via cfe-commits
@@ -84,13 +84,22 @@ class DerefFuncDeleteExprVisitor E = E->IgnoreParenCasts(); if (auto *TempE = dyn_cast(E)) E = TempE->getSubExpr(); +E = E->IgnoreParenCasts(); +if (auto *Ref = dyn_cast(E)) { + if (auto *Decl = Ref->getDecl()) { +if (auto

[clang] [Clang][Sema] Use the correct lookup context when building overloaded 'operator->' in the current instantiation (PR #104458)

2024-09-17 Thread Krystian Stasiowski via cfe-commits
sdkrystian wrote: @porglezomp Sorry, I'm currently at cppcon but I'll try reland it when I have a moment. https://github.com/llvm/llvm-project/pull/104458 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/l

[clang] [Clang][Sema] Refactor collection of multi-level template argument lists (PR #106585)

2024-09-17 Thread Krystian Stasiowski via cfe-commits
@@ -585,8 +585,8 @@ static bool CheckConstraintSatisfaction( ArrayRef TemplateArgs = TemplateArgsLists.getNumSubstitutedLevels() > 0 - ? TemplateArgsLists.getOutermost() - : ArrayRef {}; + ? TemplateArgsLists.getInnermost() s

[clang] 4a63f4d - Revert "[HLSL] set alwaysinline on HLSL functions (#106588)"

2024-09-17 Thread Thurston Dang via cfe-commits
Author: Thurston Dang Date: 2024-09-17T21:06:36Z New Revision: 4a63f4d301c0e044073e1b1f8f110015ec1778a1 URL: https://github.com/llvm/llvm-project/commit/4a63f4d301c0e044073e1b1f8f110015ec1778a1 DIFF: https://github.com/llvm/llvm-project/commit/4a63f4d301c0e044073e1b1f8f110015ec1778a1.diff LOG:

[clang] [clang-scan-deps] Don't inspect Args[0] as an option (PR #109050)

2024-09-17 Thread Martin Storsjö via cfe-commits
https://github.com/mstorsjo created https://github.com/llvm/llvm-project/pull/109050 Since a26ec542371652e1d774696e90016fd5b0b1c191, we expand the executable name to an absolute path, if it isn't already one, if found in path. This broke a couple tests in some environments; when the clang work

[clang] [clang-scan-deps] Don't inspect Args[0] as an option (PR #109050)

2024-09-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Martin Storsjö (mstorsjo) Changes Since a26ec542371652e1d774696e90016fd5b0b1c191, we expand the executable name to an absolute path, if it isn't already one, if found in path. This broke a couple tests in some environments; when the clang

[clang] [PowerPC] Fix incorrect store alignment for __builtin_vsx_build_pair() (PR #108606)

2024-09-17 Thread Lei Huang via cfe-commits
@@ -18197,7 +18197,7 @@ Value *CodeGenFunction::EmitPPCBuiltinExpr(unsigned BuiltinID, CallOps.push_back(Ops[i]); llvm::Function *F = CGM.getIntrinsic(ID); Value *Call = Builder.CreateCall(F, CallOps); -return Builder.CreateAlignedStore(Call, Ops[0], MaybeAli

[clang] [Clang][Sema] Refactor collection of multi-level template argument lists (PR #106585)

2024-09-17 Thread Erich Keane via cfe-commits
@@ -585,8 +585,8 @@ static bool CheckConstraintSatisfaction( ArrayRef TemplateArgs = TemplateArgsLists.getNumSubstitutedLevels() > 0 - ? TemplateArgsLists.getOutermost() - : ArrayRef {}; + ? TemplateArgsLists.getInnermost() e

[clang] [libc] [libcxx] [Clang] Do not implicitly link C libraries for the GPU targets (PR #109052)

2024-09-17 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 created https://github.com/llvm/llvm-project/pull/109052 Summary: I initially thought that it would be convenient to automatically link these libraries like they are for standard C/C++ targets. However, this created issues when trying to use C++ as a GPU target. This p

[clang] [libc] [libcxx] [Clang] Do not implicitly link C libraries for the GPU targets (PR #109052)

2024-09-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-driver Author: Joseph Huber (jhuber6) Changes Summary: I initially thought that it would be convenient to automatically link these libraries like they are for standard C/C++ targets. However, this created issues when trying to use C++ as a GPU targ

[clang] [libc] [libcxx] [Clang] Do not implicitly link C libraries for the GPU targets (PR #109052)

2024-09-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Joseph Huber (jhuber6) Changes Summary: I initially thought that it would be convenient to automatically link these libraries like they are for standard C/C++ targets. However, this created issues when trying to use C++ as a GPU target. Thi

[clang] [libc] [libcxx] [Clang] Do not implicitly link C libraries for the GPU targets (PR #109052)

2024-09-17 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay approved this pull request. https://github.com/llvm/llvm-project/pull/109052 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [libc] [libcxx] [Clang] Do not implicitly link C libraries for the GPU targets (PR #109052)

2024-09-17 Thread Schrodinger ZHU Yifan via cfe-commits
https://github.com/SchrodingerZhu approved this pull request. https://github.com/llvm/llvm-project/pull/109052 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [AMDGPU] Infer amdgpu-no-flat-scratch-init attribute in AMDGPUAttributor (PR #94647)

2024-09-17 Thread Jun Wang via cfe-commits
@@ -434,6 +434,15 @@ struct AAAMDAttributesFunction : public AAAMDAttributes { indicatePessimisticFixpoint(); return; } + +for (Instruction &I : instructions(F)) { + if (isa(I) && jwanggit86 wrote: @arsenm Could you please give me an e

[clang] [PAC] Re-sign a pointer to a noexcept member function when it is converted to a pointer to a member function without noexcept (PR #109056)

2024-09-17 Thread Akira Hatanaka via cfe-commits
https://github.com/ahatanak created https://github.com/llvm/llvm-project/pull/109056 Fixes https://github.com/llvm/llvm-project/issues/106487. >From eede4b2c2916a3016643fb56f87f7601dfaff69b Mon Sep 17 00:00:00 2001 From: Akira Hatanaka Date: Mon, 16 Sep 2024 17:12:13 -0700 Subject: [PATCH] [PA

[clang] [PAC] Re-sign a pointer to a noexcept member function when it is converted to a pointer to a member function without noexcept (PR #109056)

2024-09-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Akira Hatanaka (ahatanak) Changes Fixes https://github.com/llvm/llvm-project/issues/106487. --- Full diff: https://github.com/llvm/llvm-project/pull/109056.diff 3 Files Affected: - (modified) clang/lib/CodeGen/CGExprScalar.cpp (+7-2) -

[clang] [webkit.RefCntblBaseVirtualDtor] ThreadSafeRefCounted still generates warnings (PR #108656)

2024-09-17 Thread Artem Dergachev via cfe-commits
@@ -119,6 +119,11 @@ template ensureOnMainThread([this] { delete static_cast(this); }); +} else if constexpr (destructionThread == DestructionThread::MainRunLoop) { +auto deleteThis = [this] { haoNoQ

[clang] [PowerPC] Fix incorrect store alignment for __builtin_vsx_build_pair() (PR #108606)

2024-09-17 Thread Eli Friedman via cfe-commits
@@ -18197,7 +18197,7 @@ Value *CodeGenFunction::EmitPPCBuiltinExpr(unsigned BuiltinID, CallOps.push_back(Ops[i]); llvm::Function *F = CGM.getIntrinsic(ID); Value *Call = Builder.CreateCall(F, CallOps); -return Builder.CreateAlignedStore(Call, Ops[0], MaybeAli

[clang] [Parser][BoundsSafety] Print attribute as macro if it's system defined (PR #107619)

2024-09-17 Thread Yeoul Na via cfe-commits
https://github.com/rapidsna updated https://github.com/llvm/llvm-project/pull/107619 >From 1d00f0fca700c058320a39cd3f40cdd58c37cf8f Mon Sep 17 00:00:00 2001 From: Yeoul Na Date: Thu, 5 Sep 2024 09:52:41 -0700 Subject: [PATCH 1/3] [Parser][BoundsSafety] Print attribute as macro if it's system d

[clang] [HLSL] generate hlsl.wavesize attribute (PR #107176)

2024-09-17 Thread Damyan Pepper via cfe-commits
https://github.com/damyanp approved this pull request. https://github.com/llvm/llvm-project/pull/107176 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Parser][BoundsSafety] Print attribute as macro if it's system defined (PR #107619)

2024-09-17 Thread Yeoul Na via cfe-commits
@@ -1105,16 +1120,16 @@ enum AttributeDeclKind { inline const StreamingDiagnostic &operator<<(const StreamingDiagnostic &DB, const ParsedAttr &At) { - DB.AddTaggedVal(reinterpret_cast(At.getAttrName()), + const IdentifierInfo *Att

[clang] [flang] [llvm] [mlir] Make MMIWP not have ownership over MMI + Make MMI Only Use an External MCContext (PR #105541)

2024-09-17 Thread Arthur Eubanks via cfe-commits
aeubanks wrote: sorry for the delay after looking at MMI/MCContext, I agree that MMI shouldn't own MCContext, but do we even need a reference from MMI to MCContext? they are different layers of codegen IIUC. if it's possible to completely separate them we should do that (please correct me if

[clang] [UEFI] X86_64 UEFI Clang Driver (PR #76838)

2024-09-17 Thread Fangrui Song via cfe-commits
@@ -0,0 +1,4 @@ +// RUN: %clang -target x86_64-unknown-uefi -S -emit-llvm -o - %s | \ MaskRay wrote: test/Driver tests should generally only test `-###`, not `-emit-llvm -S` (codegen). Place such codegen tests to test/CodeGen https://github.com/llvm/llvm-projec

[clang] [UEFI] X86_64 UEFI Clang Driver (PR #76838)

2024-09-17 Thread Fangrui Song via cfe-commits
@@ -0,0 +1,61 @@ +//===--- UEFI.h - UEFI ToolChain Implementations --*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apache-2.0

[clang] [UEFI] X86_64 UEFI Clang Driver (PR #76838)

2024-09-17 Thread Fangrui Song via cfe-commits
@@ -0,0 +1,88 @@ +//===--- UEFI.h - UEFI ToolChain Implementations --*- C++ -*-===// MaskRay wrote: first line is incorrect. ensure 80-char wide and omit `C++` for `.cpp` files. https://github.com/llvm/llvm-project/pull/76838

[clang] [UEFI] X86_64 UEFI Clang Driver (PR #76838)

2024-09-17 Thread Fangrui Song via cfe-commits
@@ -0,0 +1,4 @@ +// RUN: %clang -target x86_64-unknown-uefi -S -emit-llvm -o - %s | \ +// RUN: FileCheck --check-prefix=X86_64_UEFI %s +// X86_64_UEFI: target datalayout = "e-m:w-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128" + Mas

[clang] 905de9b - [HLSL] Add testing for space parameter on global constants (#106782)

2024-09-17 Thread via cfe-commits
Author: Joshua Batista Date: 2024-09-17T14:57:41-07:00 New Revision: 905de9b0fe06d960e7f60175e6c96b955f334a66 URL: https://github.com/llvm/llvm-project/commit/905de9b0fe06d960e7f60175e6c96b955f334a66 DIFF: https://github.com/llvm/llvm-project/commit/905de9b0fe06d960e7f60175e6c96b955f334a66.diff

[clang] [HLSL] Add testing for space parameter on global constants (PR #106782)

2024-09-17 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 closed https://github.com/llvm/llvm-project/pull/106782 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [UEFI] X86_64 UEFI Clang Driver (PR #76838)

2024-09-17 Thread Fangrui Song via cfe-commits
MaskRay wrote: `[Driver] Add toolchain for ...' might be a more conventional patch subject. https://github.com/llvm/llvm-project/pull/76838 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-comm

[clang] [Parser][BoundsSafety] Print attribute as macro if it's system defined (PR #107619)

2024-09-17 Thread Yeoul Na via cfe-commits
https://github.com/rapidsna edited https://github.com/llvm/llvm-project/pull/107619 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [flang] Fix OOM in FormatDiagnostic (2nd attempt) (PR #108866)

2024-09-17 Thread Vakhurin Sergei via cfe-commits
https://github.com/igelbox edited https://github.com/llvm/llvm-project/pull/108866 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-17 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 edited https://github.com/llvm/llvm-project/pull/108005 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-17 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 requested changes to this pull request. Thanks! Generally looks pretty good, a few minor comments / cleanups and this should be good to go. https://github.com/llvm/llvm-project/pull/108005 ___ cfe-commits mailing list

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-17 Thread Nathan Ridge via cfe-commits
@@ -126,11 +126,29 @@ struct Config { std::vector FullyQualifiedNamespaces; } Style; + /// controls the completion options for argument lists. + enum class ArgumentListsOption { HighCommander4 wrote: naming suggestion: `ArgumentListsPolicy`, for consi

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-17 Thread Nathan Ridge via cfe-commits
@@ -242,13 +242,16 @@ opt FallbackStyle{ init(clang::format::DefaultFallbackStyle), }; -opt EnableFunctionArgSnippets{ -"function-arg-placeholders", -cat(Features), -desc("When disabled, completions contain only parentheses for " - "function calls. When

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-17 Thread Nathan Ridge via cfe-commits
@@ -561,14 +561,32 @@ struct CodeCompletionBuilder { } std::string summarizeSnippet() const { + +/// localize a ArgList depending on the config. If the config is unset we +/// will use our local (this) version, else use the one of the config +const Config::Argu

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-17 Thread Nathan Ridge via cfe-commits
@@ -504,10 +504,10 @@ struct FragmentCompiler { auto Fast = isFastTidyCheck(Str); if (!Fast.has_value()) { diag(Warning, - llvm::formatv( - "Latency of clang-tidy check '{0}' is not known. " - "It will only run if

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-17 Thread Nathan Ridge via cfe-commits
@@ -2595,10 +2596,10 @@ TEST(SignatureHelpTest, DynamicIndexDocumentation) { ElementsAre(AllOf(sig("foo() -> int"), sigDoc("Member doc"; } -TEST(CompletionTest, CompletionFunctionArgsDisabled) { +TEST(CompletionTest, ArgumentListsNotFullPlaceholders) { --

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-17 Thread Nathan Ridge via cfe-commits
@@ -622,6 +622,31 @@ struct FragmentCompiler { C.Completion.AllScopes = AllScopes; }); } +if (F.ArgumentLists) { HighCommander4 wrote: We have a `compileEnum` helper to do this more easily, see [the handling of `BackgroundPolicy`

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-17 Thread Nathan Ridge via cfe-commits
@@ -694,13 +698,20 @@ class FlagsConfigProvider : public config::Provider { BGPolicy = Config::BackgroundPolicy::Skip; } +if (PlaceholderOption == Config::ArgumentListsOption::Delimiters) { + ArgumentLists = PlaceholderOption; +} + Frag = [=](const

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-17 Thread Nathan Ridge via cfe-commits
@@ -230,6 +230,10 @@ class Parser { if (auto AllScopes = boolValue(N, "AllScopes")) F.AllScopes = *AllScopes; }); +Dict.handle("ArgumentLists", [&](Node &N) { + if (auto ArgumentLists = scalarValue(N, "ArgumentLists")) HighCommander4

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-17 Thread Nathan Ridge via cfe-commits
@@ -6,6 +6,7 @@ // //===--===// +#include "../Config.h" HighCommander4 wrote: This can be included without the `../`. (Please alphabetize it among the existing includes.) https://github.co

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-17 Thread Nathan Ridge via cfe-commits
@@ -308,6 +309,13 @@ struct Fragment { /// Whether code completion should include suggestions from scopes that are /// not visible. The required scope prefix will be inserted. std::optional> AllScopes; +/// How to present the argument list between '()' and '<>':

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-17 Thread Nathan Ridge via cfe-commits
@@ -126,11 +126,29 @@ struct Config { std::vector FullyQualifiedNamespaces; } Style; + /// controls the completion options for argument lists. + enum class ArgumentListsOption { +/// the default value. This will imply FullPlaceholders unless overridden by +///

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-17 Thread Nathan Ridge via cfe-commits
@@ -126,11 +126,29 @@ struct Config { std::vector FullyQualifiedNamespaces; } Style; + /// controls the completion options for argument lists. + enum class ArgumentListsOption { +/// the default value. This will imply FullPlaceholders unless overridden by +///

[clang-tools-extra] issue-63565: community requested small QoL fix for more configurabili… (PR #108005)

2024-09-17 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: > As mentions in [this > post](https://github.com/llvm/llvm-project/issues/63565#issuecomment-2337396222): > these to issues remain within vsocde/vscode-clangd: > >* None: after completion an error squiggly line will occur on the > identifier. Would be slightly nicer

[clang] [HLSL] set alwaysinline on HLSL functions (PR #106588)

2024-09-17 Thread Nico Weber via cfe-commits
nico wrote: Looks like the _revert_ broke check-clang: http://45.33.8.238/linux/148045/step_6.txt Please take a look, and uh, mark that test as UNSUPPORTED if it takes a while to fix, I suppose. https://github.com/llvm/llvm-project/pull/106588 ___ c

[clang] [HLSL] set alwaysinline on HLSL functions (PR #106588)

2024-09-17 Thread Nico Weber via cfe-commits
nico wrote: @thurstond ^ https://github.com/llvm/llvm-project/pull/106588 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] set alwaysinline on HLSL functions (PR #106588)

2024-09-17 Thread Thurston Dang via cfe-commits
thurstond wrote: @nico Sorry, my bad. I didn't notice the test was also updated as a companion to this change (https://github.com/llvm/llvm-project/pull/109023). I'll revert the test as well. https://github.com/llvm/llvm-project/pull/106588 ___ cfe-c

[clang] da03d17 - Revert "[HLSL] update StructuredBuffer subscript test for alwaysinline (#109023)"

2024-09-17 Thread Thurston Dang via cfe-commits
Author: Thurston Dang Date: 2024-09-17T22:49:59Z New Revision: da03d17698f205fe8ebc54c32994c8ce2c51a81e URL: https://github.com/llvm/llvm-project/commit/da03d17698f205fe8ebc54c32994c8ce2c51a81e DIFF: https://github.com/llvm/llvm-project/commit/da03d17698f205fe8ebc54c32994c8ce2c51a81e.diff LOG:

[clang] [libc] [libcxx] [Clang] Do not implicitly link C libraries for the GPU targets (PR #109052)

2024-09-17 Thread Michael Jones via cfe-commits
https://github.com/michaelrj-google approved this pull request. https://github.com/llvm/llvm-project/pull/109052 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] set alwaysinline on HLSL functions (PR #106588)

2024-09-17 Thread Thurston Dang via cfe-commits
thurstond wrote: Oh, actually, I just realized the test update was the fix-forward. So the correct fix would be to reland both the change and the test update. Sorry! https://github.com/llvm/llvm-project/pull/106588 ___ cfe-commits mailing list cfe-com

[clang] 4a0bf83 - Reapply "[HLSL] update StructuredBuffer subscript test for alwaysinline (#109023)"

2024-09-17 Thread Thurston Dang via cfe-commits
Author: Thurston Dang Date: 2024-09-17T22:54:04Z New Revision: 4a0bf8377e1038d6cf9454c7c6740bd759729938 URL: https://github.com/llvm/llvm-project/commit/4a0bf8377e1038d6cf9454c7c6740bd759729938 DIFF: https://github.com/llvm/llvm-project/commit/4a0bf8377e1038d6cf9454c7c6740bd759729938.diff LOG:

[clang] b89bb77 - Reapply "[HLSL] set alwaysinline on HLSL functions (#106588)"

2024-09-17 Thread Thurston Dang via cfe-commits
Author: Thurston Dang Date: 2024-09-17T22:54:52Z New Revision: b89bb7775d155fc787ab3170f3fa38449069ecb3 URL: https://github.com/llvm/llvm-project/commit/b89bb7775d155fc787ab3170f3fa38449069ecb3 DIFF: https://github.com/llvm/llvm-project/commit/b89bb7775d155fc787ab3170f3fa38449069ecb3.diff LOG:

[clang] [HLSL] set alwaysinline on HLSL functions (PR #106588)

2024-09-17 Thread Thurston Dang via cfe-commits
thurstond wrote: I've reverted both of my reverts https://github.com/llvm/llvm-project/pull/106588 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] set alwaysinline on HLSL functions (PR #106588)

2024-09-17 Thread Greg Roth via cfe-commits
pow2clk wrote: Sorry I didn't mention here that the fix was in. It looks like everything is clean now? https://github.com/llvm/llvm-project/pull/106588 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/lis

[clang] [llvm] riscv: Support -mstack-protector-guard=tls (PR #108942)

2024-09-17 Thread Alexander Richardson via cfe-commits
@@ -3644,13 +3645,28 @@ static void RenderSSPOptions(const Driver &D, const ToolChain &TC, << A->getOption().getName() << Value << "sysreg global"; return; } +if (EffectiveTriple.isRISCV()) { + if (Value != "tls" && Value != "global") { ---

[clang] [AST] Iterate redecls starting from the canonical one in getRawCommentsForAnyRedecl() (PR #108475)

2024-09-17 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: @zyn0217 I've debugged the `DefineInlineTest.AddInline` failure with your new suggested change, it concerns the following scenario: header.h ```c++ template void foo(); template <> void foo(); ``` source.cpp: ```c++ #include "header.h" template <> void foo() {} ``` It s

[clang] [llvm] riscv: Support -mstack-protector-guard=tls (PR #108942)

2024-09-17 Thread Alexander Richardson via cfe-commits
@@ -3664,12 +3680,18 @@ static void RenderSSPOptions(const Driver &D, const ToolChain &TC, << A->getOption().getName() << Value; return; } +if (EffectiveTriple.isRISCV() && (Offset <= -2048 || Offset >= 2048)) { arichardson wrote: Shou

[clang] [HLSL] set alwaysinline on HLSL functions (PR #106588)

2024-09-17 Thread Thurston Dang via cfe-commits
thurstond wrote: > Sorry I didn't mention here that the fix was in. It looks like everything is > clean now? Yes, both your changes are back in and I anticipate the buildbots will be green again. Sorry for the noise! https://github.com/llvm/llvm-project/pull/106588 ___

[clang] [HLSL] generate hlsl.wavesize attribute (PR #107176)

2024-09-17 Thread Xiang Li via cfe-commits
https://github.com/python3kgae updated https://github.com/llvm/llvm-project/pull/107176 >From 6de0eb900e845e6ac7918433c597bf3665b93741 Mon Sep 17 00:00:00 2001 From: Xiang Li Date: Tue, 3 Sep 2024 22:56:21 -0400 Subject: [PATCH 1/2] [HLSL] generate hlsl.wavesize attribute Generate function att

[clang] [HLSL] set alwaysinline on HLSL functions (PR #106588)

2024-09-17 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `clang-x86_64-debian-fast` running on `gribozavr4` while building `clang` at step 6 "test-build-unified-tree-check-all". Full details are available at: https://lab.llvm.org/buildbot/#/builders/56/builds/7605 Here is the rele

[clang] [HLSL] set alwaysinline on HLSL functions (PR #106588)

2024-09-17 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `llvm-x86_64-debian-dylib` running on `gribozavr4` while building `clang` at step 6 "test-build-unified-tree-check-clang". Full details are available at: https://lab.llvm.org/buildbot/#/builders/60/builds/7827 Here is the re

[clang] [llvm] [HLSL] Implement elementwise popcount (PR #108121)

2024-09-17 Thread Sarah Spall via cfe-commits
https://github.com/spall updated https://github.com/llvm/llvm-project/pull/108121 >From ebb4078d485559f70d79d3b10dc9f4ce401a3261 Mon Sep 17 00:00:00 2001 From: Sarah Spall Date: Fri, 6 Sep 2024 21:03:05 + Subject: [PATCH 1/3] implement elementwise popcount to implement countbits --- clang

[clang] [clang] Use canonical type for substitution which might be incomplete (PR #109065)

2024-09-17 Thread Matheus Izvekov via cfe-commits
https://github.com/mizvekov created https://github.com/llvm/llvm-project/pull/109065 When checking deduction consistency, a substitution can be incomplete such that only sugar parts refer to non-deduced template parameters. This would not otherwise lead to an inconsistent deduction, so this pa

[clang] [clang] Use canonical type for substitution which might be incomplete (PR #109065)

2024-09-17 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Matheus Izvekov (mizvekov) Changes When checking deduction consistency, a substitution can be incomplete such that only sugar parts refer to non-deduced template parameters. This would not otherwise lead to an inconsistent deduction, so t

[clang] [clang] check deduction consistency when partial ordering function templates (PR #100692)

2024-09-17 Thread Matheus Izvekov via cfe-commits
mizvekov wrote: @alexfh https://github.com/llvm/llvm-project/pull/109065 Fixes test case 1. https://github.com/llvm/llvm-project/pull/100692 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-com

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

2024-09-17 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: > That was always true, in the sense that there's nothing preventing the author > from doing the exact same thing: looking at the output from the clang -verify > failure and adding/removing expected diagnostics until it matches. In fact, > even without this script that is the mo

[clang-tools-extra] 785624b - [clang-tidy]suggest use `std::span` as replacement of c array in C++20 for modernize-avoid-c-arrays (#108555)

2024-09-17 Thread via cfe-commits
Author: Congcong Cai Date: 2024-09-18T08:03:06+08:00 New Revision: 785624b28237bb75d4fa3b8e4219a5448b90eaac URL: https://github.com/llvm/llvm-project/commit/785624b28237bb75d4fa3b8e4219a5448b90eaac DIFF: https://github.com/llvm/llvm-project/commit/785624b28237bb75d4fa3b8e4219a5448b90eaac.diff

[clang-tools-extra] [clang-tidy]suggest use `std::span` as replacement of c array in C++20 for modernize-avoid-c-arrays (PR #108555)

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

<    1   2   3   4   5   >