[Mesa-dev] [PATCH v2 00/31] ARB_bindless_texture: round one (GLSL)

Samuel Pitoiset samuel.pitoiset at gmail.com
Mon Apr 24 10:35:31 UTC 2017


Hi,

Because ARB_bindless_texture [1] is a massive feature which requires
a bunch of changes in Mesa, I splitted the whole series in order to
help reviewers. The first one adds all GLSL bits to the compiler.

This implements a new alternative which no longer introduces new base
types for bindless samplers/images (ie. GLSL_TYPE_BINDLESS_SAMPLER and
GLSL_TYPE_BINDLESS_IMAGE have been removed). This has been requested by
Nicolai. I have to admit that it was a bunch of frustration but in the
end it looks pretty good. :-)

It was actually simpler than expected to rework the whole thing because
all other parts are working. I have the same passrate with this series.

No regressions with a full piglit run (including compiler tests). And
my private shader-db doesn't report anything bad.

The whole series which implements ARB_bindless_texture for RadeonSI
seems to work fine. It has been tested with some Feral games (Dirt Rally).
Some parts still need to be improved though, but one thing at a time!

Please review,
Thanks!

[1] https://www.khronos.org/registry/OpenGL/extensions/ARB/ARB_bindless_texture.txt

Samuel Pitoiset (31):
  mesa: add ARB_bindless_texture to the extensions list
  glsl: add ARB_bindless_texture enable
  glsl: make sampler/image types as 64-bit
  glsl: make component_slots() returns 2 for samplers/images
  glsl: process bindless/bound layout qualifiers
  glsl: allow to declare bindless samplers/images as non-uniform
  glsl: allow bindless samplers/images as shader outputs
  glsl: allow bindless samplers/images as out and inout parameters
  glsl: allow bindless samplers/images as function return
  glsl: allow bindless samplers/images inside interface blocks
  glsl: fix std140/std430 interfaces for bindless samplers/images
  glsl: allow bindless images to be declared inside structures
  glsl: allow image qualifiers inside structures
  glsl: allow input memory qualifiers for images
  glsl: allow bindless samplers/images as varying variables
  glsl: allow bindless samplers/images as vertex shader inputs
  glsl: reject bindless samplers/images frag inputs without 'flat'
  glsl: relax bindless sampler arrays indexing
  glsl: fix explicit binding location for bindless samplers/images
  glsl: add _mesa_glsl_parse_state object to is_lvalue()
  glsl: allow bindless samplers/images to be l-values
  glsl: allow bindless samplers/images to be initialized
  glsl: allow bindless samplers/images to be assigned
  glsl: add ARB_bindless_texture operations
  glsl: add is_valid_constructor() helper function
  glsl: allow bindless samplers/images to be used with constructors
  glsl: implement ARB_bindless_texture conversions
  glsl: lower bindless sampler/image packed varyings
  glsl: do not count bindless samplers/images when linking uniforms
  glsl: disable tree grafting optimization for bindless images
  glsl: link bindless layout qualifiers

 src/compiler/glsl/ast.h                      |   8 +
 src/compiler/glsl/ast_array_index.cpp        |  10 +-
 src/compiler/glsl/ast_function.cpp           |  93 ++++++++--
 src/compiler/glsl/ast_to_hir.cpp             | 245 ++++++++++++++++++++++++---
 src/compiler/glsl/ast_type.cpp               |  65 +++++++
 src/compiler/glsl/glsl_parser.yy             |  49 +++++-
 src/compiler/glsl/glsl_parser_extras.cpp     |  12 ++
 src/compiler/glsl/glsl_parser_extras.h       |  17 ++
 src/compiler/glsl/ir.cpp                     |  41 ++++-
 src/compiler/glsl/ir.h                       |  20 ++-
 src/compiler/glsl/ir_clone.cpp               |   4 +-
 src/compiler/glsl/ir_expression_operation.py |   6 +
 src/compiler/glsl/ir_print_visitor.cpp       |   8 +-
 src/compiler/glsl/ir_validate.cpp            |  20 +++
 src/compiler/glsl/link_uniforms.cpp          |  12 +-
 src/compiler/glsl/linker.cpp                 |  44 +++++
 src/compiler/glsl/lower_packed_varyings.cpp  |  24 ++-
 src/compiler/glsl/opt_tree_grafting.cpp      |   9 +
 src/compiler/glsl/standalone_scaffolding.cpp |   1 +
 src/compiler/glsl_types.cpp                  |  30 ++++
 src/compiler/glsl_types.h                    |   4 +-
 src/mesa/main/extensions_table.h             |   1 +
 src/mesa/main/mtypes.h                       |  11 ++
 src/mesa/main/uniform_query.cpp              |   4 +-
 src/mesa/program/ir_to_mesa.cpp              |   4 +
 src/mesa/state_tracker/st_glsl_to_tgsi.cpp   |   5 +
 26 files changed, 682 insertions(+), 65 deletions(-)

-- 
2.12.2



More information about the mesa-dev mailing list