Commit Graph

395 Commits

Author SHA1 Message Date
Hans-Kristian Arntzen
df58debf7a Add support for constexpr samplers in MSL. 2018-04-17 17:43:32 +02:00
Hans-Kristian Arntzen
3a8335eee0
Merge pull request #537 from KhronosGroup/fix-535
Unsigned integers are disallowed on legacy targets.
2018-04-17 15:30:03 +02:00
Hans-Kristian Arntzen
b9cd3dcd7f Run format_all.sh. 2018-04-17 15:01:31 +02:00
Hans-Kristian Arntzen
e930f79e2e Be a bit smarter about uint on legacy targets.
Allow constants (array sizes for example), but using unsigned opcodes,
and unsigned-specific opcodes is a problem.
2018-04-17 14:56:49 +02:00
Hans-Kristian Arntzen
b06c1af9b3 Distinguish between enhanced_layouts and SSO requirements.
Block locations are 440, but non-block are 410 ...
2018-04-17 14:16:27 +02:00
Hans-Kristian Arntzen
28c9be8a23 Unsigned integers are disallowed on legacy targets.
There is no sensible way to map this that would work in all scenarios.
2018-04-17 13:56:10 +02:00
Hans-Kristian Arntzen
e1ccfd5dbb Implement all of subgroup. 2018-04-10 17:16:41 +02:00
Hans-Kristian Arntzen
f6c0e53f58 Start adding Vulkan 1.1 subgroup support to GLSL. 2018-04-10 16:13:33 +02:00
Andrei Alexeyev
4a43024dba
Strip uniform locations for ESSL < 3.00 and GLSL < 430 2018-04-07 22:14:35 +03:00
Hans-Kristian Arntzen
694b314f87 Support empty structs.
Need to fake it by pretending it has one dummy member.
2018-04-05 16:26:54 +02:00
Hans-Kristian Arntzen
31a3fdf4ee Decouple public require_extension and the internal use of the function. 2018-04-05 14:43:31 +02:00
Hans-Kristian Arntzen
938040be0b Only disable binding layout for UBOs. 2018-04-03 16:58:26 +02:00
Hans-Kristian Arntzen
fe697a80f5 Emit classic uniform for UBO in GLSL 1.30. 2018-04-03 16:58:26 +02:00
Hans-Kristian Arntzen
65be63fd04
Merge pull request #521 from KhronosGroup/fix-516
Support dual-source blending on GLSL and MSL.
2018-04-03 16:54:32 +02:00
Hans-Kristian Arntzen
a6e211e00b Support dual-source blending on GLSL and MSL. 2018-04-03 16:04:49 +02:00
Hans-Kristian Arntzen
3229e6efb6 Add more illegal name replacement in MSL. 2018-04-03 15:36:35 +02:00
Hans-Kristian Arntzen
a901b4c814 Remove redundant temporary sort. 2018-03-24 04:22:34 +01:00
Hans-Kristian Arntzen
c1947aa447 Update glslang/SPIRV-Tools on Travis. 2018-03-24 04:16:18 +01:00
Hans-Kristian Arntzen
35f64d03bb Fix name aliasing for temporary variables. 2018-03-24 01:53:49 +01:00
Hans-Kristian Arntzen
719cf9d42f Run format_all.sh. 2018-03-13 14:05:33 +01:00
Hans-Kristian Arntzen
8e90382675 Properly flatten MRT outputs in MSL. 2018-03-13 14:03:35 +01:00
Hans-Kristian Arntzen
b46910e9f5 Access chain into packed vectors as arrays.
Cleaner and should be more compatible with storing to packed vector
elements.

Fix CompositeExtract bug with packed vectors on MSL.
2018-03-13 12:13:33 +01:00
Hans-Kristian Arntzen
4979d10b54 Implement packHalf2x16/unpackHalf2x16 on MSL. 2018-03-12 17:51:14 +01:00
Hans-Kristian Arntzen
ae2680c898 Make sure ballotARB inherits expression dependencies. 2018-03-12 17:42:48 +01:00
Hans-Kristian Arntzen
938c7debed Handle control-dependent temporaries.
Derivatives, subgroup and implicit-lod instructions all need to happen
in the block they were created.
2018-03-12 17:34:54 +01:00
Hans-Kristian Arntzen
012377f811 Refactor block IO emission to use bitset. 2018-03-12 15:59:34 +01:00
Hans-Kristian Arntzen
9fbd8b789e Update tests for latest SPIRV-Tools and glslang. 2018-03-12 15:11:55 +01:00
Hans-Kristian Arntzen
e8e58844d4 Rewrite everything to use Bitset rather than uint64_t. 2018-03-12 13:24:14 +01:00
Sidney Just
e66fd6c2a0 Added generation of the textureXYZGrad() legacy GLSL instruction 2018-03-12 00:59:06 +10:00
Hans-Kristian Arntzen
9a52713d77 Run format_all.sh. 2018-03-09 15:26:36 +01:00
Hans-Kristian Arntzen
1de74fdabd Explicitly emit break/continues in selection branches. 2018-03-09 13:59:39 +01:00
Hans-Kristian Arntzen
e0efa737ca Expand the implementation of inherit_expression_dependencies. 2018-03-09 13:21:38 +01:00
Hans-Kristian Arntzen
28cccc3dbb Emit complex continue blocks "properly". 2018-03-08 17:59:21 +01:00
Hans-Kristian Arntzen
8d557d4103 Handle cases where merge selects as also loop merge or continue blocks. 2018-03-08 14:01:10 +01:00
Hans-Kristian Arntzen
922420e346 Disallow arrays and structs from becoming loop variables.
Fixes awkward code-gen issue.
2018-03-07 14:54:11 +01:00
Hans-Kristian Arntzen
2e5d06d1ce
Merge pull request #485 from KhronosGroup/fix-484
Add true FP16 support.
2018-03-07 11:59:12 +01:00
Hans-Kristian Arntzen
47d94ff8d9 Add FP16 to HLSL.
Cannot be used in buffer types, similar to mediump in GLSL.
half is useless, because it's 32-bit in FXC.
2018-03-07 10:21:25 +01:00
Hans-Kristian Arntzen
15a941cd3d Add builtin GLSL functions to blacklist. 2018-03-06 17:37:47 +01:00
Hans-Kristian Arntzen
d9da2db442 Some compat fixes for MSL and Half. 2018-03-06 17:09:18 +01:00
Hans-Kristian Arntzen
24dfe496c2 Run format_all.sh. 2018-03-06 17:09:18 +01:00
Hans-Kristian Arntzen
05348a66ca Add test shader for FP16 support. 2018-03-06 17:09:18 +01:00
Hans-Kristian Arntzen
bc0f698df3 Fix packing alignments for float16. 2018-03-06 17:09:18 +01:00
Hans-Kristian Arntzen
91f85d3412 Begin adding float16_t support to GLSL. 2018-03-06 17:09:18 +01:00
Hans-Kristian Arntzen
294259e2f1 Fix type aliasing on MSL.
Be careful about who gets to be the alias master, and don't alias types
when we have packed types in play.
2018-03-05 16:27:04 +01:00
Hans-Kristian Arntzen
3c1b147272 Support Invariant for BuiltInPosition. 2018-03-01 12:31:39 +01:00
Hans-Kristian Arntzen
e69b1aeed8 Fix implicit conversion bug. 2018-02-26 09:29:18 +01:00
Hans-Kristian Arntzen
fda36f832b Fix function overload when SPIR-V overloads on pointer type. 2018-02-25 10:58:22 +01:00
Hans-Kristian Arntzen
dd603eab58 Support spec constant array size in blocks.
Won't really be correct if the spec constant is changed outside
SPIRV-Cross, but nothing we can do about that, really.
2018-02-23 15:11:45 +01:00
Hans-Kristian Arntzen
a04bdcc7f7 Handle overloaded functions which share the same OpName.
Awkward, but legal SPIR-V.
2018-02-23 14:15:51 +01:00
Hans-Kristian Arntzen
047ad7df0f Support special float constants (NaN/Inf). 2018-02-23 13:06:20 +01:00