driconf: Add a limit_trig_input_range option
With this option enabled range of input values for fsin and fcos is limited to [-2*pi : 2*pi] by calculating the reminder after 2*pi modulo division. This helps to improve calculation precision for large input arguments on Intel. -v2: Add limit_trig_input_range option to prog_key to update shader cache (Lionel) Signed-off-by: Vadym Shovkoplias <vadym.shovkoplias@globallogic.com> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16388>
This commit is contained in:

committed by
Marge Bot

parent
0ff3517fb7
commit
55c71217ec
@@ -1409,6 +1409,9 @@ brw_nir_apply_key(nir_shader *nir,
|
||||
};
|
||||
OPT(nir_lower_subgroups, &subgroups_options);
|
||||
|
||||
if (key->limit_trig_input_range)
|
||||
OPT(brw_nir_limit_trig_input_range_workaround);
|
||||
|
||||
if (progress)
|
||||
brw_nir_optimize(nir, compiler, is_scalar, false);
|
||||
}
|
||||
|
Reference in New Issue
Block a user