OSDN Git Service

st/glsl_to_nir: disable io lowering and array splitting of fs inputs
authorTimothy Arceri <tarceri@itsqueeze.com>
Mon, 15 Jan 2018 00:48:16 +0000 (11:48 +1100)
committerTimothy Arceri <tarceri@itsqueeze.com>
Tue, 30 Jan 2018 22:14:08 +0000 (09:14 +1100)
commit283e25102be5dfd8f9759ceb08961708e09724be
tree19426ec3f52968d40f327f72dd90fda504b8346e
parent9a2e0856805d5dd27975d5a2bf68fab44346aa4f
st/glsl_to_nir: disable io lowering and array splitting of fs inputs

We need this to be able to support the interpolateAt builtins in a
sane way. It also leads to the generation of more optimal code.

The lowering and splitting is made conditional on lower_all_io_to_temps
because vc4 and freedreno both expect these passes to be enabled and
niether support glsl 400 so don't need to deal with the interpolateAt
builtins.

We leave the other stages for now as to avoid regressions. Ideally we
could remove the stage checks and just set the nir options correctly
for each stage. However all gallium drivers currently just use return
the same nir compiler options for all stages, and it's probably more
trouble than its worth to change this.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
src/mesa/state_tracker/st_glsl_to_nir.cpp