Skip to content

Conversation

@gtong-nv
Copy link
Contributor

@gtong-nv gtong-nv commented Dec 8, 2025

When a ParameterBlock contains only resources(no uniform data), e.g.

struct Texture2DHandleBuffer
{
    StructuredBuffer<Texture2D.Handle> texture2DbufferOfHandles;
};

ParameterBlock<Texture2DHandleBuffer> BLOCK;

its elements get flattened into global params with RegisterSpace offsets.
The findUnusedSpaceIndex() function was not tracking these RegisterSpace
offsets, causing __slang_resource_heap to be incorrectly placed in the
same descriptor set as the ParameterBlock's resources.

Add tracking of RegisterSpace offsets directly (as absolute descriptor
set numbers) to ensure the bindless resource heap is placed in an
unused descriptor set.

#8952

@gtong-nv gtong-nv added the pr: non-breaking PRs without breaking changes label Dec 9, 2025
@gtong-nv gtong-nv force-pushed the pb_invalid_descriptor_set branch from 29cf11c to e5680ef Compare December 9, 2025 01:01
@gtong-nv gtong-nv force-pushed the pb_invalid_descriptor_set branch from e5680ef to 8b1dfb6 Compare December 9, 2025 01:03
@gtong-nv gtong-nv marked this pull request as ready for review December 9, 2025 01:07
@gtong-nv gtong-nv requested a review from a team as a code owner December 9, 2025 01:07
@tdavidovicNV
Copy link
Collaborator

I've tested this branch and can confirm it solves the bug even on the original code from which I did the simplified repro case.

@gtong-nv
Copy link
Contributor Author

gtong-nv commented Dec 9, 2025

I've tested this branch and can confirm it solves the bug even on the original code from which I did the simplified repro case.

Thanks for confriming. I will request a review again and try to get this merged today

jkwak-work
jkwak-work previously approved these changes Dec 10, 2025
Copy link
Collaborator

@jkwak-work jkwak-work left a comment

Choose a reason for hiding this comment

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

Looks good to me.

But I wonder if the test should check the reflection info as well.

@gtong-nv
Copy link
Contributor Author

Yong gave some feedback during the review meeting. I will refactor it a bit and update

@CLAassistant
Copy link

CLAassistant commented Dec 11, 2025

CLA assistant check
All committers have signed the CLA.

@gtong-nv gtong-nv force-pushed the pb_invalid_descriptor_set branch from 75cce81 to bbfef7a Compare December 11, 2025 22:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr: non-breaking PRs without breaking changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants