[Mesa-dev] [PATCH 08/14] intel/compiler: enable shuffle_from_32bit_read at 64-bit gs_input_load
Jason Ekstrand
jason at jlekstrand.net
Thu Jun 14 01:31:40 UTC 2018
How about "Use shuffle_from_32bit_read for 64-bit gs_input_load"? Also, as
a general comment, intel/fs would be a bit more specific prefix
Reviewed-by: Jason Ekstrand <jason at jlekstrand.net>
On Sat, Jun 9, 2018 at 4:13 AM, Jose Maria Casanova Crespo <
jmcasanova at igalia.com> wrote:
> This implementation avoids two unneeded MOVs for each 64-bit
> component. One was done in the old shuffle, to avoid cases of
> src/dst overlap but this is not the case. And the removed MOV
> was already being being done in the shuffle.
>
> Copy propagation wasn't able to remove them because shuffle
> destination values are defined with partial writes because they
> have stride == 2.
> ---
> src/intel/compiler/brw_fs_nir.cpp | 10 +++++-----
> 1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/src/intel/compiler/brw_fs_nir.cpp
> b/src/intel/compiler/brw_fs_nir.cpp
> index 780a9e228de..6abc7c0174d 100644
> --- a/src/intel/compiler/brw_fs_nir.cpp
> +++ b/src/intel/compiler/brw_fs_nir.cpp
> @@ -2305,11 +2305,11 @@ fs_visitor::emit_gs_input_load(const fs_reg &dst,
> }
>
> if (type_sz(dst.type) == 8) {
> - shuffle_32bit_load_result_to_64bit_data(
> - bld, tmp_dst, retype(tmp_dst, BRW_REGISTER_TYPE_F),
> num_components);
> -
> - for (unsigned c = 0; c < num_components; c++)
> - bld.MOV(offset(dst, bld, iter * 2 + c), offset(tmp_dst, bld,
> c));
> + shuffle_from_32bit_read(bld,
> + offset(dst, bld, iter * 2),
> + retype(tmp_dst, BRW_REGISTER_TYPE_D),
> + 0,
> + num_components);
> }
>
> if (num_iterations > 1) {
> --
> 2.17.1
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20180613/984c8ff6/attachment.html>
More information about the mesa-dev
mailing list