[clang] [Clang][Sema] Fix exception specification comparison for functions with different template depths (PR #111561)

2024-10-08 Thread Krystian Stasiowski via cfe-commits
https://github.com/sdkrystian created https://github.com/llvm/llvm-project/pull/111561 Currently, we do not account for differences in template depth when comparing exception specifications for equivalence. This results in explicit specializations of member function templates specialized for a

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

2024-10-08 Thread Matheus Izvekov via cfe-commits
mizvekov wrote: Yeah, I think its only user was reverted a while ago, but should be merged back eventually. https://github.com/llvm/llvm-project/pull/73 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman

[clang] [clang] Add test for CWG110 "Can template functions and classes be declared in the same scope?" (PR #111446)

2024-10-08 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll edited https://github.com/llvm/llvm-project/pull/111446 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] assume_aligned incorrectly diagnoses a dependent return type (PR #111573)

2024-10-08 Thread Erich Keane via cfe-commits
@@ -1216,6 +1216,8 @@ static void handlePreferredName(Sema &S, Decl *D, const ParsedAttr &AL) { } bool Sema::isValidPointerAttrType(QualType T, bool RefOkay) { + if (T->isDependentType()) erichkeane wrote: Probably valuable to audit the other uses of this f

[clang] [clang] Add test for CWG110 "Can template functions and classes be declared in the same scope?" (PR #111446)

2024-10-08 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll edited https://github.com/llvm/llvm-project/pull/111446 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Add test for CWG110 "Can template functions and classes be declared in the same scope?" (PR #111446)

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

[clang] eaea5f6 - [clang] Add test for CWG110 "Can template functions and classes be declared in the same scope?" (#111446)

2024-10-08 Thread via cfe-commits
Author: Vlad Serebrennikov Date: 2024-10-08T22:41:33+04:00 New Revision: eaea5f6f952b6059cebfe87ea9800a3a6516f9ed URL: https://github.com/llvm/llvm-project/commit/eaea5f6f952b6059cebfe87ea9800a3a6516f9ed DIFF: https://github.com/llvm/llvm-project/commit/eaea5f6f952b6059cebfe87ea9800a3a6516f9ed.

[clang] [HLSL] Make HLSLAttributedResourceType canonical and add code paths to convert HLSL types to DirectX target types (PR #110327)

2024-10-08 Thread Chris B via cfe-commits
https://github.com/llvm-beanz edited https://github.com/llvm/llvm-project/pull/110327 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Make HLSLAttributedResourceType canonical and add code paths to convert HLSL types to DirectX target types (PR #110327)

2024-10-08 Thread Chris B via cfe-commits
@@ -32,6 +32,7 @@ #include "llvm/ADT/SmallVector.h" #include "llvm/ADT/StringExtras.h" #include "llvm/Support/CRC.h" +#include "llvm/Support/DXILABI.h" llvm-beanz wrote: Do we need this include? https://github.com/llvm/llvm-project/pull/110327 ___

[clang-tools-extra] [clang-tidy][performance-move-const-arg] Fix crash when argument type has no definition (PR #111472)

2024-10-08 Thread Julian Schmidt via cfe-commits
https://github.com/5chmidti approved this pull request. Please add a release note, otherwise LGTM https://github.com/llvm/llvm-project/pull/111472 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/c

[clang] [llvm] [HLSL] Implement `WaveReadLaneAt` intrinsic (PR #111010)

2024-10-08 Thread Finn Plummer via cfe-commits
@@ -428,6 +431,7 @@ bool SPIRVInstructionSelector::spvSelect(Register ResVReg, case TargetOpcode::G_INTRINSIC: case TargetOpcode::G_INTRINSIC_W_SIDE_EFFECTS: + case TargetOpcode::G_INTRINSIC_CONVERGENT: inbelic wrote: Afaict, not within this section of t

[clang] Support BasedOnStyle referencing an arbitrary file (PR #110634)

2024-10-08 Thread Ryan Saunders via cfe-commits
https://github.com/jediry updated https://github.com/llvm/llvm-project/pull/110634 >From 82160d1e6de3f197c847bf8ed21ea1fc314b3cf4 Mon Sep 17 00:00:00 2001 From: Ryan Saunders Date: Tue, 1 Oct 2024 00:03:50 -0700 Subject: [PATCH 1/2] Support BasedOnStyle: file:blah.clang-format --- clang/inclu

[clang] [llvm] [clang][llvm][SPIR-V] Explicitly encode native integer widths for SPIR-V (PR #110695)

2024-10-08 Thread Vyacheslav Levytskyy via cfe-commits
@@ -1,12 +1,14 @@ ; This test aims to check ability to support "Arithmetic with Overflow" intrinsics ; in the special case when those intrinsics are being generated by the CodeGenPrepare; -; pass during translations with optimization (note -O3 in llc arguments). +; pass during

[clang] [llvm] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds (PR #90933)

2024-10-08 Thread Kyungwoo Lee via cfe-commits
https://github.com/kyulee-com updated https://github.com/llvm/llvm-project/pull/90933 >From 411fc459e58a65d9599c917f220ba68bb799baac Mon Sep 17 00:00:00 2001 From: Kyungwoo Lee Date: Fri, 13 Sep 2024 08:51:00 -0700 Subject: [PATCH 1/4] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds

[clang] Support BasedOnStyle referencing an arbitrary file (PR #110634)

2024-10-08 Thread Ryan Saunders via cfe-commits
https://github.com/jediry updated https://github.com/llvm/llvm-project/pull/110634 >From 82160d1e6de3f197c847bf8ed21ea1fc314b3cf4 Mon Sep 17 00:00:00 2001 From: Ryan Saunders Date: Tue, 1 Oct 2024 00:03:50 -0700 Subject: [PATCH 1/2] Support BasedOnStyle: file:blah.clang-format --- clang/inclu

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

2024-10-08 Thread via cfe-commits
yonghong-song wrote: For About whether we should sign-extend for 8- and 16-bit load-acquires (brought up by Yonghong): All ARM64 insns that match acquiring_load seem to zero-extend the value before writing it to register, like, LDAPRH: Load-Acquire RCpc Register Halfword derives an a

[clang] Support BasedOnStyle referencing an arbitrary file (PR #110634)

2024-10-08 Thread Ryan Saunders via cfe-commits
jediry wrote: > Can this have some unit test? Done. Added docs as well. https://github.com/llvm/llvm-project/pull/110634 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Format clang/lib/Sema/Sema.cpp (PR #111518)

2024-10-08 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: Is there a need for the changes? (Are you making a significant number of changes in the file, or is this just a drive-by cleanup?) Generally, we don't do sweeping formatting changes: > Avoid committing formatting- or whitespace-only changes outside of code you > plan to ma

[clang] 7e31eaa - [libc++] Remove unused HAVE_LIBCXXABI variable from Android cache (#111007)

2024-10-08 Thread via cfe-commits
Author: Louis Dionne Date: 2024-10-08T13:16:47-04:00 New Revision: 7e31eaab575d15384654ed989717e5579e963e72 URL: https://github.com/llvm/llvm-project/commit/7e31eaab575d15384654ed989717e5579e963e72 DIFF: https://github.com/llvm/llvm-project/commit/7e31eaab575d15384654ed989717e5579e963e72.diff

[clang] [libc++] Remove unused HAVE_LIBCXXABI variable from Android cache (PR #111007)

2024-10-08 Thread Louis Dionne via cfe-commits
https://github.com/ldionne closed https://github.com/llvm/llvm-project/pull/111007 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Improve type traits recognition in `__has_builtin` (PR #111516)

2024-10-08 Thread via cfe-commits
https://github.com/cor3ntin updated https://github.com/llvm/llvm-project/pull/111516 >From 94874b7acb9ce763f502b74bc50d983ee3012d53 Mon Sep 17 00:00:00 2001 From: Corentin Jabot Date: Tue, 8 Oct 2024 12:28:24 +0200 Subject: [PATCH 1/2] [Clang] Improve type traits recognition in `__has_builtin`

[clang] [clang] Track function template instantiation from definition (PR #110387)

2024-10-08 Thread Matheus Izvekov via cfe-commits
https://github.com/mizvekov updated https://github.com/llvm/llvm-project/pull/110387 >From 28e582bc3b3058aa5ba946c9eb9b3d0e989b5c28 Mon Sep 17 00:00:00 2001 From: Matheus Izvekov Date: Sat, 28 Sep 2024 14:28:58 -0300 Subject: [PATCH] [clang] Track function template instantiation from definition

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2024-10-08 Thread via cfe-commits
@@ -0,0 +1,190 @@ +//===--- Mustache.h -*- 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] Update llvm::Registry to work for LLVM shared library builds on windows (PR #109024)

2024-10-08 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman commented: These changes LGTM but precommit CI was unable to run, so it would be nice if that could be re-run to ensure it comes back green before landing. https://github.com/llvm/llvm-project/pull/109024 ___ cfe-commit

[clang] [clang] Track function template instantiation from definition (PR #110387)

2024-10-08 Thread Matheus Izvekov via cfe-commits
mizvekov wrote: Now this is rebased on top of the `getTemplateInstantiationArgs` refactoring. https://github.com/llvm/llvm-project/pull/110387 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-c

[clang] Make PCH's respect any VFS specified. (PR #106577)

2024-10-08 Thread Henrik Karlsson via cfe-commits
honkstar1 wrote: I'm working with Neil and I've just tried changing our system to work the way where all our rsp etc use virtual paths and then create a vfsoverlay that points to the "right" places... it almost works for portable pch. What is not working is "#include_next".. that gets resolved

[clang] [llvm] [HLSL] Implement `WaveReadLaneAt` intrinsic (PR #111010)

2024-10-08 Thread Farzon Lotfi via cfe-commits
@@ -428,6 +431,7 @@ bool SPIRVInstructionSelector::spvSelect(Register ResVReg, case TargetOpcode::G_INTRINSIC: case TargetOpcode::G_INTRINSIC_W_SIDE_EFFECTS: + case TargetOpcode::G_INTRINSIC_CONVERGENT: farzonl wrote: Is there anything that distinguishes

[clang] [llvm] [HLSL] Implement `WaveReadLaneAt` intrinsic (PR #111010)

2024-10-08 Thread Farzon Lotfi via cfe-commits
https://github.com/farzonl approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/111010 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

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

2024-10-08 Thread Aiden Grossman via cfe-commits
https://github.com/boomanaiden154 requested changes to this pull request. The documentation build workflow is not really the correct place to put this. Also, why can't we just run the python script as part of building the docs instead of committing the result of the script to the repository? h

[clang] [SystemZ][z/OS] Add z/OS customization file (PR #111182)

2024-10-08 Thread Abhina Sree via cfe-commits
https://github.com/abhina-sree approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/82 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [InstrPGO] Instrument sampling profile based cold function (PR #109837)

2024-10-08 Thread Ellis Hoag via cfe-commits
@@ -1119,6 +1125,18 @@ PassBuilder::buildModuleSimplificationPipeline(OptimizationLevel Level, // removed. MPM.addPass( PGOIndirectCallPromotion(true /* IsInLTO */, true /* SamplePGO */)); + +if (InstrumentSampleColdFuncPath.getNumOccurrences() && +

[clang-tools-extra] a199fb1 - [clang-tidy] Only expand macros in modernize-use-std-format/print (#97911)

2024-10-08 Thread via cfe-commits
Author: Mike Crowe Date: 2024-10-08T22:03:58+02:00 New Revision: a199fb1229987d0885a4367e3a439db336069156 URL: https://github.com/llvm/llvm-project/commit/a199fb1229987d0885a4367e3a439db336069156 DIFF: https://github.com/llvm/llvm-project/commit/a199fb1229987d0885a4367e3a439db336069156.diff LO

[clang-tools-extra] [clang-tidy] Only expand macros in modernize-use-std-format/print (PR #97911)

2024-10-08 Thread Julian Schmidt via cfe-commits
5chmidti wrote: Yep, thanks. Sorry for the delay https://github.com/llvm/llvm-project/pull/97911 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Only expand macros in modernize-use-std-format/print (PR #97911)

2024-10-08 Thread Julian Schmidt via cfe-commits
https://github.com/5chmidti closed https://github.com/llvm/llvm-project/pull/97911 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Allow `ConditionalOperator` fast-math flags to be overridden by `pragma float_control` (PR #105912)

2024-10-08 Thread Andy Kaylor via cfe-commits
andykaylor wrote: @rjmccall I understand your point, and I think you're raising a good question. Let's walk through an example that illustrates why we currently want FMF on phis and selects and see if we can agree on an alternative way to handle it. In a comment on https://github.com/llvm/llvm

[clang] [clang] assume_aligned incorrectly diagnoses a dependent return type (PR #111573)

2024-10-08 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/111573 >From dea97ae4f893774489bfd423e9536e486f022bb9 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Tue, 8 Oct 2024 20:12:45 +0200 Subject: [PATCH] [clang] assume_aligned incorrectly diagnoses a dependent ret

[clang] [HLSL] Make HLSLAttributedResourceType canonical and add code paths to convert HLSL types to DirectX target types (PR #110327)

2024-10-08 Thread Chris B via cfe-commits
@@ -3437,6 +3437,9 @@ static void encodeTypeForFunctionPointerAuth(const ASTContext &Ctx, OS << II->getLength() << II->getName(); return; } + case Type::HLSLAttributedResource: llvm-beanz wrote: This should maybe be higher up with the "should never

[clang] [HLSL] Make HLSLAttributedResourceType canonical and add code paths to convert HLSL types to DirectX target types (PR #110327)

2024-10-08 Thread Chris B via cfe-commits
@@ -3943,6 +3943,9 @@ void ItaniumRTTIBuilder::BuildVTablePointer(const Type *Ty) { // abi::__pointer_to_member_type_info. VTableName = "_ZTVN10__cxxabiv129__pointer_to_member_type_infoE"; break; + + case Type::HLSLAttributedResource: +llvm_unreachable("not ye

[clang] [HLSL] Make HLSLAttributedResourceType canonical and add code paths to convert HLSL types to DirectX target types (PR #110327)

2024-10-08 Thread Chris B via cfe-commits
@@ -4205,6 +4208,9 @@ llvm::Constant *ItaniumRTTIBuilder::BuildTypeInfo( case Type::Atomic: // No fields, at least for the moment. break; + + case Type::HLSLAttributedResource: +llvm_unreachable("not yet implemented"); llvm-beanz wrote: This too

[clang] [HLSL] Make HLSLAttributedResourceType canonical and add code paths to convert HLSL types to DirectX target types (PR #110327)

2024-10-08 Thread Chris B via cfe-commits
https://github.com/llvm-beanz commented: A few (mostly small) comments https://github.com/llvm/llvm-project/pull/110327 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Make HLSLAttributedResourceType canonical and add code paths to convert HLSL types to DirectX target types (PR #110327)

2024-10-08 Thread Chris B via cfe-commits
@@ -13672,6 +13690,9 @@ static QualType getCommonNonSugarTypeNode(ASTContext &Ctx, const Type *X, TX->getDepth(), TX->getIndex(), TX->isParameterPack(), getCommonDecl(TX->getDecl(), TY->getDecl())); } + case Type::HLSLAttributedResource: { l

[clang] [HLSL] Make HLSLAttributedResourceType canonical and add code paths to convert HLSL types to DirectX target types (PR #110327)

2024-10-08 Thread Chris B via cfe-commits
@@ -29,19 +29,40 @@ class DirectXTargetCodeGenInfo : public TargetCodeGenInfo { llvm::Type *DirectXTargetCodeGenInfo::getHLSLType(CodeGenModule &CGM, const Type *Ty) const { - auto *BuiltinTy = dyn_cast(Ty); - if (!BuiltinTy

[libcxx] [libcxxabi] [libunwind] [runtimes] Always define cxx_shared, cxx_static & other targets (PR #80007)

2024-10-08 Thread Louis Dionne via cfe-commits
https://github.com/ldionne updated https://github.com/llvm/llvm-project/pull/80007 >From 447159a21d73d6b4b5c6f6c4710231f01e0af4fc Mon Sep 17 00:00:00 2001 From: Louis Dionne Date: Wed, 12 Oct 2022 18:06:32 -0400 Subject: [PATCH] [runtimes] Always define cxx_shared, cxx_static & other targets

[clang] [llvm] [HLSL] Implement `WaveReadLaneAt` intrinsic (PR #111010)

2024-10-08 Thread Finn Plummer via cfe-commits
@@ -87,6 +87,7 @@ class CGHLSLRuntime { GENERATE_HLSL_INTRINSIC_FUNCTION(SDot, sdot) GENERATE_HLSL_INTRINSIC_FUNCTION(UDot, udot) GENERATE_HLSL_INTRINSIC_FUNCTION(WaveIsFirstLane, wave_is_first_lane) + GENERATE_HLSL_INTRINSIC_FUNCTION(WaveReadLaneAt, waveReadLaneAt)

[clang] [llvm] [InstrPGO] Instrument sampling profile based cold function (PR #109837)

2024-10-08 Thread Lei Wang via cfe-commits
https://github.com/wlei-llvm updated https://github.com/llvm/llvm-project/pull/109837 >From 07a2cab3fa5df2965f9f7da9ee2d3603581a47f1 Mon Sep 17 00:00:00 2001 From: wlei Date: Sun, 22 Sep 2024 20:23:20 -0700 Subject: [PATCH 1/5] [InstrPGO] Instrument sampling profile based cold function --- c

[clang] [llvm] [InstrPGO] Instrument sampling profile based cold function (PR #109837)

2024-10-08 Thread Lei Wang via cfe-commits
@@ -1119,6 +1125,18 @@ PassBuilder::buildModuleSimplificationPipeline(OptimizationLevel Level, // removed. MPM.addPass( PGOIndirectCallPromotion(true /* IsInLTO */, true /* SamplePGO */)); + +if (InstrumentSampleColdFuncPath.getNumOccurrences() && +

[clang] [llvm] [HLSL] Implement `WaveReadLaneAt` intrinsic (PR #111010)

2024-10-08 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/111010 >From 70089645ec5cf62b491a56df96ec46f4328fbc11 Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Thu, 3 Oct 2024 11:43:51 -0700 Subject: [PATCH 01/10] [HLSL] Implement `WaveReadLaneAt` intrinsic - create a

[clang] [llvm] [HLSL] Implement `WaveReadLaneAt` intrinsic (PR #111010)

2024-10-08 Thread Finn Plummer via cfe-commits
@@ -0,0 +1,26 @@ +// RUN: %clang_cc1 -finclude-default-header -triple dxil-pc-shadermodel6.6-library %s -fnative-half-type -emit-llvm-only -disable-llvm-passes -verify -verify-ignore-unexpected inbelic wrote: Good catch. There are no ignored diagnostics and it

[clang] [clang] Allow `ConditionalOperator` fast-math flags to be overridden by `pragma float_control` (PR #105912)

2024-10-08 Thread Andy Kaylor via cfe-commits
andykaylor wrote: > Yeah, the conditional operator doesn't do any floating-path math itself. If > the first operand is a floating-point expression, we should always be > modeling that with a float-to-boolean conversion, and the flags should go > there (if they're necessary — I didn't think com

[clang] [ItaniumCXXABI] Mark RTTI type name as global unnamed_addr (PR #111343)

2024-10-08 Thread via cfe-commits
luxufan wrote: > https://itanium-cxx-abi.github.io/cxx-abi/abi.html#vague-rtti and > https://itanium-cxx-abi.github.io/cxx-abi/abi.html#typeid in the ABI require > the type name string to be globally unique, and some `std::type_info` > implementations rely on that. You might be able to do this

[clang] [llvm] [clang][LLVM Demangler] Add an assertion that validates that all mang… (PR #111391)

2024-10-08 Thread Viktoriia Bakalova via cfe-commits
@@ -1967,6 +1967,10 @@ def fclang_abi_compat_EQ : Joined<["-"], "fclang-abi-compat=">, Group, MetaVarName<"">, Values<".,latest">, HelpText<"Attempt to match the ABI of Clang ">; +def fno_demangling_failures: Flag<["-"], "fno-demangling-failures">, Group,

[clang] [clang][RISCV] Extend intrinsic size check variable from 16 -> 32 bits. NFC (PR #111481)

2024-10-08 Thread Pengcheng Wang via cfe-commits
wangpc-pp wrote: > Why don’t any of our lit tests that use every intrinsic catch it? We don't see any error, is it because your downstream added some intrinsics? https://github.com/llvm/llvm-project/pull/111481 ___ cfe-commits mailing list cfe-commits

[clang] [clang][RISCV] Extend intrinsic size check variable from 16 -> 32 bits. NFC (PR #111481)

2024-10-08 Thread Craig Topper via cfe-commits
topperc wrote: Why don’t any of our lit tests that use every intrinsic catch it? https://github.com/llvm/llvm-project/pull/111481 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [clang][LLVM Demangler] Add an assertion that validates that all mang… (PR #111391)

2024-10-08 Thread Viktoriia Bakalova via cfe-commits
@@ -462,6 +462,9 @@ ENUM_CODEGENOPT(ZeroCallUsedRegs, llvm::ZeroCallUsedRegs::ZeroCallUsedRegsKind, /// non-deleting destructors. (No effect on Microsoft ABI.) CODEGENOPT(CtorDtorReturnThis, 1, 0) +/// Whether to validate if a produced mangled name can be demangled with LLVM

[clang] [llvm] [clang][LLVM Demangler] Add an assertion that validates that all mang… (PR #111391)

2024-10-08 Thread Viktoriia Bakalova via cfe-commits
https://github.com/VitaNuo edited https://github.com/llvm/llvm-project/pull/111391 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][RISCV] Extend intrinsic size check variable from 16 -> 32 bits. NFC (PR #111481)

2024-10-08 Thread Craig Topper via cfe-commits
@@ -399,7 +399,7 @@ void RISCVIntrinsicManagerImpl::InitRVVIntrinsic( Record.HasFRMRoundModeOp); // Put into IntrinsicList. - uint16_t Index = IntrinsicList.size(); + uint32_t Index = IntrinsicList.size(); topperc wrote

[clang] [clang][RISCV] Extend intrinsic size check variable from 16 -> 32 bits. NFC (PR #111481)

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

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

2024-10-08 Thread Yi Kong via cfe-commits
kongy wrote: There is a case that becomes invalid with this patch, is it expected behaviour? ``` template struct Traits { using Type = Traits; }; template void bar(typename Traits::Type... args) { FillVRegs(args...); } template void FillVRegs(typename Traits::Type...); template void Fill

[clang] [clang][Sema] Bad register variable type error should point to the type (PR #110239)

2024-10-08 Thread via cfe-commits
https://github.com/Sirraide approved this pull request. Looks like CI is still mad at you for some reason so that still needs to be looked into, but other than that this lgtm. https://github.com/llvm/llvm-project/pull/110239 ___ cfe-commits mailing li

[clang] [clang][RISCV] Extend intrinsic size check variable from 16 -> 32 bits. NFC (PR #111481)

2024-10-08 Thread Craig Topper via cfe-commits
topperc wrote: Does the number intrinsics vary with the number of extensions enabled? Maybe we don't have a test with all extensions? https://github.com/llvm/llvm-project/pull/111481 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://list

[clang] Effect analysis: correctly detect `(x ? a : b)` as nonblocking when a and b are (PR #111224)

2024-10-08 Thread via cfe-commits
https://github.com/Sirraide approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/111224 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Effect analysis: correctly detect `(x ? a : b)` as nonblocking when a and b are (PR #111224)

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

[clang] 4d218ca - [Clang] [Sema] Effects: Correctly detect `(x ? a : b)` as nonblocking when a and b are (#111224)

2024-10-08 Thread via cfe-commits
Author: Doug Wyatt Date: 2024-10-08T10:20:05+02:00 New Revision: 4d218caa7716743061e8d34d61b2181c94b16440 URL: https://github.com/llvm/llvm-project/commit/4d218caa7716743061e8d34d61b2181c94b16440 DIFF: https://github.com/llvm/llvm-project/commit/4d218caa7716743061e8d34d61b2181c94b16440.diff LO

[clang] [llvm] [clang][LLVM Demangler] Add an assertion that validates that all mang… (PR #111391)

2024-10-08 Thread Viktoriia Bakalova via cfe-commits
VitaNuo wrote: > Since this is being done as an assert, this is something that really only > applies during debug mode. I dont think this compiler flag makes sense > because of it. The reason I am adding a flag on top of an assert is that there are unfortunately still many mangled names produ

[clang] Effect analysis: correctly detect `(x ? a : b)` as nonblocking when a and b are (PR #111224)

2024-10-08 Thread via cfe-commits
Sirraide wrote: @dougsonos Maybe you should ask for commit access since you’ll likely be contributing more patches to this in the future as I understand it? CC @AaronBallman Does that still work like it used to or did your maintainers rfc change something about that too? https://github.com/ll

[clang] Effect analysis: correctly detect `(x ? a : b)` as nonblocking when a and b are (PR #111224)

2024-10-08 Thread via cfe-commits
Sirraide wrote: Oh, also, are there any other places where we should maybe be using `FunctionEffectsRef::get()`? https://github.com/llvm/llvm-project/pull/111224 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/ma

[clang] f658c1b - Recommit "[RISCV][FMV] Support target_version" (#111096)" (#111333)

2024-10-08 Thread via cfe-commits
Author: Piyou Chen Date: 2024-10-08T16:26:55+08:00 New Revision: f658c1bf4a9d74518ff55a37184b76ec5dec9a8b URL: https://github.com/llvm/llvm-project/commit/f658c1bf4a9d74518ff55a37184b76ec5dec9a8b DIFF: https://github.com/llvm/llvm-project/commit/f658c1bf4a9d74518ff55a37184b76ec5dec9a8b.diff LO

[clang] Recommit "[RISCV][FMV] Support target_version" (#111096)" (PR #111333)

2024-10-08 Thread Piyou Chen via cfe-commits
https://github.com/BeMg closed https://github.com/llvm/llvm-project/pull/111333 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Introduce [[clang::lifetime_capture_by(X)]] (PR #111499)

2024-10-08 Thread Utkarsh Saxena via cfe-commits
https://github.com/usx95 created https://github.com/llvm/llvm-project/pull/111499 This implements the RFC https://discourse.llvm.org/t/rfc-introduce-clang-lifetime-capture-by-x/81371 >From b1368f676ac5f55741df021c2697d3b46fd2c92d Mon Sep 17 00:00:00 2001 From: Utkarsh Saxena Date: Tue, 8 Oct

[clang] [Clang] Instantiate the correct lambda call operator (PR #110446)

2024-10-08 Thread via cfe-commits
https://github.com/Sirraide updated https://github.com/llvm/llvm-project/pull/110446 >From a61f3e94d0636f4294f3be440d79b83889771800 Mon Sep 17 00:00:00 2001 From: Sirraide Date: Mon, 30 Sep 2024 02:58:31 +0200 Subject: [PATCH 1/3] [Clang] Instantiate the correct lambda call operator --- clang

[clang] [llvm] [ARM] Fix musttail calls (PR #109943)

2024-10-08 Thread Oliver Stannard via cfe-commits
https://github.com/ostannard updated https://github.com/llvm/llvm-project/pull/109943 >From 9b2646806978429395232ed596429ef281bcb26b Mon Sep 17 00:00:00 2001 From: Oliver Stannard Date: Thu, 9 May 2024 12:58:41 +0100 Subject: [PATCH 01/10] [ARM] Re-generate a test --- llvm/test/CodeGen/ARM/fp

[clang] [llvm] [ARM] Fix musttail calls (PR #109943)

2024-10-08 Thread Oliver Stannard via cfe-commits
@@ -0,0 +1,345 @@ +; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 5 +; RUN: llc -mtriple=armv7a-none-eabi %s -o - | FileCheck %s + +declare i32 @many_args_callee(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5) + +define i32 @many

[clang] [clang-format] Add an option to control indentation of `export { ... }` (PR #110381)

2024-10-08 Thread via cfe-commits
@@ -26588,10 +26613,7 @@ TEST_F(FormatTest, Cpp20ModulesSupport) { " int foo;\n" "};", Style); - verifyFormat("export {\n" - " int foo;\n" - "};", - Style); + verifyFormat("export { int f

[clang] [llvm] [clang][LLVM Demangler] Add an assertion that validates that all mang… (PR #111391)

2024-10-08 Thread Ilya Biryukov via cfe-commits
ilya-biryukov wrote: Sorry for jumping in late. I think Erich is on point that having a flag that controls an assertion is a bit of a red flag as we are mixing build configuration and runtime configuration. It is at least unusual and may cause confusion. After thinking about this a bit more,

[clang-tools-extra] [clangd] Harden incomingCalls() against possible misinterpretation of a range as pertaining to the wrong file (PR #111616)

2024-10-08 Thread Nathan Ridge via cfe-commits
@@ -2292,9 +2289,26 @@ incomingCalls(const CallHierarchyItem &Item, const SymbolIndex *Index) { Index->lookup(ContainerLookup, [&](const Symbol &Caller) { auto It = CallsIn.find(Caller.ID); assert(It != CallsIn.end()); -if (auto CHI = symbolToCallHierarchyItem(Ca

[clang-tools-extra] [clangd] Harden incomingCalls() against possible misinterpretation of a range as pertaining to the wrong file (PR #111616)

2024-10-08 Thread Nathan Ridge via cfe-commits
@@ -2292,9 +2289,26 @@ incomingCalls(const CallHierarchyItem &Item, const SymbolIndex *Index) { Index->lookup(ContainerLookup, [&](const Symbol &Caller) { auto It = CallsIn.find(Caller.ID); assert(It != CallsIn.end()); -if (auto CHI = symbolToCallHierarchyItem(Ca

[clang] [lld] [lld][LoongArch] Enable relaxation when --relax option is passed (PR #111488)

2024-10-08 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay edited https://github.com/llvm/llvm-project/pull/111488 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [lld] [lld][LoongArch] Enable relaxation when --relax option is passed (PR #111488)

2024-10-08 Thread Fangrui Song via cfe-commits
@@ -1462,6 +1462,8 @@ template void Writer::finalizeAddressDependentContent() { for (;;) { bool changed = ctx.target->needsThunks ? tc.createThunks(pass, ctx.outputSections) + : ctx.arg.emachine == EM_LOONGARCH && !ctx.arg.relax

[clang] [lld] [lld][LoongArch] Enable relaxation when --relax option is passed (PR #111488)

2024-10-08 Thread Fangrui Song via cfe-commits
@@ -134,6 +134,13 @@ void loongarch::getLoongArchTargetFeatures(const Driver &D, (!Args.hasArgNoClaim(clang::driver::options::OPT_march_EQ))) Features.push_back("+lsx"); + // -mrelax is default, unless -mno-relax is specified. MaskRay wrote: This

[clang] [lld] [lld][LoongArch] Enable relaxation when --relax option is passed (PR #111488)

2024-10-08 Thread Fangrui Song via cfe-commits
https://github.com/MaskRay commented: We split clang and lld changes. https://github.com/llvm/llvm-project/pull/111488 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] WIP: Warn on mismatched RequiresCapability attributes (PR #67520)

2024-10-08 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr updated https://github.com/llvm/llvm-project/pull/67520 >From 55efd18bb177150a1fd170cb1535e225854967a6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Thu, 20 Jun 2024 07:39:20 +0200 Subject: [PATCH] Warn on RequiresCapability attribute mismatch -

[clang] [clang] WIP: Warn on mismatched RequiresCapability attributes (PR #67520)

2024-10-08 Thread Timm Baeder via cfe-commits
Timm =?utf-8?q?Bäder?= , Timm =?utf-8?q?Bäder?= , Timm =?utf-8?q?Bäder?= , Timm =?utf-8?q?Bäder?= , Timm =?utf-8?q?Bäder?= , Timm =?utf-8?q?Bäder?= , Timm =?utf-8?q?Bäder?= Message-ID: In-Reply-To: @@ -2249,7 +2249,7 @@ void fooF1(Foo *f) EXCLUSIVE_LOCKS_REQUIRED(f->mu_) { f

[clang] [HLSL] Make HLSLAttributedResourceType canonical and add code paths to convert HLSL types to DirectX target types (PR #110327)

2024-10-08 Thread Helena Kotas via cfe-commits
@@ -3437,6 +3437,9 @@ static void encodeTypeForFunctionPointerAuth(const ASTContext &Ctx, OS << II->getLength() << II->getName(); return; } + case Type::HLSLAttributedResource: hekota wrote: The other "should never get here"' is in a different swit

[clang] [HLSL] Make HLSLAttributedResourceType canonical and add code paths to convert HLSL types to DirectX target types (PR #110327)

2024-10-08 Thread Helena Kotas via cfe-commits
@@ -13672,6 +13690,9 @@ static QualType getCommonNonSugarTypeNode(ASTContext &Ctx, const Type *X, TX->getDepth(), TX->getIndex(), TX->isParameterPack(), getCommonDecl(TX->getDecl(), TY->getDecl())); } + case Type::HLSLAttributedResource: { h

[clang] [-Wunsafe-buffer-usage] Add user documentation. (PR #111624)

2024-10-08 Thread Artem Dergachev via cfe-commits
https://github.com/haoNoQ created https://github.com/llvm/llvm-project/pull/111624 This is an attempt to finally land the documentation that I initially wrote in https://reviews.llvm.org/D136811 - which doubled as RFC - and I sincerely apologize for not doing this sooner. I've rewritten most

[clang] [-Wunsafe-buffer-usage] Add user documentation. (PR #111624)

2024-10-08 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Artem Dergachev (haoNoQ) Changes This is an attempt to finally land the documentation that I initially wrote in https://reviews.llvm.org/D136811 - which doubled as RFC - and I sincerely apologize for not doing this sooner. I've rewritten

[clang] [Clang][perf-training] Do build of libLLVMSupport for perf training (PR #111625)

2024-10-08 Thread Tom Stellard via cfe-commits
https://github.com/tstellar created https://github.com/llvm/llvm-project/pull/111625 This adds a build of the libLLVMSupport to the lit suite that is used for generating profile data. This helps to improve both PGO and BOLT optimization of clang over the existing hello world training program.

[clang] [llvm] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds (PR #90933)

2024-10-08 Thread Teresa Johnson via cfe-commits
@@ -1513,6 +1522,171 @@ class InProcessThinBackend : public ThinBackendProc { return Error::success(); } }; + +/// This backend is utilized in the first round of a two-codegen round process. +/// It first saves optimized bitcode files to disk before the codegen process +/

[clang] [llvm] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds (PR #90933)

2024-10-08 Thread Teresa Johnson via cfe-commits
@@ -0,0 +1,94 @@ +; This test verifies whether we can outline a singleton instance (i.e., an instance that does not repeat) teresajohnson wrote: This test seems like mostly an overlap of the caching test, with the exception of the regular LTO module interaction

[clang] [llvm] [CGData][ThinLTO] Global Outlining with Two-CodeGen Rounds (PR #90933)

2024-10-08 Thread Teresa Johnson via cfe-commits
@@ -1513,6 +1522,171 @@ class InProcessThinBackend : public ThinBackendProc { return Error::success(); } }; + +/// This backend is utilized in the first round of a two-codegen round process. +/// It first saves optimized bitcode files to disk before the codegen process +/

[clang] [Clang][perf-training] Do build of libLLVMSupport for perf training (PR #111625)

2024-10-08 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Tom Stellard (tstellar) Changes This adds a build of the libLLVMSupport to the lit suite that is used for generating profile data. This helps to improve both PGO and BOLT optimization of clang over the existing hello world training progr

[clang] [Sema] Support negation/parens with __builtin_available (PR #111439)

2024-10-08 Thread Helena Kotas via cfe-commits
https://github.com/hekota approved this pull request. LGTM! https://github.com/llvm/llvm-project/pull/111439 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Switch DirectX Target to use the Itanium ABI (PR #111632)

2024-10-08 Thread Greg Roth via cfe-commits
@@ -1,35 +1,66 @@ -// RUN: %clang_cc1 -finclude-default-header -x hlsl -triple \ -// RUN: dxil-pc-shadermodel6.3-library %s \ +// RUN: %clang_cc1 -finclude-default-header -triple dxil-pc-shadermodel6.3-library %s \ // RUN: -emit-llvm -disable-llvm-passes -o - | FileCheck %s

[clang] Switch DirectX Target to use the Itanium ABI (PR #111632)

2024-10-08 Thread Greg Roth via cfe-commits
https://github.com/pow2clk commented: Just a few comments to explain the changes that aren't just mangling style changes. https://github.com/llvm/llvm-project/pull/111632 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/c

[clang] Switch DirectX Target to use the Itanium ABI (PR #111632)

2024-10-08 Thread Greg Roth via cfe-commits
@@ -1,93 +1,96 @@ -// RUN: %clang_cc1 -std=hlsl2021 -finclude-default-header -x hlsl -triple \ -// RUN: dxil-pc-shadermodel6.3-library %s -fnative-half-type \ -// RUN: -emit-llvm -disable-llvm-passes -o - | FileCheck %s \ -// RUN: --check-prefixes=CHECK,NATIVE_HALF -// RUN:

[clang] Switch DirectX Target to use the Itanium ABI (PR #111632)

2024-10-08 Thread Greg Roth via cfe-commits
@@ -1,7 +1,7 @@ -// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.0-compute -std=hlsl202x -emit-llvm -disable-llvm-passes %s -o - | FileCheck %s --check-prefixes=CS,NOINLINE,CHECK -// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.3-library -std=hlsl202x -emit-llvm -disable-llvm-p

[clang] Switch DirectX Target to use the Itanium ABI (PR #111632)

2024-10-08 Thread Greg Roth via cfe-commits
@@ -56,14 +55,12 @@ void main() { // CHECK-LABEL: define {{.*}}DoSilly // CHECK-NEXT:entry: -// CHECK-NEXT: [[ResPtr:%.*]] = alloca ptr // CHECK-NEXT: [[ThisPtrAddr:%.*]] = alloca ptr -// CHECK-NEXT: store ptr [[AggRes:%.*]], ptr [[ResPtr]] // CHECK-NEXT: store ptr {{.*}

[clang] Switch DirectX Target to use the Itanium ABI (PR #111632)

2024-10-08 Thread Greg Roth via cfe-commits
@@ -289,17 +289,19 @@ void setFour(inout int I) { // CHECK: [[B:%.*]] = alloca %struct.B // CHECK: [[Tmp:%.*]] = alloca i32 -// CHECK: [[BFLoad:%.*]] = load i32, ptr [[B]] -// CHECK: [[BFshl:%.*]] = shl i32 [[BFLoad]], 24 -// CHECK: [[BFashr:%.*]] = ashr i32 [[BFshl]], 24 -//

[clang] Switch DirectX Target to use the Itanium ABI (PR #111632)

2024-10-08 Thread Greg Roth via cfe-commits
@@ -13,16 +13,16 @@ void InitBuf(RWBuffer buf) { } // CHECK-NOT: _Init_thread_epoch -// CHECK: define internal void @"?main@@YAXXZ" +// CHECK: define internal void @_Z4mainv // CHECK-NEXT: entry: // CHECK-NEXT: [[Tmp1:%.*]] = alloca %"class.hlsl::RWBuffer" -// CHECK-NEXT: [[

[clang] Switch DirectX Target to use the Itanium ABI (PR #111632)

2024-10-08 Thread Greg Roth via cfe-commits
https://github.com/pow2clk edited https://github.com/llvm/llvm-project/pull/111632 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

  1   2   3   4   5   >