dawn-cmake/test/intrinsics/gen/textureNumSamples
Stephen White f9b8b6104d GLSL: implement CombineSamplers transform (string version).
This transform converts all separate texture/sampler references
in a program into combined texture/samplers. This is required for GLSL,
which does not support separate texture/samplers.

As input, the transform requires a map from the unique sampler/texture
pairs previously gathered by the Resolver to strings, which will be
used as the names of the newly-generated combined samplers. Note that
binding points are unused by GLSL, and so are set to (0, 0) with
collision detection disabled.

All function signatures containing textures or samplers are rewritten,
as well as function calls and texture intrinsic calls. For texture
intrinsic calls, a placeholder sampler is used to satisfy the subsequent
Resolver pass (GLSL texture intrinsics do not require a separate sampler,
but WGSL intrinsics do). The placeholder is also used if the shader
contains only texture references (e.g., textureLoad).

Bug: tint:1366

Change-Id: Iff8407d28fdc2a8adac5cb655707a08c8553c389
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/77080
Reviewed-by: Ben Clayton <bclayton@google.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Stephen White <senorblanco@chromium.org>
2022-01-24 17:17:22 +00:00
..
2c6f14.wgsl wgsl: Replace [[decoration]] with @decoration 2022-01-19 22:46:57 +00:00
2c6f14.wgsl.expected.glsl GLSL: implement CombineSamplers transform (string version). 2022-01-24 17:17:22 +00:00
2c6f14.wgsl.expected.hlsl transform/shader_io: Generate a wrapper function 2021-08-04 22:15:28 +00:00
2c6f14.wgsl.expected.msl transform/shader_io: Generate a wrapper function 2021-08-04 22:15:28 +00:00
2c6f14.wgsl.expected.spvasm spirv: Use generic transform to process shader IO 2021-08-05 17:34:19 +00:00
2c6f14.wgsl.expected.wgsl wgsl: Replace [[decoration]] with @decoration 2022-01-19 22:46:57 +00:00
42f8bb.wgsl wgsl: Replace [[decoration]] with @decoration 2022-01-19 22:46:57 +00:00
42f8bb.wgsl.expected.glsl GLSL: implement CombineSamplers transform (string version). 2022-01-24 17:17:22 +00:00
42f8bb.wgsl.expected.hlsl transform/shader_io: Generate a wrapper function 2021-08-04 22:15:28 +00:00
42f8bb.wgsl.expected.msl transform/shader_io: Generate a wrapper function 2021-08-04 22:15:28 +00:00
42f8bb.wgsl.expected.spvasm spirv: Use generic transform to process shader IO 2021-08-05 17:34:19 +00:00
42f8bb.wgsl.expected.wgsl wgsl: Replace [[decoration]] with @decoration 2022-01-19 22:46:57 +00:00
449d23.wgsl wgsl: Replace [[decoration]] with @decoration 2022-01-19 22:46:57 +00:00
449d23.wgsl.expected.glsl GLSL: implement CombineSamplers transform (string version). 2022-01-24 17:17:22 +00:00
449d23.wgsl.expected.hlsl transform/shader_io: Generate a wrapper function 2021-08-04 22:15:28 +00:00
449d23.wgsl.expected.msl transform/shader_io: Generate a wrapper function 2021-08-04 22:15:28 +00:00
449d23.wgsl.expected.spvasm spirv: Use generic transform to process shader IO 2021-08-05 17:34:19 +00:00
449d23.wgsl.expected.wgsl wgsl: Replace [[decoration]] with @decoration 2022-01-19 22:46:57 +00:00
a3c8a0.wgsl wgsl: Replace [[decoration]] with @decoration 2022-01-19 22:46:57 +00:00
a3c8a0.wgsl.expected.glsl GLSL: implement CombineSamplers transform (string version). 2022-01-24 17:17:22 +00:00
a3c8a0.wgsl.expected.hlsl transform/shader_io: Generate a wrapper function 2021-08-04 22:15:28 +00:00
a3c8a0.wgsl.expected.msl transform/shader_io: Generate a wrapper function 2021-08-04 22:15:28 +00:00
a3c8a0.wgsl.expected.spvasm spirv: Use generic transform to process shader IO 2021-08-05 17:34:19 +00:00
a3c8a0.wgsl.expected.wgsl wgsl: Replace [[decoration]] with @decoration 2022-01-19 22:46:57 +00:00