-
Notifications
You must be signed in to change notification settings - Fork 819
Closed
Labels
bugBug, regression, crashBug, regression, crashneeds-triageAwaiting triageAwaiting triagespirvWork related to SPIR-VWork related to SPIR-V
Description
Description
I ran into this by accident, testing the types that vk::BufferPointer performs loads/stores with.
Steps to Reproduce
struct StaticMeshVertex
{
float3 Position;
uint pad;
};
StaticMeshVertex VertexFactory_GetVertex(uint vertexId)
{
StaticMeshVertex retval;
float3 uninit;
vk::BufferPointer<StaticMeshVertex,4>(0xdeadbeefull).Get().Position = uninit;
return retval;
}https://godbolt.org/z/ee9PEMEsM
Actual Behavior
If the variable on the right hand side of the assignment is an OpUndef the corresponding OpStore won't be generated, and the BDA write gets sliently dropped.
If you perform the store with a constant or something else, it will be preserved
Environment
- DXC version
- Host Operating System <!--- Host operating system and version --->
Metadata
Metadata
Assignees
Labels
bugBug, regression, crashBug, regression, crashneeds-triageAwaiting triageAwaiting triagespirvWork related to SPIR-VWork related to SPIR-V
Type
Projects
Status
Triaged