SPIRV-Cross/reference/shaders-hlsl-no-opt/asm/frag/composite-insert-inheritance.asm.frag
Chip Davis 5547b25afe Interleave undef values with constants and types.
Undef values may be of struct type and may be used in constants.
Therefore, they must be interleaved with constants and types.

Fixes the rest of the Vulkan CTS test
`dEQP-VK.spirv_assembly.instruction.compute.opundef.undefined_spec_constant_composite`.

(Please excuse the churn in the reference output; it's an inevitable
result of this change.)
2022-11-20 02:08:37 -08:00

85 lines
1.6 KiB
JavaScript

static float4 _32;
static const float4 _34[2] = { 0.0f.xxxx, 0.0f.xxxx };
static float4 vInput;
static float4 FragColor;
struct SPIRV_Cross_Input
{
float4 vInput : TEXCOORD0;
};
struct SPIRV_Cross_Output
{
float4 FragColor : SV_Target0;
};
void frag_main()
{
float4 _37 = vInput;
float4 _38 = _37;
_38.x = 1.0f;
_38.y = 2.0f;
_38.z = 3.0f;
_38.w = 4.0f;
FragColor = _38;
float4 _6 = _37;
_6.x = 1.0f;
_6.y = 2.0f;
_6.z = 3.0f;
_6.w = 4.0f;
FragColor = _6;
float4 _42 = _37;
_42.x = 1.0f;
_42.y = 2.0f;
_42.z = 3.0f;
_42.w = 4.0f;
FragColor = _42;
float4 _44 = _37;
_44.x = 1.0f;
float4 _45 = _44;
_45.y = 2.0f;
float4 _46 = _45;
_46.z = 3.0f;
float4 _47 = _46;
_47.w = 4.0f;
FragColor = _47 + _44;
FragColor = _47 + _45;
float4 _49;
_49.x = 1.0f;
_49.y = 2.0f;
_49.z = 3.0f;
_49.w = 4.0f;
FragColor = _49;
float4 _53 = 0.0f.xxxx;
_53.x = 1.0f;
FragColor = _53;
float4 _54[2] = _34;
_54[1].z = 1.0f;
_54[0].w = 2.0f;
FragColor = _54[0];
FragColor = _54[1];
float4x4 _58 = float4x4(0.0f.xxxx, 0.0f.xxxx, 0.0f.xxxx, 0.0f.xxxx);
_58[1].z = 1.0f;
_58[2].w = 2.0f;
FragColor = _58[0];
FragColor = _58[1];
FragColor = _58[2];
FragColor = _58[3];
float4 PHI;
PHI = _46;
float4 _65 = PHI;
_65.w = 4.0f;
FragColor = _65;
}
SPIRV_Cross_Output main(SPIRV_Cross_Input stage_input)
{
vInput = stage_input.vInput;
frag_main();
SPIRV_Cross_Output stage_output;
stage_output.FragColor = FragColor;
return stage_output;
}