[clang] [llvm] [HLSL][RootSignature] Add infastructure to parse parameters (PR #133800)

2025-04-14 Thread Finn Plummer via cfe-commits
@@ -32,11 +39,19 @@ struct DescriptorTable { using ClauseType = llvm::dxil::ResourceClass; struct DescriptorTableClause { ClauseType Type; + Register Register; + uint32_t Space = 0; }; // Models RootElement : DescriptorTable | DescriptorTableClause using RootElement =

[clang] [llvm] [HLSL] Implement the `faceforward` intrinsic (PR #135878)

2025-04-16 Thread Finn Plummer via cfe-commits
@@ -137,6 +137,42 @@ bool SemaSPIRV::CheckSPIRVBuiltinFunctionCall(unsigned BuiltinID, TheCall->setType(RetTy); break; } + case SPIRV::BI__builtin_spirv_faceforward: { +if (SemaRef.checkArgCount(TheCall, 3)) + return true; + +// check if all arguments h

[clang] [llvm] [HLSL] Implement the `faceforward` intrinsic (PR #135878)

2025-04-16 Thread Finn Plummer via cfe-commits
@@ -137,6 +137,42 @@ bool SemaSPIRV::CheckSPIRVBuiltinFunctionCall(unsigned BuiltinID, TheCall->setType(RetTy); break; } + case SPIRV::BI__builtin_spirv_faceforward: { +if (SemaRef.checkArgCount(TheCall, 3)) + return true; + +// check if all arguments h

[clang] [llvm] [HLSL] Implement the `faceforward` intrinsic (PR #135878)

2025-04-16 Thread Finn Plummer via cfe-commits
https://github.com/inbelic commented: Just a collection of nits. LGTM https://github.com/llvm/llvm-project/pull/135878 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL] Implement the `faceforward` intrinsic (PR #135878)

2025-04-16 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/135878 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Add a warning for implicit bindings (PR #135909)

2025-04-16 Thread Finn Plummer via cfe-commits
@@ -3278,6 +3284,9 @@ void SemaHLSL::processExplicitBindingsOnDecl(VarDecl *VD) { << static_cast(RT); } } + + if (!HasBinding && VD->getType()->isHLSLResourceRecord()) inbelic wrote: I do also see the function `isResourceRecordTypeOrArrayOf`

[clang] [llvm] [HLSL] Implement the `faceforward` intrinsic (PR #135878)

2025-04-16 Thread Finn Plummer via cfe-commits
@@ -214,6 +214,53 @@ const inline double4 dst(double4 Src0, double4 Src1) { return __detail::dst_impl(Src0, Src1); } +//===--===// +// faceforward builtin +//===--

[clang] [llvm] [HLSL] Implement the `faceforward` intrinsic (PR #135878)

2025-04-16 Thread Finn Plummer via cfe-commits
@@ -0,0 +1,94 @@ +// RUN: %clang_cc1 -finclude-default-header -x hlsl -triple \ inbelic wrote: ```suggestion // RUN: %clang_cc1 -finclude-default-header -triple \ ``` `-x` just specifies the file extension, since the file is `.hlsl` it should naturally detect an

[clang] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-04-30 Thread Finn Plummer via cfe-commits
@@ -5209,6 +5211,92 @@ void Parser::ParseMicrosoftUuidAttributeArgs(ParsedAttributes &Attrs) { } } +void Parser::ParseMicrosoftRootSignatureAttributeArgs(ParsedAttributes &Attrs) { + assert(Tok.is(tok::identifier) && "Not a Microsoft attribute list"); + IdentifierInfo *R

[clang] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-04-30 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/137690 >From 0ab73ae597164aa039be69534056edbe26e55243 Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Mon, 28 Apr 2025 18:42:10 + Subject: [PATCH 01/10] [HLSL][RootSignature] Define and integrate rootsig clang a

[clang] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-04-30 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/137690 >From 0ab73ae597164aa039be69534056edbe26e55243 Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Mon, 28 Apr 2025 18:42:10 + Subject: [PATCH 1/8] [HLSL][RootSignature] Define and integrate rootsig clang att

[clang] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-05-01 Thread Finn Plummer via cfe-commits
@@ -5209,6 +5211,97 @@ void Parser::ParseMicrosoftUuidAttributeArgs(ParsedAttributes &Attrs) { } } +void Parser::ParseMicrosoftRootSignatureAttributeArgs(ParsedAttributes &Attrs) { + assert(Tok.is(tok::identifier) && + "Expected an identifier to denote which MS at

[clang] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-05-01 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/137690 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][RootSignatures] Conform to new std::optional calling conventions (PR #136747)

2025-04-24 Thread Finn Plummer via cfe-commits
https://github.com/inbelic closed https://github.com/llvm/llvm-project/pull/136747 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Add parsing of ShaderVisibility to DescriptorTable (PR #136751)

2025-04-24 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/136751 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Reland "[HLSL][RootSignature] Define and integrate HLSLRootSignatureAttr" (PR #134293)

2025-04-24 Thread Finn Plummer via cfe-commits
https://github.com/inbelic closed https://github.com/llvm/llvm-project/pull/134293 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Reland "[HLSL][RootSignature] Define and integrate HLSLRootSignatureAttr" (PR #134293)

2025-04-24 Thread Finn Plummer via cfe-commits
inbelic wrote: Closing as this would actually introduce a circular dependency between clangParse and clangSema, as surprisingly, clangParse has a dependency on clangSema. This will need to reland after we move the HLSLRootSignatureParser into an accessible location (most likely within clangSem

[clang] [llvm] [HLSL][RootSignature] Add parsing of DescriptorRangeFlags (PR #136775)

2025-04-24 Thread Finn Plummer via cfe-commits
@@ -91,11 +92,19 @@ class RootSignatureParser { /// Parsing methods of various enums std::optional parseShaderVisibility(); + std::optional + parseDescriptorRangeFlags(); inbelic wrote: Yep, adding spaces will make clang-format complain. https://github

[clang] [llvm] Reland "[HLSL][RootSignature] Implement initial parsing of the descriptor table clause params" (PR #136740)

2025-04-23 Thread Finn Plummer via cfe-commits
@@ -129,10 +129,10 @@ TEST_F(ParseHLSLRootSignatureTest, ValidParseEmptyTest) { TEST_F(ParseHLSLRootSignatureTest, ValidParseDTClausesTest) { const llvm::StringLiteral Source = R"cc( DescriptorTable( - CBV(), - SRV(), - Sampler(), - UAV() + CBV(b0

[clang] [HLSL] Put tests for compatibility overloads for 'clamp', 'isinf', 'min', and 'max' in own files (PR #137004)

2025-04-23 Thread Finn Plummer via cfe-commits
https://github.com/inbelic approved this pull request. Can use the [NFC] tag as well if you want https://github.com/llvm/llvm-project/pull/137004 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cf

[clang] [llvm] [HLSL][RootSignature] Add parsing of ShaderVisibility to DescriptorTable (PR #136751)

2025-04-24 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/136751 >From bf4bb7a08445df8f65cbee8b98e674fbbd154965 Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Tue, 22 Apr 2025 19:42:50 + Subject: [PATCH] [HLSL][RootSignature] Add parsing of ShaderVisibility to Descrip

[clang] [llvm] [HLSL][RootSignature] Add parsing of ShaderVisibility to DescriptorTable (PR #136751)

2025-04-24 Thread Finn Plummer via cfe-commits
https://github.com/inbelic reopened https://github.com/llvm/llvm-project/pull/136751 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][RootSignatures] Conform to new std::optional calling conventions (PR #136747)

2025-04-24 Thread Finn Plummer via cfe-commits
@@ -26,22 +26,14 @@ RootSignatureParser::RootSignatureParser(SmallVector &Elements, bool RootSignatureParser::parse() { // Iterate as many RootElements as possible - while (tryConsumeExpectedToken(TokenKind::kw_DescriptorTable)) { -// Dispatch onto parser method. -

[clang] [llvm] [HLSL][RootSignature] Add parsing of DescriptorRangeFlags (PR #136775)

2025-04-25 Thread Finn Plummer via cfe-commits
https://github.com/inbelic closed https://github.com/llvm/llvm-project/pull/136775 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Add parsing of remaining Descriptor Table params (PR #137038)

2025-04-25 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/137038 >From dd004171f5777dc68b700a5bf0f96c9c703a57c9 Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Wed, 23 Apr 2025 18:37:55 + Subject: [PATCH 1/2] pre-req: Add `unbounded` keyword to lexer --- clang/include

[clang] [llvm] [HLSL][RootSignature] Add parsing of remaining Descriptor Table params (PR #137038)

2025-04-25 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/137038 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [DirectX] Implement UseNativeLowPrecision shader flag analysis (PR #134288)

2025-04-10 Thread Finn Plummer via cfe-commits
@@ -282,10 +282,14 @@ void CGHLSLRuntime::addHLSLBufferLayoutType(const RecordType *StructType, void CGHLSLRuntime::finishCodeGen() { auto &TargetOpts = CGM.getTarget().getTargetOpts(); + auto &LangOpts = CGM.getLangOpts(); llvm::Module &M = CGM.getModule(); Triple T

[clang] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-04-28 Thread Finn Plummer via cfe-commits
https://github.com/inbelic created https://github.com/llvm/llvm-project/pull/137690 - Defines a new declaration node `HLSLRootSignature` in `DeclNodes.td` that will hold a reference to an in-memory construction of the root signature, namely an array of `hlsl::rootsig::RootElement`s - Defines

[clang] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-04-28 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/137690 >From 0ab73ae597164aa039be69534056edbe26e55243 Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Mon, 28 Apr 2025 18:42:10 + Subject: [PATCH 1/2] [HLSL][RootSignature] Define and integrate rootsig clang att

[clang] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-04-28 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/137690 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-04-28 Thread Finn Plummer via cfe-commits
@@ -3037,6 +3037,11 @@ void TextNodeDumper::VisitHLSLBufferDecl(const HLSLBufferDecl *D) { dumpName(D); } +void TextNodeDumper::VisitHLSLRootSignatureDecl( +const HLSLRootSignatureDecl *D) { + dumpName(D); inbelic wrote: We could extend this to dump m

[clang] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-04-28 Thread Finn Plummer via cfe-commits
@@ -949,6 +950,23 @@ void SemaHLSL::emitLogicalOperatorFixIt(Expr *LHS, Expr *RHS, << NewFnName << FixItHint::CreateReplacement(FullRange, OS.str()); } +void SemaHLSL::handleRootSignatureAttr(Decl *D, const ParsedAttr &AL) { + if (AL.getNumArgs() != 1) { +Diag(AL.g

[clang] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-04-28 Thread Finn Plummer via cfe-commits
@@ -0,0 +1,11 @@ +// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.3-library -x hlsl -o - %s -verify + +// Attr test + +[RootSignature()] // expected-error {{expected string literal as argument of 'RootSignature' attribute}} +void bad_root_signature_0() {} + +// expected-error@+2

[clang] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-04-28 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/137690 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL] Overloads for `lerp` with a scalar weight (PR #137877)

2025-04-29 Thread Finn Plummer via cfe-commits
https://github.com/inbelic approved this pull request. https://github.com/llvm/llvm-project/pull/137877 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-05-01 Thread Finn Plummer via cfe-commits
@@ -3037,6 +3037,11 @@ void TextNodeDumper::VisitHLSLBufferDecl(const HLSLBufferDecl *D) { dumpName(D); } +void TextNodeDumper::VisitHLSLRootSignatureDecl( +const HLSLRootSignatureDecl *D) { + dumpName(D); inbelic wrote: >From design we will block on

[clang] [llvm] [HLSL][RootSignature] Add parsing for empty RootConstants (PR #137999)

2025-05-01 Thread Finn Plummer via cfe-commits
@@ -252,6 +252,32 @@ TEST_F(ParseHLSLRootSignatureTest, ValidSamplerFlagsTest) { ASSERT_TRUE(Consumer->isSatisfied()); } +TEST_F(ParseHLSLRootSignatureTest, ValidParseRootConsantsTest) { inbelic wrote: Once we add the mandatory parameters then having an emp

[clang] [llvm] [HLSL][RootSignature] Implement Parsing of Descriptor Tables (PR #122982)

2025-03-07 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/122982 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Implement Parsing of Descriptor Tables (PR #122982)

2025-03-05 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/122982 >From 9fe6b897b161f7e40e4a5662ab2cad4dceed174e Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Thu, 13 Feb 2025 22:56:52 + Subject: [PATCH 01/15] [HLSL][RootSignature] Parse empty Descriptor Table Root El

[clang] [llvm] [HLSL][RootSignature] Implement Parsing of Descriptor Tables (PR #122982)

2025-03-05 Thread Finn Plummer via cfe-commits
@@ -0,0 +1,417 @@ +#include "clang/Parse/ParseHLSLRootSignature.h" + +#include "clang/Lex/LiteralSupport.h" + +#include "llvm/Support/raw_ostream.h" + +using namespace llvm::hlsl::rootsig; + +namespace clang { +namespace hlsl { + +static std::string FormatTokenKinds(ArrayRef Kinds

[clang] [HLSL][RootSignature] Implement Lexing of DescriptorTables (PR #122981)

2025-02-13 Thread Finn Plummer via cfe-commits
@@ -0,0 +1,89 @@ +//===--- ParseHLSLRootSignature.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: Apa

[clang] [HLSL][RootSignature] Implement Lexing of DescriptorTables (PR #122981)

2025-02-13 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/122981 >From 98deff6a407b912852e70b2bdc3618aaec8a1931 Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Fri, 24 Jan 2025 22:23:39 + Subject: [PATCH 01/18] [HLSL][RootSignature] Initial Lexer Definition with puncua

[clang] [HLSL][RootSignature] Implement Lexing of DescriptorTables (PR #122981)

2025-02-12 Thread Finn Plummer via cfe-commits
@@ -0,0 +1,194 @@ +#include "clang/Parse/ParseHLSLRootSignature.h" + +namespace clang { +namespace hlsl { + +// Lexer Definitions + +static bool IsNumberChar(char C) { + // TODO(#126565): extend for float support exponents + return isdigit(C); // integer support +} + +bool RootS

[clang] [HLSL][RootSignature] Implement Lexing of DescriptorTables (PR #122981)

2025-02-12 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/122981 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL][RootSignature] Implement Lexing of DescriptorTables (PR #122981)

2025-02-12 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/122981 >From 98deff6a407b912852e70b2bdc3618aaec8a1931 Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Fri, 24 Jan 2025 22:23:39 + Subject: [PATCH 01/17] [HLSL][RootSignature] Initial Lexer Definition with puncua

[clang] [HLSL][RootSignature] Implement Lexing of DescriptorTables (PR #122981)

2025-02-12 Thread Finn Plummer via cfe-commits
@@ -0,0 +1,166 @@ +#include "clang/Parse/ParseHLSLRootSignature.h" + +namespace clang { +namespace hlsl { + +// Lexer Definitions + +static bool IsNumberChar(char C) { + // TODO(#126565): extend for float support exponents + return isdigit(C); // integer support +} + +bool RootS

[clang] [HLSL][RootSignature] Implement Lexing of DescriptorTables (PR #122981)

2025-02-14 Thread Finn Plummer via cfe-commits
https://github.com/inbelic closed https://github.com/llvm/llvm-project/pull/122981 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Implement parsing of a DescriptorTable with empty clauses (PR #133302)

2025-03-31 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/133302 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Implement parsing of a DescriptorTable with empty clauses (PR #133302)

2025-03-31 Thread Finn Plummer via cfe-commits
https://github.com/inbelic closed https://github.com/llvm/llvm-project/pull/133302 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Revert "[HLSL][RootSignature] Define and integrate `HLSLRootSignatureAttr`" (PR #134273)

2025-04-03 Thread Finn Plummer via cfe-commits
https://github.com/inbelic closed https://github.com/llvm/llvm-project/pull/134273 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL][RootSignature] Define and integrate `HLSLRootSignatureAttr` (PR #134124)

2025-04-03 Thread Finn Plummer via cfe-commits
https://github.com/inbelic closed https://github.com/llvm/llvm-project/pull/134124 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Add infastructure to parse parameters (PR #133800)

2025-04-03 Thread Finn Plummer via cfe-commits
@@ -32,11 +39,19 @@ struct DescriptorTable { using ClauseType = llvm::dxil::ResourceClass; struct DescriptorTableClause { ClauseType Type; + Register Register; + uint32_t Space = 0; }; // Models RootElement : DescriptorTable | DescriptorTableClause using RootElement =

[clang] Reland "[HLSL][RootSignature] Define and integrate HLSLRootSignatureAttr" (PR #134293)

2025-04-03 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/134293 >From b5a61c786eac10b77c15a16b7425d158396a234b Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Wed, 2 Apr 2025 17:04:57 + Subject: [PATCH 1/2] [HLSL][RootSignature] Define and integrate `HLSLRootSignature

[clang] [llvm] [HLSL] Implement dot2add intrinsic (PR #131237)

2025-04-03 Thread Finn Plummer via cfe-commits
https://github.com/inbelic approved this pull request. LGTM once formatting is resolved https://github.com/llvm/llvm-project/pull/131237 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][HLSL][RootSignature] Make the Lexer adhere to naming conventions (PR #134136)

2025-04-04 Thread Finn Plummer via cfe-commits
https://github.com/inbelic closed https://github.com/llvm/llvm-project/pull/134136 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Add parsing for empty RootConstants (PR #137999)

2025-05-07 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/137999 >From d6e88d0ced28861ed0181b2d4aa2269582f768d9 Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Wed, 30 Apr 2025 17:17:32 + Subject: [PATCH 1/4] pre-req: add missing lexing keywords --- clang/include/clan

[clang] [llvm] [HLSL][RootSignature] Add parsing for RootFlags (PR #138055)

2025-05-09 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/138055 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-05-12 Thread Finn Plummer via cfe-commits
inbelic wrote: Unused variables build failures were addressed [here ](https://github.com/llvm/llvm-project/pull/139590)and [here](https://github.com/llvm/llvm-project/commit/e74877bafebeff40f7213c199c8125bb49818fc1). https://github.com/llvm/llvm-project/pull/137690

[clang] [llvm] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-05-12 Thread Finn Plummer via cfe-commits
https://github.com/inbelic closed https://github.com/llvm/llvm-project/pull/137690 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][HLSL][RootSignature] Patch to remove unused variable (PR #139590)

2025-05-12 Thread Finn Plummer via cfe-commits
https://github.com/inbelic closed https://github.com/llvm/llvm-project/pull/139590 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][HLSL][RootSignature] Patch to remove unused variable (PR #139590)

2025-05-12 Thread Finn Plummer via cfe-commits
inbelic wrote: https://github.com/llvm/llvm-project/commit/e74877bafebeff40f7213c199c8125bb49818fc1 beat me to it https://github.com/llvm/llvm-project/pull/139590 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/m

[clang] [llvm] [HLSL][RootSignature] Add parsing for empty RootConstants (PR #137999)

2025-05-08 Thread Finn Plummer via cfe-commits
https://github.com/inbelic closed https://github.com/llvm/llvm-project/pull/137999 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL][NFC] Stricter Overload Tests (clamp, max, min, pow) (PR #138993)

2025-05-08 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/138993 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL][NFC] Rename isImplicit() to hasRegisterStot() on HLSLResourceBindingAttr (PR #138964)

2025-05-07 Thread Finn Plummer via cfe-commits
https://github.com/inbelic approved this pull request. https://github.com/llvm/llvm-project/pull/138964 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [HLSL][NFC] Stricter Overload Tests (clamp, max, min, pow) (PR #138993)

2025-05-08 Thread Finn Plummer via cfe-commits
https://github.com/inbelic approved this pull request. https://github.com/llvm/llvm-project/pull/138993 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-05-09 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/137690 >From 87680ba4a99d35dbcc9416ab6b0710bd2f88d7bd Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Mon, 28 Apr 2025 18:42:10 + Subject: [PATCH 01/16] [HLSL][RootSignature] Define and integrate rootsig clang a

[clang] [llvm] [HLSL][RootSignature] Add parsing for RootFlags (PR #138055)

2025-05-09 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/138055 >From e1b21cc4d33dab2e100346443c998a678afc3dab Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Wed, 30 Apr 2025 23:14:07 + Subject: [PATCH 1/6] pre-req: define missing lexer tokens for flags --- .../clan

[clang] [llvm] [HLSL][RootSignature] Add optional parameters for RootConstants (PR #138007)

2025-05-09 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/138007 Rate limit · GitHub body { background-color: #f6f8fa; color: #24292e; font-family: -apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,Arial,sans-s

[clang] [llvm] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-05-09 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/137690 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Add optional parameters for RootConstants (PR #138007)

2025-05-09 Thread Finn Plummer via cfe-commits
https://github.com/inbelic closed https://github.com/llvm/llvm-project/pull/138007 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Define and integrate rootsig clang attr and decl (PR #137690)

2025-05-09 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/137690 Rate limit · GitHub body { background-color: #f6f8fa; color: #24292e; font-family: -apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,Arial,sans-s

[clang] [llvm] [HLSL][RootSignature] Add mandatory parameters for RootConstants (PR #138002)

2025-05-09 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/138002 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Add mandatory parameters for RootConstants (PR #138002)

2025-05-09 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/138002 >From 61931241a2d66161b00ea5478d02f7fe3842ae8c Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Wed, 30 Apr 2025 17:53:11 + Subject: [PATCH 1/4] [HLSL][RootSignature] Add mandatory parameters for RootConst

[clang] [llvm] [HLSL][RootSignature] Add mandatory parameters for RootConstants (PR #138002)

2025-05-09 Thread Finn Plummer via cfe-commits
https://github.com/inbelic closed https://github.com/llvm/llvm-project/pull/138002 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Add optional parameters for RootConstants (PR #138007)

2025-05-09 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/138007 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][HLSL][RootSignature] Patch to remove unused variable (PR #139590)

2025-05-12 Thread Finn Plummer via cfe-commits
https://github.com/inbelic created https://github.com/llvm/llvm-project/pull/139590 - SignatureDecl is currently unused as validation is not yet implemented - this patch cleans-up the unused variable from when it was used during implementation Rate limit · GitHub

[clang] [llvm] [DirectX][SPIRV] Fix the lowering of dot4add (PR #140315)

2025-05-16 Thread Finn Plummer via cfe-commits
https://github.com/inbelic approved this pull request. https://github.com/llvm/llvm-project/pull/140315 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [DirectX][SPIRV] Fix the lowering of dot4add (PR #140315)

2025-05-16 Thread Finn Plummer via cfe-commits
@@ -1,17 +1,19 @@ -// RUN: %clang_cc1 -finclude-default-header -triple \ -// RUN: dxil-pc-shadermodel6.3-compute %s -emit-llvm -disable-llvm-passes -o - | \ -// RUN: FileCheck %s -DTARGET=dx -// RUN: %clang_cc1 -finclude-default-header -triple \ -// RUN: spirv-pc-vulkan-com

[clang] [llvm] [HLSL][RootSignature] Add metadata generation for descriptor tables (PR #139633)

2025-05-15 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/139633 >From 135e6c98f964daff5313c335fc38c5e857994366 Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Mon, 12 May 2025 21:43:57 + Subject: [PATCH 01/13] pre-req: update attr to store reference to root signature

[clang] [llvm] [HLSL][RootSignature] Add metadata generation for descriptor tables (PR #139633)

2025-05-15 Thread Finn Plummer via cfe-commits
@@ -160,6 +163,75 @@ void dumpRootElements(raw_ostream &OS, ArrayRef Elements) { OS << "}"; } +static MDString *ClauseTypeToName(LLVMContext &Ctx, ClauseType Type) { + StringRef Name; + switch (Type) { + case ClauseType::CBuffer: +Name = "CBV"; +break; + case Cl

[clang] [llvm] [HLSL][RootSignature] Add metadata generation for descriptor tables (PR #139633)

2025-05-15 Thread Finn Plummer via cfe-commits
@@ -160,6 +163,75 @@ void dumpRootElements(raw_ostream &OS, ArrayRef Elements) { OS << "}"; } +static MDString *ClauseTypeToName(LLVMContext &Ctx, ClauseType Type) { + StringRef Name; + switch (Type) { + case ClauseType::CBuffer: +Name = "CBV"; +break; + case Cl

[clang] [llvm] [HLSL][RootSignature] Add metadata generation for descriptor tables (PR #139633)

2025-05-15 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/139633 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Add metadata generation for descriptor tables (PR #139633)

2025-05-15 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/139633 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Add metadata generation for descriptor tables (PR #139633)

2025-05-15 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/139633 >From 135e6c98f964daff5313c335fc38c5e857994366 Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Mon, 12 May 2025 21:43:57 + Subject: [PATCH 01/14] pre-req: update attr to store reference to root signature

[clang] [HLSL][NFC] Simplify resource constructors codegen tests (PR #139842)

2025-05-14 Thread Finn Plummer via cfe-commits
https://github.com/inbelic approved this pull request. https://github.com/llvm/llvm-project/pull/139842 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Add parsing infastructure for StaticSampler (PR #140180)

2025-05-26 Thread Finn Plummer via cfe-commits
https://github.com/inbelic closed https://github.com/llvm/llvm-project/pull/140180 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Add parsing infastructure for StaticSampler (PR #140180)

2025-05-26 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/140180 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Add parsing infastructure for StaticSampler (PR #140180)

2025-05-26 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/140180 >From 05cd843e21cd8d93a94914d13843871886146dab Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Thu, 15 May 2025 22:35:30 + Subject: [PATCH] [HLSL][RootSignature] Add parsing infastructure for StaticSample

[clang] [llvm] [HLSL][RootSignature] Add parsing infastructure for StaticSampler (PR #140180)

2025-05-26 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/140180 >From 05cd843e21cd8d93a94914d13843871886146dab Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Thu, 15 May 2025 22:35:30 + Subject: [PATCH 1/2] [HLSL][RootSignature] Add parsing infastructure for StaticSa

[clang] [llvm] [HLSL][RootSignature] Add parsing infastructure for StaticSampler (PR #140180)

2025-05-26 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/140180 >From 05cd843e21cd8d93a94914d13843871886146dab Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Thu, 15 May 2025 22:35:30 + Subject: [PATCH 1/3] [HLSL][RootSignature] Add parsing infastructure for StaticSa

[clang] [HLSL] Add Buffer def to frontend (PR #141086)

2025-05-27 Thread Finn Plummer via cfe-commits
https://github.com/inbelic approved this pull request. LGTM given we have a way of tracking making sure it will be read-only https://github.com/llvm/llvm-project/pull/141086 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org

[clang] [llvm] [HLSL][RootSignature] Add parsing of floats for StaticSampler (PR #140181)

2025-05-28 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/140181 >From 1c40e031725f1bd21c5c0d24d333781f99bd2a0a Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Thu, 15 May 2025 23:14:10 + Subject: [PATCH 01/18] pre-req: add missing token to Lexer --- clang/include/cla

[clang] [llvm] [HLSL][RootSignature] Add parsing of floats for StaticSampler (PR #140181)

2025-05-28 Thread Finn Plummer via cfe-commits
@@ -821,22 +873,115 @@ std::optional RootSignatureParser::handleUIntLiteral() { PP.getSourceManager(), PP.getLangOpts(), PP.getTargetInfo(), PP.getDiagnostics()); if (Literal.hadError) -return tr

[clang] [llvm] [HLSL][RootSignature] Add metadata generation for descriptor tables (PR #139633)

2025-05-15 Thread Finn Plummer via cfe-commits
@@ -160,6 +163,75 @@ void dumpRootElements(raw_ostream &OS, ArrayRef Elements) { OS << "}"; } +static MDString *ClauseTypeToName(LLVMContext &Ctx, ClauseType Type) { + StringRef Name; + switch (Type) { + case ClauseType::CBuffer: +Name = "CBV"; +break; + case Cl

[clang] [llvm] [HLSL][RootSignature] Add metadata generation for descriptor tables (PR #139633)

2025-05-15 Thread Finn Plummer via cfe-commits
https://github.com/inbelic closed https://github.com/llvm/llvm-project/pull/139633 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Add parsing for empty RootParams (PR #140147)

2025-05-15 Thread Finn Plummer via cfe-commits
https://github.com/inbelic created https://github.com/llvm/llvm-project/pull/140147 - define the RootParam in-memory struct containing its type - add test harness for testing First part of https://github.com/llvm/llvm-project/issues/126577 >From fc2fc60145e65a1b32542cbaf9b4bd6ce3b1509d Mon Sep

[clang] [llvm] [HLSL][RootSignature] Add parsing for empty RootParams (PR #140147)

2025-05-21 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/140147 >From fc2fc60145e65a1b32542cbaf9b4bd6ce3b1509d Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Thu, 15 May 2025 17:48:07 + Subject: [PATCH 1/2] [HLSL][RootSignature] Add parsing for empty RootParams - def

[clang] [llvm] [HLSL][RootSignature] Add parsing for empty RootDescriptors (PR #140147)

2025-05-21 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/140147 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Add parsing for empty RootDescriptors (PR #140147)

2025-05-21 Thread Finn Plummer via cfe-commits
https://github.com/inbelic edited https://github.com/llvm/llvm-project/pull/140147 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [HLSL][RootSignature] Add parsing for empty RootParams (PR #140147)

2025-05-21 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/140147 >From fc2fc60145e65a1b32542cbaf9b4bd6ce3b1509d Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Thu, 15 May 2025 17:48:07 + Subject: [PATCH 1/2] [HLSL][RootSignature] Add parsing for empty RootParams - def

<    1   2   3   4   5   6   7   >