intel/compiler: Don't emit no-op cr0 changes
If mask is 0, we're asking for no changes to cr0. Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5566>
This commit is contained in:
@@ -258,6 +258,9 @@ fs_visitor::emit_shader_float_controls_execution_mode()
|
||||
fs_builder abld = bld.annotate("shader floats control execution mode");
|
||||
unsigned mask, mode = brw_rnd_mode_from_nir(execution_mode, &mask);
|
||||
|
||||
if (mask == 0)
|
||||
return;
|
||||
|
||||
abld.emit(SHADER_OPCODE_FLOAT_CONTROL_MODE, bld.null_reg_ud(),
|
||||
brw_imm_d(mode), brw_imm_d(mask));
|
||||
}
|
||||
|
Reference in New Issue
Block a user