Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HLSL: implement 4 (of 6) structuredbuffer types #725

Merged
merged 1 commit into from Feb 22, 2017
Merged

HLSL: implement 4 (of 6) structuredbuffer types #725

merged 1 commit into from Feb 22, 2017

Conversation

ghost
Copy link

@ghost ghost commented Feb 15, 2017

This is a partial implemention of structurebuffers supporting:

  • structured buffer types of:
    • StructuredBuffer
    • RWStructuredBuffer
    • ByteAddressBuffer
    • RWByteAddressBuffer
  • Load/Load[234], Store/Store[234], GetDimensions methods (where allowed by type)
  • globallycoherent flag
  • Atomic operations on RWByteAddressBuffer

But NOT yet supporting:

  • Atomic operations on RWByteAddressBuffer Now implemented
  • AppendStructuredBuffer / ConsumeStructuredBuffer types
  • IncrementCounter/DecrementCounter methods

Please note # 1: the stride returned by GetDimensions is as calculated per std430, and may not match other environments in all cases.

Please note # 2: the hidden internal counter for Increment/Decrement methods is not in place on RW types. This is also a potential layout difference, until that is implemented.

case EHTokRWStructuredBuffer:
break;
case EHTokStructuredBuffer:
readonly = true;
Copy link
Member

Choose a reason for hiding this comment

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

Too much columnizing? Not quite seeing logical groupings the need verification by visually seeing the column instead of the row.

qualifier.storage = type.getQualifier().storage;
qualifier.readonly = type.getQualifier().readonly;
Copy link
Member

Choose a reason for hiding this comment

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

Too many spaces; maybe historical columnizing, but out of place now.

@johnkslang
Copy link
Member

I reviewed this, and it looks good to me. Waiting for author removal of WIP.

This is a partial implemention of structurebuffers supporting:

* structured buffer types of:
*   StructuredBuffer
*   RWStructuredBuffer
*   ByteAddressBuffer
*   RWByteAddressBuffer

* Atomic operations on RWByteAddressBuffer

* Load/Load[234], Store/Store[234], GetDimensions methods (where allowed by type)

* globallycoherent flag

But NOT yet supporting:

* AppendStructuredBuffer / ConsumeStructuredBuffer types
* IncrementCounter/DecrementCounter methods

Please note: the stride returned by GetDimensions is as calculated by glslang for std430,
and may not match other environments in all cases.
@ghost ghost changed the title WIP: implement structuredbuffers HLSL: implement 4 (of 6) structuredbuffer types Feb 21, 2017
@ghost
Copy link
Author

ghost commented Feb 21, 2017

Removed columnizing from hlslGrammar, and removed WIP, post real world sanity testing.

@johnkslang johnkslang merged commit 2fbe08c into KhronosGroup:master Feb 22, 2017
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.

1 participant