Skip to content

Conversation

@bogner
Copy link
Collaborator

@bogner bogner commented Nov 14, 2025

This adds for arrays of various shapes in cbuffers that were failing before llvm/llvm-project#147352 was implemented, and updates XFAILs appropriately for that change.

This adds for arrays of various shapes in cbuffers. These currently fail
due to layout issues, which are tracked by llvm/llvm-project#147352.
Out[1] = w[2].z;
Out[2] = v[1].q;
Out[3] = v[2].q;
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does accessing the array inside the struct work too with llvm/llvm-project#147352?

Suggested change
}
Out[4] = v[0].x[1];
Out[5] = v[2].x[0];
}

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It does. I've added the tests to show it.

@@ -0,0 +1,101 @@
#--- source.hlsl
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not a cbuffer test. Either the PR description needs to be updated, or this test should be added in a separate change.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I must have slipped this one in by accident. I'll remove it from this PR and commit it separately later.

Copy link
Contributor

@inbelic inbelic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Relevant buffer visualization links for other reviewers:

array-dynamic-index, array-of-structs/dynamic-struct

Copy link
Member

@hekota hekota left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@bogner bogner merged commit df2689c into llvm:main Nov 18, 2025
10 of 13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants