ac: fix broken elimination of duplicated VS exports
authorMarek Olšák <marek.olsak@amd.com>
Mon, 8 May 2017 14:37:26 +0000 (16:37 +0200)
committerMarek Olšák <marek.olsak@amd.com>
Mon, 8 May 2017 17:18:29 +0000 (19:18 +0200)
commit34bc470fa61fd667514a82a412bce310ab9c9653
tree25af0f7768af3b1a66c910368bef7e0bd535c260
parent0160fb1d50d314b9de496d49475a33ddff0f5702
ac: fix broken elimination of duplicated VS exports

The renumbering code didn't take into account that multiple VS exports
can have the same PARAM index. This also significantly simplifies
the renumbering. Thankfully, we have piglits for this:

    spec@arb_gpu_shader5@arb_gpu_shader5-interpolateatcentroid-packing
    spec@glsl-1.50@execution@interface-blocks-complex-vs-fs

Reported by Michel Dänzer.

Fixes: b08715499e61 ("ac: eliminate duplicated VS exports")
Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
src/amd/common/ac_llvm_build.c