Add CommonUniformElim pass
authorGregF <greg@LunarG.com>
Mon, 3 Jul 2017 23:23:04 +0000 (17:23 -0600)
committerDavid Neto <dneto@google.com>
Thu, 3 Aug 2017 15:34:58 +0000 (11:34 -0400)
commitf4b29f3bf79bd64c7b4855d5f9fde69eb224244a
tree6beba55a849ef9408e3c728def7b53ffb19a9ad8
parentc1b46eedbd8a33370d4bb97e553f8893f10a54f8
Add CommonUniformElim pass

- UniformElim: Only process reachable blocks

- UniformElim: Don't reuse loads of samplers and images across blocks.
  Added a second phase which only reuses loads within a block for samplers
  and images.

- UniformElim: Upgrade CopyObject skipping in GetPtr

- UniformElim: Add extensions whitelist
  Currently disallowing SPV_KHR_variable_pointers because it doesn't
  handle extended pointer forms.

- UniformElim: Do not process shaders with GroupDecorate

- UniformElim: Bail on shaders with non-32-bit ints.

- UniformElim: Document support for only single index and add TODO.
include/spirv-tools/optimizer.hpp
source/opt/CMakeLists.txt
source/opt/common_uniform_elim_pass.cpp [new file with mode: 0644]
source/opt/common_uniform_elim_pass.h [new file with mode: 0644]
source/opt/optimizer.cpp
source/opt/passes.h
test/opt/CMakeLists.txt
test/opt/common_uniform_elim_test.cpp [new file with mode: 0644]
tools/opt/opt.cpp