[Mesa-dev] [PATCH] tgsi: add some atomic opcodes to tgsi_opcode_infer_type
Marek Olšák
maraeo at gmail.com
Mon Jun 18 20:56:33 UTC 2018
Reviewed-by: Marek Olšák <marek.olsak at amd.com>
Marek
On Thu, Jun 14, 2018 at 7:35 PM, Gurchetan Singh <
gurchetansingh at chromium.org> wrote:
> We don't have cases for atomic types, some of which are explicitly
> signed or unsigned.
>
> The other opcodes could have uint or int return types, based on the
> sources.
> ---
> src/gallium/auxiliary/tgsi/tgsi_info.c | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/src/gallium/auxiliary/tgsi/tgsi_info.c
> b/src/gallium/auxiliary/tgsi/tgsi_info.c
> index 4aa658785cf..6f3cd9c5304 100644
> --- a/src/gallium/auxiliary/tgsi/tgsi_info.c
> +++ b/src/gallium/auxiliary/tgsi/tgsi_info.c
> @@ -253,6 +253,9 @@ tgsi_opcode_infer_src_type(enum tgsi_opcode opcode,
> uint src_idx)
> return TGSI_TYPE_SIGNED;
>
> switch (opcode) {
> + case TGSI_OPCODE_ATOMUADD:
> + case TGSI_OPCODE_ATOMUMAX:
> + case TGSI_OPCODE_ATOMUMIN:
> case TGSI_OPCODE_UIF:
> case TGSI_OPCODE_TXF:
> case TGSI_OPCODE_TXF_LZ:
> @@ -268,6 +271,8 @@ tgsi_opcode_infer_src_type(enum tgsi_opcode opcode,
> uint src_idx)
> case TGSI_OPCODE_U2I64:
> case TGSI_OPCODE_MEMBAR:
> return TGSI_TYPE_UNSIGNED;
> + case TGSI_OPCODE_ATOMIMAX:
> + case TGSI_OPCODE_ATOMIMIN:
> case TGSI_OPCODE_IMUL_HI:
> case TGSI_OPCODE_I2F:
> case TGSI_OPCODE_I2D:
> --
> 2.13.5
>
> _______________________________________________
> 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/20180618/20e1d63b/attachment.html>
More information about the mesa-dev
mailing list