[Mesa-dev] [PATCH] radeonsi: add support for viewport array (v2)

Marek Olšák maraeo at gmail.com
Fri Jun 26 16:03:08 PDT 2015


If you write VIEWPORT_INDEX at location 0, it overwrites POSITION
which happens to be at location 0 too and that's why the test fails.

The fix is not to call si_shader_io_get_unique_index (or its caller
get_param_index) for LAYER and VIEWPORT_INDEX.

LAYER and VIEWPORT_INDEX should be ignored in
si_llvm_emit_es_epilogue, as is required by the spec.

Marek

On Fri, Jun 26, 2015 at 11:10 PM, Dave Airlie <airlied at gmail.com> wrote:
> On 26 June 2015 at 07:43, Dave Airlie <airlied at gmail.com> wrote:
>> On 26 June 2015 at 07:11, Marek Olšák <maraeo at gmail.com> wrote:
>>> Wait a moment, how did it fail with si_shader_io_get_unique_index? The
>>> function shouldn't be called for ES with the viewport index, because
>>> ES can't pass the output to GS. If it was called, ignoring the
>>> viewport index in si_llvm_emit_es_epilogue should fix it.
>>
>> It asserted in a couple of ARB_fragment_layer_viewport tests.
>>
>> It seemed due to the putting viewpor and layer into params, but I
>> don't have a backtrace here
>> right now, but I can get it tomorrow.
>>
>> Dave.
>
> Okay I've tested this again, and
> tests/spec/arb_fragment_layer_viewport/viewport-vs-write-gs-no-write-simple.shader_test
> fails without the change I made.
>
> si_llvm_emit_es_epilogue is what calls it, but with the assert removed
> by your patch, the test still fails unless I add my change.
>
> Dave.


More information about the mesa-dev mailing list