r600g/cayman: handle empty vertex shaders
authorDave Airlie <airlied@redhat.com>
Tue, 18 Nov 2014 01:22:01 +0000 (11:22 +1000)
committerDave Airlie <airlied@redhat.com>
Tue, 18 Nov 2014 01:59:47 +0000 (11:59 +1000)
commit4e520101e6a0b4fcd930323c32d1a8a6348c8417
tree08d91844a15e39e82d4d032badb9ef7ad44ea6e7
parent27e1e0e7108511b43d0f56f678c7201f39e2acc5
r600g/cayman: handle empty vertex shaders

Some of the geom shader tests produce an empty vertex shader,
on cayman we'd crash in the finaliser because last_cf was NULL.

cayman doesn't need the NOP workaround, so if the code arrives
here with no last_cf, just emit an END.

fixes crashes in a bunch of piglit geom shader tests.

Cc: "10.3 10.4" <mesa-stable@lists.freedesktop.org>
Reviewed-by: Glenn Kennard <glenn.kennard@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
src/gallium/drivers/r600/sb/sb_bc_finalize.cpp