radeonsi: generate an explicit switch instruction over vertex streams
authorNicolai Hähnle <nicolai.haehnle@amd.com>
Tue, 29 Nov 2016 15:25:21 +0000 (16:25 +0100)
committerNicolai Hähnle <nicolai.haehnle@amd.com>
Mon, 12 Dec 2016 08:04:49 +0000 (09:04 +0100)
commitbdf1bf1cb5422a944205ea30b2eb203a73bdd736
tree026a9e3ad8318b0c3b31b53123166e4f0adb5d4a
parentbae929f96ee57ec55d15fae87bf80c45a8bd7e4d
radeonsi: generate an explicit switch instruction over vertex streams

SimplifyCFG generates a switch instruction anyway when all four streams
are present, but is simultaneously not smart enough to eliminate some
redundant jumps that it generates.

The generated assembly is still a bit silly, probably because the
control flow annotation doesn't know how to handle a switch with uniform
condition.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
src/gallium/drivers/radeonsi/si_shader.c