@@ -253,12 +257,229 @@ static void validatePackoffset(Sema &S, HLSLBufferDecl
*BufDecl) {
}
}
+// Returns true if the array has a zero size = if any of the dimensions is 0
+static bool isZeroSizedArray(const ConstantArrayType *CAT) {
+ while (CAT && !CAT->isZeroSize())
+
@@ -253,12 +257,229 @@ static void validatePackoffset(Sema &S, HLSLBufferDecl
*BufDecl) {
}
}
+// Returns true if the array has a zero size = if any of the dimensions is 0
+static bool isZeroSizedArray(const ConstantArrayType *CAT) {
+ while (CAT && !CAT->isZeroSize())
+
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/122820
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -253,12 +257,229 @@ static void validatePackoffset(Sema &S, HLSLBufferDecl
*BufDecl) {
}
}
+// Returns true if the array has a zero size = if any of the dimensions is 0
+static bool isZeroSizedArray(const ConstantArrayType *CAT) {
+ while (CAT && !CAT->isZeroSize())
+
https://github.com/hekota closed
https://github.com/llvm/llvm-project/pull/123411
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota ready_for_review
https://github.com/llvm/llvm-project/pull/123394
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/123394
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/123394
>From 1d04bfa8e1b138a13acf30c3fc46428d3b260569 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Fri, 17 Jan 2025 12:40:21 -0800
Subject: [PATCH 1/2] [HLSL] Fix global resource initialization
Fixes #120636
---
https://github.com/hekota created
https://github.com/llvm/llvm-project/pull/123394
Create separate resource initialization function for each resource and add them
to CodeGenModule's `CXXGlobalInits` list. fixes Fixes #120636 and addresses
this [comment
](https://github.com/llvm/llvm-project/p
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/123394
>From 1d04bfa8e1b138a13acf30c3fc46428d3b260569 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Fri, 17 Jan 2025 12:40:21 -0800
Subject: [PATCH 1/2] [HLSL] Fix global resource initialization
Fixes #120636
---
https://github.com/hekota created
https://github.com/llvm/llvm-project/pull/124840
- create structs with public fields instead of classes with private fields
- add Packed attribute to prevent struct padding
- use `__cblayout_` prefix in name
- filter out arrays of resources (bug fix)
- don't cre
@@ -27,6 +27,3 @@ cbuffer A {
// AST-NEXT: TextComment {{.*}} Text=" CBuffer decl."
// AST-NEXT: VarDecl {{.*}} a 'hlsl_constant float'
// AST-NEXT: VarDecl {{.*}} b 'hlsl_constant int'
-// AST-NEXT: CXXRecordDecl {{.*}} implicit class __layout_A definition
-// AST: FieldDecl {
https://github.com/hekota ready_for_review
https://github.com/llvm/llvm-project/pull/124840
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/124840
>From 63c465b40512ad4c5fff84c0b2b022b49d46eaa7 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Tue, 28 Jan 2025 13:20:30 -0800
Subject: [PATCH 1/2] [HLSL] Constant buffer layout struct update
- create structs
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/124840
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota created
https://github.com/llvm/llvm-project/pull/124866
None
>From 402e768521b33c7d1758d6aca2ff13741551cf4f Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Tue, 28 Jan 2025 17:16:02 -0800
Subject: [PATCH] [HLSL] Checks store instructions in resource binding test
-
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/124866
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota closed
https://github.com/llvm/llvm-project/pull/119755
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/124866
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/124866
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota ready_for_review
https://github.com/llvm/llvm-project/pull/124866
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/124866
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/123394
>From 1d04bfa8e1b138a13acf30c3fc46428d3b260569 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Fri, 17 Jan 2025 12:40:21 -0800
Subject: [PATCH 1/3] [HLSL] Fix global resource initialization
Fixes #120636
---
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/122820
>From 71ddb5a2b4cc8a9609410b436e896484401f5e90 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Mon, 13 Jan 2025 15:03:12 -0800
Subject: [PATCH] [HLSL] cbuffer: Create host layout struct and add resource
handle
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/122820
>From 71ddb5a2b4cc8a9609410b436e896484401f5e90 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Mon, 13 Jan 2025 15:03:12 -0800
Subject: [PATCH 1/2] [HLSL] cbuffer: Create host layout struct and add
resource ha
@@ -5362,6 +5362,23 @@ LangAS CodeGenModule::GetGlobalVarAddressSpace(const
VarDecl *D) {
if (OpenMPRuntime->hasAllocateAttributeForGlobalVar(D, AS))
return AS;
}
+
+ if (LangOpts.HLSL) {
+if (D == nullptr)
+ return LangAS::hlsl_private;
+
+// Except
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/122103
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/122820
>From 71ddb5a2b4cc8a9609410b436e896484401f5e90 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Mon, 13 Jan 2025 15:03:12 -0800
Subject: [PATCH 1/3] [HLSL] cbuffer: Create host layout struct and add
resource ha
https://github.com/hekota closed
https://github.com/llvm/llvm-project/pull/121989
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -253,12 +257,253 @@ static void validatePackoffset(Sema &S, HLSLBufferDecl
*BufDecl) {
}
}
+// Returns true if the array has a zero size = if any of the dimensions is 0
+static bool isZeroSizedArray(const ConstantArrayType *CAT) {
+ while (CAT && !CAT->isZeroSize())
+
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/122820
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -253,12 +257,253 @@ static void validatePackoffset(Sema &S, HLSLBufferDecl
*BufDecl) {
}
}
+// Returns true if the array has a zero size = if any of the dimensions is 0
+static bool isZeroSizedArray(const ConstantArrayType *CAT) {
+ while (CAT && !CAT->isZeroSize())
+
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/122820
>From 71ddb5a2b4cc8a9609410b436e896484401f5e90 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Mon, 13 Jan 2025 15:03:12 -0800
Subject: [PATCH 1/4] [HLSL] cbuffer: Create host layout struct and add
resource ha
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/122820
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/122820
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota approved this pull request.
https://github.com/llvm/llvm-project/pull/123141
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota approved this pull request.
LGTM!
https://github.com/llvm/llvm-project/pull/123141
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/124886
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/124886
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -59,8 +59,14 @@ llvm::Type *DirectXTargetCodeGenInfo::getHLSLType(
SmallVector Ints = {/*IsWriteable*/ ResAttrs.ResourceClass ==
llvm::dxil::ResourceClass::UAV,
/*IsROV*/ ResAttrs.IsROV};
-
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/131032
>From 7ebfc826ca27c71ef80f4a1b38b2d3a2e155b777 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Wed, 12 Mar 2025 14:09:24 -0700
Subject: [PATCH 1/4] [HLSL][NFC] Refactoring HLSLExternalSemaSource
Moving builder
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/131032
>From 7ebfc826ca27c71ef80f4a1b38b2d3a2e155b777 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Wed, 12 Mar 2025 14:09:24 -0700
Subject: [PATCH 1/6] [HLSL][NFC] Refactoring HLSLExternalSemaSource
Moving builder
@@ -0,0 +1,96 @@
+//===--- HLSLBuiltinTypeDeclBuilder.h - HLSL Builtin Type Decl Builder
---===//
+//
+// 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
@@ -453,11 +481,11 @@ BuiltinTypeMethodBuilder
&BuiltinTypeMethodBuilder::dereference(T Ptr) {
return *this;
}
-BuiltinTypeDeclBuilder &BuiltinTypeMethodBuilder::finalizeMethod() {
+BuiltinTypeDeclBuilder &BuiltinTypeMethodBuilder::finalize() {
assert(!DeclBuilder.Record
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/131384
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota closed
https://github.com/llvm/llvm-project/pull/131032
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/131384
>From 7ebfc826ca27c71ef80f4a1b38b2d3a2e155b777 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Wed, 12 Mar 2025 14:09:24 -0700
Subject: [PATCH 1/5] [HLSL][NFC] Refactoring HLSLExternalSemaSource
Moving builder
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/131384
>From 7ebfc826ca27c71ef80f4a1b38b2d3a2e155b777 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Wed, 12 Mar 2025 14:09:24 -0700
Subject: [PATCH 1/4] [HLSL][NFC] Refactoring HLSLExternalSemaSource
Moving builder
@@ -453,11 +481,11 @@ BuiltinTypeMethodBuilder
&BuiltinTypeMethodBuilder::dereference(T Ptr) {
return *this;
}
-BuiltinTypeDeclBuilder &BuiltinTypeMethodBuilder::finalizeMethod() {
+BuiltinTypeDeclBuilder &BuiltinTypeMethodBuilder::finalize() {
assert(!DeclBuilder.Record
https://github.com/hekota created
https://github.com/llvm/llvm-project/pull/132828
Fixes #132309
>From ac823de8971dc7cfd2516860badd24fe983968eb Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Mon, 24 Mar 2025 14:05:47 -0700
Subject: [PATCH] [HLSL] Fix codegen to support classes in `cbuffer`
https://github.com/hekota closed
https://github.com/llvm/llvm-project/pull/130342
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/130342
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota closed
https://github.com/llvm/llvm-project/pull/130338
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota closed
https://github.com/llvm/llvm-project/pull/130223
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
hekota wrote:
> LGTM for DXIL. Is there a plan to do this with SPIR-V too?
SPIR-V is generating different target type and it does not seem to have the
'signed' flag:
See
https://github.com/llvm/llvm-project/blob/fbf0276b6a7a7a4508c373cf87fc349569652659/clang/lib/CodeGen/Targets/SPIR.cpp#L396
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/131032
>From 7ebfc826ca27c71ef80f4a1b38b2d3a2e155b777 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Wed, 12 Mar 2025 14:09:24 -0700
Subject: [PATCH 1/5] [HLSL][NFC] Refactoring HLSLExternalSemaSource
Moving builder
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/131384
>From 7ebfc826ca27c71ef80f4a1b38b2d3a2e155b777 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Wed, 12 Mar 2025 14:09:24 -0700
Subject: [PATCH 1/6] [HLSL][NFC] Refactoring HLSLExternalSemaSource
Moving builder
https://github.com/hekota created
https://github.com/llvm/llvm-project/pull/135120
- Adds resource constructor that takes explicit binding for all resource
classes.
- Updates implementation of default resource constructor to initialize resource
handle to `poison`.
- Removes initialization of r
https://github.com/hekota ready_for_review
https://github.com/llvm/llvm-project/pull/135120
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
Nathan =?utf-8?q?Gau=C3=ABr?= ,
Nathan =?utf-8?q?Gau=C3=ABr?= ,
Nathan =?utf-8?q?Gau=C3=ABr?= ,
Nathan =?utf-8?q?Gau=C3=ABr?= ,
Nathan =?utf-8?q?Gau=C3=ABr?=
Message-ID:
In-Reply-To:
https://github.com/hekota approved this pull request.
LGTM! Thanks!
https://github.com/llvm/llvm-project/pull/
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/135120
>From 85001dcbc184491dfb24e9d2a39df46fd4c9a363 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Wed, 9 Apr 2025 18:17:26 -0700
Subject: [PATCH 1/3] Initialize resources by constructors
- add resource record con
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/135120
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/135120
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/135120
>From 85001dcbc184491dfb24e9d2a39df46fd4c9a363 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Wed, 9 Apr 2025 18:17:26 -0700
Subject: [PATCH 1/2] Initialize resources by constructors
- add resource record con
https://github.com/hekota approved this pull request.
LGTM! One suggestion to use `getUnqualifiedDesugaredType` instead of
`getDesugaredType` that requires a context.
https://github.com/llvm/llvm-project/pull/134683
___
cfe-commits mailing list
cfe-co
https://github.com/hekota closed
https://github.com/llvm/llvm-project/pull/131384
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/130338
>From 99539251dcf58aab9a88973f9162156ae6f1aa77 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Thu, 6 Mar 2025 18:22:07 -0800
Subject: [PATCH 1/4] [HLSL][NFC] Update resource metadata tests to not use
obsolete
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/135120
>From 85001dcbc184491dfb24e9d2a39df46fd4c9a363 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Wed, 9 Apr 2025 18:17:26 -0700
Subject: [PATCH 1/4] Initialize resources by constructors
- add resource record con
@@ -287,6 +287,24 @@ Value *CodeGenFunction::EmitHLSLBuiltinExpr(unsigned
BuiltinID,
RetTy, CGM.getHLSLRuntime().getCreateResourceGetPointerIntrinsic(),
ArrayRef{HandleOp, IndexOp});
}
+ case Builtin::BI__builtin_hlsl_resource_createpoisonhandle: {
+llvm
@@ -1,34 +1,117 @@
// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.3-library -x hlsl -emit-llvm
-disable-llvm-passes -o - %s | FileCheck %s --check-prefixes=CHECK,CHECK-DXIL
+// FIXME: SPIR-V codegen of llvm.spv.resource.handlefrombinding and resource
types is not yet implement
https://github.com/hekota updated
https://github.com/llvm/llvm-project/pull/135120
>From 85001dcbc184491dfb24e9d2a39df46fd4c9a363 Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Wed, 9 Apr 2025 18:17:26 -0700
Subject: [PATCH 1/5] Initialize resources by constructors
- add resource record con
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/134683
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -195,7 +195,8 @@ bool HLSLBufferLayoutBuilder::layoutField(const FieldDecl
*FD,
// Unwrap array to find the element type and get combined array size.
QualType Ty = FieldTy;
while (Ty->isConstantArrayType()) {
- const ConstantArrayType *ArrayTy = cast(Ty);
+
https://github.com/hekota closed
https://github.com/llvm/llvm-project/pull/135287
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota closed
https://github.com/llvm/llvm-project/pull/135120
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/135287
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -751,13 +751,14 @@
BuiltinTypeDeclBuilder::addHandleAccessFunction(DeclarationName &Name,
using PH = BuiltinTypeMethodBuilder::PlaceHolder;
QualType ElemTy = getHandleElementType();
- // TODO: Map to an hlsl_device address space.
- QualType ElemPtrTy = AST.getPointer
@@ -2379,8 +2379,10 @@ bool SemaHLSL::CheckBuiltinFunctionCall(unsigned
BuiltinID, CallExpr *TheCall) {
auto *ResourceTy =
TheCall->getArg(0)->getType()->castAs();
QualType ContainedTy = ResourceTy->getContainedType();
-// TODO: Map to an hlsl_device addres
@@ -89,12 +89,12 @@ RESOURCE Buffer;
// CHECK-SAME{LITERAL}: [[hlsl::raw_buffer]]
// CHECK-SAME{LITERAL}: [[hlsl::contained_type(element_type)]]
-// CHECK-SUBSCRIPT: CXXMethodDecl {{.*}} operator[] 'const element_type
&(unsigned int) const'
+// CHECK-SUBSCRIPT: CXXMethodDecl
@@ -751,13 +751,14 @@
BuiltinTypeDeclBuilder::addHandleAccessFunction(DeclarationName &Name,
using PH = BuiltinTypeMethodBuilder::PlaceHolder;
QualType ElemTy = getHandleElementType();
- // TODO: Map to an hlsl_device address space.
- QualType ElemPtrTy = AST.getPointer
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/127675
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota requested changes to this pull request.
Looks mostly good, but I think there is an issue with the const-ness of the
subscript operator return value.
https://github.com/llvm/llvm-project/pull/127675
___
cfe-commits mailing lis
https://github.com/hekota approved this pull request.
LGTM! One small nit.
https://github.com/llvm/llvm-project/pull/137391
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,13 @@
+// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.3-library -ast-dump %s |
FileCheck %s
hekota wrote:
This test should probably be in `clang/test/AST/HLSL`.
https://github.com/llvm/llvm-project/pull/137391
___
https://github.com/hekota approved this pull request.
LGTM! Just a couple of nits. Apologies for the delay, I was on vacation last
week. :)
https://github.com/llvm/llvm-project/pull/127675
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https:
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/127675
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -121,15 +121,15 @@ RESOURCE Buffer;
// CHECK-SUBSCRIPT-NEXT: DeclRefExpr {{.*}} 'unsigned int' ParmVar {{.*}}
'Index' 'unsigned int'
// CHECK-SUBSCRIPT-NEXT: AlwaysInlineAttr {{.*}} Implicit always_inline
-// CHECK-NOSUBSCRIPT-NOT: CXXMethodDecl {{.*}} operator[] 'const el
@@ -89,12 +89,12 @@ RESOURCE Buffer;
// CHECK-SAME{LITERAL}: [[hlsl::raw_buffer]]
// CHECK-SAME{LITERAL}: [[hlsl::contained_type(element_type)]]
-// CHECK-SUBSCRIPT: CXXMethodDecl {{.*}} operator[] 'const element_type
&(unsigned int) const'
+// CHECK-SUBSCRIPT: CXXMethodDecl
@@ -115,48 +83,176 @@ llvm::Triple::ArchType CGHLSLRuntime::getArch() {
return CGM.getTarget().getTriple().getArch();
}
-void CGHLSLRuntime::addConstant(VarDecl *D, Buffer &CB) {
- if (D->getStorageClass() == SC_Static) {
-// For static inside cbuffer, take as global st
@@ -115,48 +83,176 @@ llvm::Triple::ArchType CGHLSLRuntime::getArch() {
return CGM.getTarget().getTriple().getArch();
}
-void CGHLSLRuntime::addConstant(VarDecl *D, Buffer &CB) {
- if (D->getStorageClass() == SC_Static) {
-// For static inside cbuffer, take as global st
@@ -115,48 +83,176 @@ llvm::Triple::ArchType CGHLSLRuntime::getArch() {
return CGM.getTarget().getTriple().getArch();
}
-void CGHLSLRuntime::addConstant(VarDecl *D, Buffer &CB) {
- if (D->getStorageClass() == SC_Static) {
-// For static inside cbuffer, take as global st
@@ -56,9 +75,18 @@ llvm::Type
*DirectXTargetCodeGenInfo::getHLSLType(CodeGenModule &CGM,
return llvm::TargetExtType::get(Ctx, TypeName, {ElemType}, Ints);
}
- case llvm::dxil::ResourceClass::CBuffer:
-llvm_unreachable("dx.CBuffer handles are not implemented yet");
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/124886
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota closed
https://github.com/llvm/llvm-project/pull/128981
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/128981
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/128991
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/130222
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota created
https://github.com/llvm/llvm-project/pull/130223
Fixes #130191
>From e3f4108f1a0677569bf6bd8ae73569e0dae8d78a Mon Sep 17 00:00:00 2001
From: Helena Kotas
Date: Thu, 6 Mar 2025 18:41:12 -0800
Subject: [PATCH] [HLSL] Make sure to set isSigned flag on TypedBuffer
https://github.com/hekota edited
https://github.com/llvm/llvm-project/pull/130222
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/hekota created
https://github.com/llvm/llvm-project/pull/130222
Update resource metadata tests to generate metadata based on
`llvm.dx.resource.handlefrombinding` data collected in
`DXILResourceBindingAnalysis`.
- `UAVMetadata.ll` is renamed to `uav_metadata.ll`, updated and
701 - 800 of 892 matches
Mail list logo