mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-24 19:40:10 +01:00
nir/opt_phi_precision: Work with libraries
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Reviewed-by: Karol Herbst <kherbst@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25625>
This commit is contained in:
parent
cd1ba21958
commit
b1b7616418
1 changed files with 4 additions and 7 deletions
|
|
@ -444,13 +444,10 @@ nir_opt_phi_precision(nir_shader *shader)
|
|||
unsigned bit_sizes_used = shader->info.bit_sizes_float |
|
||||
shader->info.bit_sizes_int;
|
||||
|
||||
if (!bit_sizes_used) {
|
||||
nir_shader_gather_info(shader, nir_shader_get_entrypoint(shader));
|
||||
bit_sizes_used = shader->info.bit_sizes_float |
|
||||
shader->info.bit_sizes_int;
|
||||
}
|
||||
|
||||
if (!(bit_sizes_used & (8 | 16)))
|
||||
/* Note: if the info is zeroed, we conservatively run to avoid gathering
|
||||
* info, which doesn't work for libraries.
|
||||
*/
|
||||
if (bit_sizes_used && !(bit_sizes_used & (8 | 16)))
|
||||
return false;
|
||||
|
||||
nir_foreach_function_impl(impl, shader) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue