mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-07 23:50:11 +01:00
nvk: use || instead of | between bools
We have to split each call into its own variable, because simply replacing `|` with `||` would short-circuit the right side when the left side succeeds. Fixes:dadf9d59e6("nvk: Add support for variable pointers") Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26509> (cherry picked from commit81ec1fa0b5)
This commit is contained in:
parent
10a47cde73
commit
65eb17f415
2 changed files with 12 additions and 9 deletions
|
|
@ -334,7 +334,7 @@
|
|||
"description": "nvk: use `||` instead of `|` between bools",
|
||||
"nominated": true,
|
||||
"nomination_type": 1,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"main_sha": null,
|
||||
"because_sha": "dadf9d59e6f9e0c4a7a7e84af6eca85efe24476a",
|
||||
"notes": null
|
||||
|
|
|
|||
|
|
@ -682,12 +682,15 @@ nvk_nir_lower_descriptors(nir_shader *nir,
|
|||
* are left and lowers them to slightly less efficient but variable-
|
||||
* pointers-correct versions.
|
||||
*/
|
||||
return nir_shader_instructions_pass(nir, try_lower_descriptors_instr,
|
||||
nir_metadata_block_index |
|
||||
nir_metadata_dominance,
|
||||
(void *)&ctx) |
|
||||
nir_shader_instructions_pass(nir, lower_ssbo_descriptor_instr,
|
||||
nir_metadata_block_index |
|
||||
nir_metadata_dominance,
|
||||
(void *)&ctx);
|
||||
bool pass_lower_descriptors =
|
||||
nir_shader_instructions_pass(nir, try_lower_descriptors_instr,
|
||||
nir_metadata_block_index |
|
||||
nir_metadata_dominance,
|
||||
(void *)&ctx);
|
||||
bool pass_lower_ssbo =
|
||||
nir_shader_instructions_pass(nir, lower_ssbo_descriptor_instr,
|
||||
nir_metadata_block_index |
|
||||
nir_metadata_dominance,
|
||||
(void *)&ctx);
|
||||
return pass_lower_descriptors || pass_lower_ssbo;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue