intel/eu/validate/gen12: Fix validation of SYNC instruction.
authorFrancisco Jerez <currojerez@riseup.net>
Wed, 6 Feb 2019 05:54:54 +0000 (21:54 -0800)
committerFrancisco Jerez <currojerez@riseup.net>
Fri, 11 Oct 2019 19:24:16 +0000 (12:24 -0700)
src0 will typically be null for this instruction.

Reviewed-by: Caio Marcelo de Oliveira Filho <caio.oliveira@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/intel/compiler/brw_eu_validate.c

index 068143d0dd0af50d5a8435cdbdb6cf0def3fc789..7acc9c3b57d8ddbe9c438a07141a3204c76b0899 100644 (file)
@@ -280,7 +280,7 @@ sources_not_null(const struct gen_device_info *devinfo,
    if (inst_is_split_send(devinfo, inst))
       return (struct string){};
 
-   if (num_sources >= 1)
+   if (num_sources >= 1 && brw_inst_opcode(devinfo, inst) != BRW_OPCODE_SYNC)
       ERROR_IF(src0_is_null(devinfo, inst), "src0 is null");
 
    if (num_sources == 2)