@@ -194,17 +196,19 @@ static unsigned calculateLegacyCbufferSize(const
ASTContext &Context,
calculateLegacyCbufferSize(Context, VT->getElementType());
Size = ElementSize * ElementCount;
} else {
-Size = Context.getTypeSize(T);
+Size = Context.getTypeSize(
https://github.com/bob80905 approved this pull request.
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
@@ -393,7 +396,7 @@ static FieldDecl *createFieldForHostLayoutStruct(Sema &S,
const Type *Ty,
auto *Field = FieldDecl::Create(AST, LayoutStruct, SourceLocation(),
SourceLocation(), II, QT, TSI, nullptr,
false,
@@ -472,14 +477,16 @@ void createHostLayoutStructForBuffer(Sema &S,
HLSLBufferDecl *BufDecl) {
IdentifierInfo *II = getHostLayoutStructName(S, BufDecl, true);
CXXRecordDecl *LS =
- CXXRecordDecl::Create(AST, TagDecl::TagKind::Class, BufDecl,
+ CXXRecordDecl::Cre
@@ -48,94 +48,108 @@ struct TwoFloats {
// CHECK: HLSLResourceClassAttr {{.*}} Implicit CBuffer
// CHECK: HLSLResourceAttr {{.*}} Implicit CBuffer
cbuffer CB {
- // CHECK: VarDecl {{.*}} col:9 used a1 'hlsl_constant float'
+ // CHECK: VarDecl {{.*}} used a1 'hlsl_constant flo
@@ -48,94 +48,108 @@ struct TwoFloats {
// CHECK: HLSLResourceClassAttr {{.*}} Implicit CBuffer
// CHECK: HLSLResourceAttr {{.*}} Implicit CBuffer
cbuffer CB {
- // CHECK: VarDecl {{.*}} col:9 used a1 'hlsl_constant float'
+ // CHECK: VarDecl {{.*}} used a1 'hlsl_constant flo
@@ -48,94 +48,108 @@ struct TwoFloats {
// CHECK: HLSLResourceClassAttr {{.*}} Implicit CBuffer
// CHECK: HLSLResourceAttr {{.*}} Implicit CBuffer
cbuffer CB {
- // CHECK: VarDecl {{.*}} col:9 used a1 'hlsl_constant float'
+ // CHECK: VarDecl {{.*}} used a1 'hlsl_constant flo
@@ -48,94 +48,108 @@ struct TwoFloats {
// CHECK: HLSLResourceClassAttr {{.*}} Implicit CBuffer
// CHECK: HLSLResourceAttr {{.*}} Implicit CBuffer
cbuffer CB {
- // CHECK: VarDecl {{.*}} col:9 used a1 'hlsl_constant float'
+ // CHECK: VarDecl {{.*}} used a1 'hlsl_constant flo
@@ -14183,6 +14183,7 @@ void Sema::ActOnUninitializedDecl(Decl *RealDecl) {
if (getLangOpts().OpenCL &&
Var->getType().getAddressSpace() == LangAS::opencl_local)
return;
+
bob80905 wrote:
nit: unneeded new line
https://github.com/llvm/llvm-p
https://github.com/bob80905 approved this pull request.
https://github.com/llvm/llvm-project/pull/125904
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/bob80905 approved this pull request.
https://github.com/llvm/llvm-project/pull/125992
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/bob80905 approved this pull request.
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
@@ -5720,8 +5720,7 @@ static bool EvaluateUnaryTypeTrait(Sema &Self, TypeTrait
UTT,
case UTT_IsTypedResourceElementCompatible:
assert(Self.getLangOpts().HLSL &&
"typed resource element compatible types are an HLSL-only feature");
-if (Self.RequireCompleteT
https://github.com/bob80905 closed
https://github.com/llvm/llvm-project/pull/115971
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/bob80905 updated
https://github.com/llvm/llvm-project/pull/119444
>From 3a09b73239a4b14b8704d71ad5683abdf5ff8b08 Mon Sep 17 00:00:00 2001
From: Joshua Batista
Date: Tue, 10 Dec 2024 11:45:56 -0800
Subject: [PATCH 1/2] cleanup comments NFC
---
clang/lib/Sema/HLSLExternalSema
https://github.com/bob80905 created
https://github.com/llvm/llvm-project/pull/119444
Cleaning up some comments that @bogner pointed out were unpolished.
>From 3a09b73239a4b14b8704d71ad5683abdf5ff8b08 Mon Sep 17 00:00:00 2001
From: Joshua Batista
Date: Tue, 10 Dec 2024 11:45:56 -0800
Subject: [
https://github.com/bob80905 created
https://github.com/llvm/llvm-project/pull/119643
This PR adds concept validation to raw buffers like Structured buffers, in the
same way that it was done for typed buffers in
https://github.com/llvm/llvm-project/pull/116413.
This PR should also be responsib
https://github.com/bob80905 closed
https://github.com/llvm/llvm-project/pull/119444
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/bob80905 edited
https://github.com/llvm/llvm-project/pull/119643
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/bob80905 edited
https://github.com/llvm/llvm-project/pull/119643
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/bob80905 approved this pull request.
https://github.com/llvm/llvm-project/pull/120466
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/bob80905 updated
https://github.com/llvm/llvm-project/pull/119643
>From cbcdcd37ec82e7bbb5fdd1cf83b093778d4fcf9f Mon Sep 17 00:00:00 2001
From: Joshua Batista
Date: Wed, 11 Dec 2024 17:02:02 -0800
Subject: [PATCH 1/2] add concepts for raw buffers
---
clang/lib/Sema/HLSLExte
https://github.com/bob80905 updated
https://github.com/llvm/llvm-project/pull/119643
>From cbcdcd37ec82e7bbb5fdd1cf83b093778d4fcf9f Mon Sep 17 00:00:00 2001
From: Joshua Batista
Date: Wed, 11 Dec 2024 17:02:02 -0800
Subject: [PATCH 1/4] add concepts for raw buffers
---
clang/lib/Sema/HLSLExte
https://github.com/bob80905 updated
https://github.com/llvm/llvm-project/pull/119643
>From cbcdcd37ec82e7bbb5fdd1cf83b093778d4fcf9f Mon Sep 17 00:00:00 2001
From: Joshua Batista
Date: Wed, 11 Dec 2024 17:02:02 -0800
Subject: [PATCH 1/3] add concepts for raw buffers
---
clang/lib/Sema/HLSLExte
https://github.com/bob80905 edited
https://github.com/llvm/llvm-project/pull/119643
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/bob80905 updated
https://github.com/llvm/llvm-project/pull/119643
>From cbcdcd37ec82e7bbb5fdd1cf83b093778d4fcf9f Mon Sep 17 00:00:00 2001
From: Joshua Batista
Date: Wed, 11 Dec 2024 17:02:02 -0800
Subject: [PATCH 1/5] add concepts for raw buffers
---
clang/lib/Sema/HLSLExte
https://github.com/bob80905 updated
https://github.com/llvm/llvm-project/pull/119643
>From cbcdcd37ec82e7bbb5fdd1cf83b093778d4fcf9f Mon Sep 17 00:00:00 2001
From: Joshua Batista
Date: Wed, 11 Dec 2024 17:02:02 -0800
Subject: [PATCH 1/7] add concepts for raw buffers
---
clang/lib/Sema/HLSLExte
@@ -0,0 +1,15 @@
+// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.0-library -x hlsl -ast-dump
-ast-dump-filter=__is_structured_resource_element_compatible %s | FileCheck %s
+
+// CHECK: ConceptDecl 0x{{[0-9a-f]+}} <>
__is_structured_resource_element_compatible
+// CHECK: |-Temp
https://github.com/bob80905 edited
https://github.com/llvm/llvm-project/pull/119643
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/bob80905 closed
https://github.com/llvm/llvm-project/pull/119643
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/bob80905 closed
https://github.com/llvm/llvm-project/pull/116413
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,25 @@
+// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.0-library -x hlsl -ast-dump
-DEMPTY %s | FileCheck -check-prefix=EMPTY %s
+// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.0-library -x hlsl -ast-dump %s
| FileCheck %s
+
+
+// EMPTY: CXXRecordDecl 0x{{[0-9A-Fa-f]
https://github.com/bob80905 updated
https://github.com/llvm/llvm-project/pull/115971
>From 7413ceb21a6e0ac9212ef6317763ee0eff559612 Mon Sep 17 00:00:00 2001
From: Joshua Batista
Date: Tue, 12 Nov 2024 16:44:00 -0800
Subject: [PATCH 1/7] print struct body within target ext ty context
---
.../t
https://github.com/bob80905 edited
https://github.com/llvm/llvm-project/pull/115971
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/bob80905 edited
https://github.com/llvm/llvm-project/pull/115971
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/bob80905 updated
https://github.com/llvm/llvm-project/pull/115971
>From 7413ceb21a6e0ac9212ef6317763ee0eff559612 Mon Sep 17 00:00:00 2001
From: Joshua Batista
Date: Tue, 12 Nov 2024 16:44:00 -0800
Subject: [PATCH 1/5] print struct body within target ext ty context
---
.../t
https://github.com/bob80905 updated
https://github.com/llvm/llvm-project/pull/115971
>From 7413ceb21a6e0ac9212ef6317763ee0eff559612 Mon Sep 17 00:00:00 2001
From: Joshua Batista
Date: Tue, 12 Nov 2024 16:44:00 -0800
Subject: [PATCH 1/4] print struct body within target ext ty context
---
.../t
https://github.com/bob80905 updated
https://github.com/llvm/llvm-project/pull/115971
>From 7413ceb21a6e0ac9212ef6317763ee0eff559612 Mon Sep 17 00:00:00 2001
From: Joshua Batista
Date: Tue, 12 Nov 2024 16:44:00 -0800
Subject: [PATCH 1/6] print struct body within target ext ty context
---
.../t
https://github.com/bob80905 updated
https://github.com/llvm/llvm-project/pull/116413
>From 92ccbe72ca95ad2df5a81b76244a8a8d7cedef40 Mon Sep 17 00:00:00 2001
From: Joshua Batista
Date: Fri, 15 Nov 2024 09:00:15 -0800
Subject: [PATCH 1/7] update new tests
---
clang/lib/Sema/HLSLExternalSemaSour
https://github.com/bob80905 updated
https://github.com/llvm/llvm-project/pull/115971
>From 7413ceb21a6e0ac9212ef6317763ee0eff559612 Mon Sep 17 00:00:00 2001
From: Joshua Batista
Date: Tue, 12 Nov 2024 16:44:00 -0800
Subject: [PATCH 1/8] print struct body within target ext ty context
---
.../t
@@ -871,6 +871,34 @@ float3 degrees(float3);
_HLSL_BUILTIN_ALIAS(__builtin_hlsl_elementwise_degrees)
float4 degrees(float4);
+//===--===//
+// distance builtins
+//===--
@@ -871,6 +871,34 @@ float3 degrees(float3);
_HLSL_BUILTIN_ALIAS(__builtin_hlsl_elementwise_degrees)
float4 degrees(float4);
+//===--===//
+// distance builtins
+//===--
https://github.com/bob80905 approved this pull request.
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/bob80905 approved this pull request.
https://github.com/llvm/llvm-project/pull/122357
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/bob80905 approved this pull request.
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
@@ -2229,6 +2241,41 @@ static bool CheckResourceHandle(
// returning an ExprError
bool SemaHLSL::CheckBuiltinFunctionCall(unsigned BuiltinID, CallExpr *TheCall)
{
switch (BuiltinID) {
+ case Builtin::BI__builtin_hlsl_adduint64: {
+if (SemaRef.checkArgCount(TheCall, 2))
https://github.com/bob80905 approved this pull request.
https://github.com/llvm/llvm-project/pull/127262
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,375 @@
+//=== ParseHLSLRootSignatureTest.cpp - Parse Root Signature tests
-===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
bob80905 wrote
https://github.com/bob80905 approved this pull request.
https://github.com/llvm/llvm-project/pull/127346
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1,41 +1,56 @@
-// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.3-library -x hlsl -ast-dump -o
- %s | FileCheck %s
+// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.3-library
-finclude-default-header -ast-dump -o - %s | FileCheck %s
-// CHECK:HLSLBufferDecl 0x[[CB:[0-9a-f]+]
@@ -1,41 +1,56 @@
-// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.3-library -x hlsl -ast-dump -o
- %s | FileCheck %s
+// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.3-library
-finclude-default-header -ast-dump -o - %s | FileCheck %s
-// CHECK:HLSLBufferDecl 0x[[CB:[0-9a-f]+]
@@ -1,41 +1,56 @@
-// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.3-library -x hlsl -ast-dump -o
- %s | FileCheck %s
+// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.3-library
-finclude-default-header -ast-dump -o - %s | FileCheck %s
bob80905 wrote:
Can you ex
@@ -1,41 +1,56 @@
-// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.3-library -x hlsl -ast-dump -o
- %s | FileCheck %s
+// RUN: %clang_cc1 -triple dxil-pc-shadermodel6.3-library
-finclude-default-header -ast-dump -o - %s | FileCheck %s
-// CHECK:HLSLBufferDecl 0x[[CB:[0-9a-f]+]
@@ -131,3 +157,9 @@ double3 test_min_double3(double3 p0, double3 p1) { return
min(p0, p1); }
// CHECK-LABEL: define noundef nofpclass(nan inf) <4 x double>
@_Z16test_min_double4
// CHECK: call reassoc nnan ninf nsz arcp afn <4 x double> @llvm.minnum.v4f64
double4 test_min_dou
https://github.com/bob80905 approved this pull request.
I can approve this, though it might be worth considering adding a macro at the
top of hlsl_intrinsics.h, along with some of the other macros there, to shrink
the change and possibly simplify future changes that need these types of sets
of
https://github.com/bob80905 approved this pull request.
https://github.com/llvm/llvm-project/pull/129334
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1678,6 +1678,30 @@ half3 max(half3, half3);
_HLSL_16BIT_AVAILABILITY(shadermodel, 6.2)
_HLSL_BUILTIN_ALIAS(__builtin_elementwise_max)
half4 max(half4, half4);
+_HLSL_16BIT_AVAILABILITY(shadermodel, 6.2)
+constexpr half2 max(half2 p0, half p1) {
bob80905 wro
https://github.com/bob80905 approved this pull request.
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
@@ -35,25 +35,48 @@ namespace hlsl {
#define _HLSL_16BIT_AVAILABILITY_STAGE(environment, version, stage)
#endif
-#define GEN_VEC_SCALAR_OVERLOADS(FUNC_NAME, BASE_TYPE, AVAIL)
\
- GEN_BOTH_OVERLOADS(FUNC_NAME, BASE_TYPE, BASE_TYPE##2, AVAIL)
\
https://github.com/bob80905 edited
https://github.com/llvm/llvm-project/pull/129939
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -35,25 +35,48 @@ namespace hlsl {
#define _HLSL_16BIT_AVAILABILITY_STAGE(environment, version, stage)
#endif
-#define GEN_VEC_SCALAR_OVERLOADS(FUNC_NAME, BASE_TYPE, AVAIL)
\
- GEN_BOTH_OVERLOADS(FUNC_NAME, BASE_TYPE, BASE_TYPE##2, AVAIL)
\
@@ -35,25 +35,48 @@ namespace hlsl {
#define _HLSL_16BIT_AVAILABILITY_STAGE(environment, version, stage)
#endif
-#define GEN_VEC_SCALAR_OVERLOADS(FUNC_NAME, BASE_TYPE, AVAIL)
\
- GEN_BOTH_OVERLOADS(FUNC_NAME, BASE_TYPE, BASE_TYPE##2, AVAIL)
\
@@ -35,25 +35,48 @@ namespace hlsl {
#define _HLSL_16BIT_AVAILABILITY_STAGE(environment, version, stage)
#endif
-#define GEN_VEC_SCALAR_OVERLOADS(FUNC_NAME, BASE_TYPE, AVAIL)
\
- GEN_BOTH_OVERLOADS(FUNC_NAME, BASE_TYPE, BASE_TYPE##2, AVAIL)
\
501 - 563 of 563 matches
Mail list logo