diff options
author | Alejandro PiƱeiro <[email protected]> | 2017-12-04 16:29:34 +0100 |
---|---|---|
committer | Arcady Goldmints-Orlov <[email protected]> | 2019-06-30 16:58:26 -0500 |
commit | 15f134412f690e3c23f5f3a14de2e4cd38dde852 (patch) | |
tree | 3ea360f4e163bf9d73153c6df2d90a1357afff0b /src/compiler | |
parent | 7d7ab34d5f5c280d635a54ae080cffc40e74584a (diff) |
spirv/nir: fill up nir variable info for ubos and ssbo
The data for some nir variables is only filled up for some specific
modes. We need now too for UBO/SSBO, as such info would be used when
linking for OpenGL (ARB_gl_spirv).
There is an existing comment just before that code (starts with XXX)
that points that binding still needs to be filled up for uniform
variables at that point, and that should be fixed, although it doesn't
specify why that's a problem or what would be the alternative. For now
doing the same for UBO/SSBO, and will hope that the future fixing is
done for all of them.
Reviewed-by: Timothy Arceri <[email protected]>
Diffstat (limited to 'src/compiler')
-rw-r--r-- | src/compiler/spirv/vtn_variables.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/compiler/spirv/vtn_variables.c b/src/compiler/spirv/vtn_variables.c index c640e3aa670..b7ec2edd06c 100644 --- a/src/compiler/spirv/vtn_variables.c +++ b/src/compiler/spirv/vtn_variables.c @@ -2292,7 +2292,9 @@ vtn_create_variable(struct vtn_builder *b, struct vtn_value *val, assign_missing_member_locations(var); } - if (var->mode == vtn_variable_mode_uniform) { + if (var->mode == vtn_variable_mode_uniform || + var->mode == vtn_variable_mode_ubo || + var->mode == vtn_variable_mode_ssbo) { /* XXX: We still need the binding information in the nir_variable * for these. We should fix that. */ |