diff options
author | Jason Ekstrand <[email protected]> | 2015-12-30 17:00:16 -0800 |
---|---|---|
committer | Jason Ekstrand <[email protected]> | 2015-12-30 17:45:43 -0800 |
commit | e993e45eb157014fe6a7f65be8edda9fd716dc52 (patch) | |
tree | 0cdc5ad597d54b66a0cba7666488248bbb42c30f /src/vulkan/anv_pipeline.c | |
parent | db3a64fcea6318ab5ded186a347e732b7956f1f7 (diff) |
nir/spirv: Get the shader stage from the SPIR-V
Previously, we depended on it being passed in.
Diffstat (limited to 'src/vulkan/anv_pipeline.c')
-rw-r--r-- | src/vulkan/anv_pipeline.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/vulkan/anv_pipeline.c b/src/vulkan/anv_pipeline.c index c17809c519f..0f7835ea84f 100644 --- a/src/vulkan/anv_pipeline.c +++ b/src/vulkan/anv_pipeline.c @@ -108,7 +108,8 @@ anv_shader_compile_to_nir(struct anv_device *device, assert(spirv[0] == SPIR_V_MAGIC_NUMBER); assert(module->size % 4 == 0); - nir = spirv_to_nir(spirv, module->size / 4, stage, nir_options); + nir = spirv_to_nir(spirv, module->size / 4, nir_options); + assert(nir->stage == stage); nir_validate_shader(nir); nir_lower_returns(nir); |