i965: Don't try to decode types for non-existent src1.
authorKenneth Graunke <kenneth@whitecape.org>
Sat, 7 Oct 2017 07:14:34 +0000 (00:14 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Tue, 10 Oct 2017 22:11:35 +0000 (15:11 -0700)
commit03087686ffb8c638831256fd17c124d250d7238b
treefc430781b14e1749a2c26850eea63841b5d425ef
parenteab078f1321cbd6b292c88fe1770dc1b24261514
i965: Don't try to decode types for non-existent src1.

KHR-GL45.shader_ballot_tests.ShaderBallotBitmasks has a MOV that hits
this validation path.  MOVs don't have a src1 file, but calling
brw_inst_src1_type() was tripping on src1.file being BRW_IMMEDIATE_VALUE
and the hw_type being something invalid for immediates.

To work around this, just pretend src1 is src0 if there isn't a src1.

Fixes: 2572c2771d0cab0b9bc489d354ede44dfc88547b (i965: Validate "Special
       Requirements for Handling Double Precision Data Types")
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=102680
Reviewed-by: Alejandro PiƱeiro <apinheiro@igalia.com>
src/intel/compiler/brw_eu_validate.c