Bill Hollings
ed16b3e699
Merge pull request #785 from billhollings/master
...
MSL don't emit memory_scope after MSL 2.0.
2018-12-11 17:57:15 -05:00
Bill Hollings
ab329a7906
MSL don't emit memory_scope
after MSL 2.0.
2018-12-11 16:28:29 -05:00
Bill Hollings
52f26ee736
Merge pull request #782 from cdavis5e/force-signedness-2
...
MSL: Use an enum instead of two mutually exclusive booleans.
2018-12-04 22:02:39 +01:00
Chip Davis
6db79b80c1
MSL: Use an enum instead of two mutually exclusive booleans.
...
NFCI.
2018-12-04 13:54:29 -06:00
Bill Hollings
2cd54e4e6d
Merge pull request #779 from cdavis5e/force-signedness
...
MSL: Force signedness of shader vertex attributes to match the host.
2018-12-04 09:37:55 -05:00
Chip Davis
06d483459b
MSL: Force signedness of shader vertex attributes to match the host.
...
Based on a patch by Stefan Dösinger.
Metal cannot do signedness conversion on vertex attributes, and for good
reason. Putting a `uint4` into an `int4`, or a `char4` into a `uint4`,
would lose those values that are outside the range of the target type.
But putting a `uchar4` into a `short4` or an `int4`, or a `ushort4` into
an `int4`, should work. In that case, force the signedness in the shader
to match the declared type of the host.
Unfortunately, I don't really know how to automatically test this. This
remapping is done based on input parameters normally supplied by
MoltenVK. I'm not sure how we'd set this up for the command-line
`spirv-cross` tool.
2018-11-28 17:53:56 -06:00
Hans-Kristian Arntzen
1830f7ae8b
Merge pull request #778 from KhronosGroup/fix-777
...
Support gl_HelperInvocation on GLSL and MSL.
2018-11-28 17:11:19 +01:00
Hans-Kristian Arntzen
61f1d8b2cf
Support gl_HelperInvocation on GLSL and MSL.
...
There is no obvious builtin for this on HLSL.
2018-11-28 15:18:43 +01:00
Hans-Kristian Arntzen
fbae10db15
Merge pull request #776 from lifpan/master
...
Fix build warning.
2018-11-28 11:34:32 +01:00
lifpan
b21525bcce
Fix build warning.
2018-11-28 14:20:24 +08:00
Hans-Kristian Arntzen
2c029fcd49
Merge pull request #775 from KhronosGroup/fix-746
...
CPP: declare constants.
2018-11-27 12:39:34 +01:00
Hans-Kristian Arntzen
7cb04c7582
CPP: declare constants.
2018-11-27 10:49:19 +01:00
Hans-Kristian Arntzen
84588753dc
Merge pull request #774 from KhronosGroup/fix-770
...
Keep track of pointer-to-pointer depth in parser.
2018-11-26 13:35:27 +01:00
Hans-Kristian Arntzen
d0b937206f
Keep track of pointer-to-pointer depth in parser.
...
Defer failure of pointer-to-pointer to compilation time, so we can still
reflect VK_KHR_variable_pointer shaders.
2018-11-26 12:23:28 +01:00
Hans-Kristian Arntzen
a89ebba827
Merge pull request #772 from KhronosGroup/fix-771
...
Fix unsigned switch case selectors.
2018-11-26 11:24:02 +01:00
Hans-Kristian Arntzen
04f410d35c
Fix unsigned switch case selectors.
2018-11-26 10:36:50 +01:00
Hans-Kristian Arntzen
cd5cdda13d
Merge pull request #769 from KhronosGroup/fix-761
...
Handle invariant decoration more robustly.
2018-11-22 22:30:58 +01:00
Hans-Kristian Arntzen
816c1167ce
Handle invariant decoration more robustly.
...
Avoids certain cases of variance between translation units by forcing
every dependent expression of a store to be temporary.
Should avoid the major failure cases where invariance matters.
2018-11-22 11:55:57 +01:00
Hans-Kristian Arntzen
f247b05ffd
Merge pull request #768 from KhronosGroup/fix-764
...
Remove old hack for dealing with HLSL counter buffers.
2018-11-22 11:17:13 +01:00
Hans-Kristian Arntzen
9aa623a553
Remove old hack for dealing with HLSL counter buffers.
...
No longer needed.
2018-11-22 10:23:58 +01:00
Hans-Kristian Arntzen
2588309290
Merge pull request #763 from trzecieu/patch-2
...
Adding C++ syntax coloring for missed snippet
2018-11-19 10:54:15 +01:00
Piotr Paczkowski (trzeci.eu)
30743aa931
Adding C++ syntax coloring for missed snippet
2018-11-19 10:49:49 +01:00
Hans-Kristian Arntzen
7611dc0967
Merge pull request #762 from trzecieu/patch-1
...
Syntax coloring for C++ snippets in README.md
2018-11-19 10:13:06 +01:00
Piotr Paczkowski (trzeci.eu)
bc6011b512
Syntax coloring for C++ snippets in README.md
2018-11-19 08:52:12 +01:00
Hans-Kristian Arntzen
ea6bdacd05
Merge pull request #760 from KhronosGroup/fix-758
...
Parser: Handle group decorations.
2018-11-15 12:01:51 +01:00
Hans-Kristian Arntzen
fa42ed37ba
Parser: Handle group decorations.
2018-11-15 10:51:52 +01:00
Hans-Kristian Arntzen
e4822981cc
Merge pull request #759 from lifpan/master
...
Handle opcode OpSourceContinued.
2018-11-15 10:09:30 +01:00
Hans-Kristian Arntzen
510e1475c6
Merge pull request #756 from cdavis5e/relaxed-block-layout-2
...
MSL: Also pack 2- and 4- element vectors when necessary.
2018-11-15 10:09:09 +01:00
lifpan
00a765eccf
Handle opcode OpSourceContinued.
2018-11-15 09:04:36 +08:00
Hans-Kristian Arntzen
c2fe5878b4
Merge pull request #757 from cdavis5e/msl-extended-arith
...
MSL: Support extended arithmetic opcodes.
2018-11-14 18:46:07 +01:00
Chip Davis
a5882da091
Test loading from and storing to packed vectors.
2018-11-14 10:47:20 -06:00
Chip Davis
6d675ae6a2
Correct carry/borrow bit checks.
...
Don't use `addsat()`/`subsat()`; that'll erroneously flag cases where
the sum is exactly the maximum integer value, or the difference is
exactly 0. Also, correct the condition for the `select()` function; it's
basically `mix()` with a boolean factor.
(What was I *thinking*?)
2018-11-14 10:13:56 -06:00
Chip Davis
cf2a890e4f
MSL: Support extended arithmetic opcodes.
2018-11-13 17:33:03 -06:00
Chip Davis
bed4918cb5
MSL: Also pack 2- and 4- element vectors when necessary.
...
This is also needed for `VK_KHR_relaxed_block_layout` support.
2018-11-13 17:31:47 -06:00
Hans-Kristian Arntzen
1adaaba74e
Merge pull request #755 from KhronosGroup/fix-740
...
GLSL: Support extended arithmetic opcodes.
2018-11-13 16:54:53 +01:00
Hans-Kristian Arntzen
2a8a4fe706
GLSL: Support extended arithmetic opcodes.
...
- uaddCarry
- usubBorrow
- umulExtended
- imulExtended
2018-11-13 14:50:46 +01:00
Hans-Kristian Arntzen
14a3ce4a20
Merge pull request #754 from lifpan/master
...
Handle opcode OpModuleProcessed.
2018-11-13 09:23:46 +01:00
lifpan
9161096676
Handle opcode OpModuleProcessed.
2018-11-13 14:28:38 +08:00
Hans-Kristian Arntzen
f734d78c15
Merge pull request #750 from KhronosGroup/msl-travis-fix
...
MSL: Split out early_fragment_tests.
2018-11-12 17:14:37 +01:00
Hans-Kristian Arntzen
d6be21543d
MSL: Split out early_fragment_tests.
...
Was causing compilation failures, jumped the merge a bit too soon.
2018-11-12 16:20:49 +01:00
Hans-Kristian Arntzen
be732f5f51
Merge pull request #749 from KhronosGroup/fix-747
...
Deal with depth_greater/depth_less qualifiers.
2018-11-12 13:10:26 +01:00
Hans-Kristian Arntzen
4e5c8d7199
Deal with depth_greater/depth_less qualifiers.
...
Adds support on HLSL SM 5.0, and fixes bug on GLSL.
Makes sure early fragment tests is tested on MSL as well.
2018-11-12 10:35:36 +01:00
Hans-Kristian Arntzen
b778e16e48
HLSL: Complete support for combined image samplers in legacy.
2018-11-12 09:59:39 +01:00
Hans-Kristian Arntzen
e8e7baf1ca
Merge branch 'mgong/CombineOnSM3' of git://github.com/gongminmin/SPIRV-Cross
2018-11-12 09:59:12 +01:00
Minmin Gong
e3ebfdaae5
HLSL: Combine image and sampler on shader model <= 30
2018-11-10 13:44:59 -08:00
Hans-Kristian Arntzen
485eb0fb67
Merge pull request #742 from stenzek/msl-ssign
...
MSL: Emit wrapper for SSign (sign() for int types)
2018-11-08 12:03:56 +01:00
Connor McLaughlin
1dd676c1de
MSL: Emit wrapper for SSign (sign() for int types)
...
Metal does not define the sign() function for integer types, only
floating-point types.
2018-11-08 13:08:34 +10:00
Hans-Kristian Arntzen
cf5e1c2801
Merge pull request #743 from cdavis5e/relaxed-block-layout
...
MSL: Also pack members at unaligned offsets.
2018-11-07 19:38:56 +01:00
Hans-Kristian Arntzen
28a7583cfa
Merge pull request #741 from stenzek/msl-early-fragment-tests
...
MSL: Print early_fragment_tests specifier before fragment
2018-11-07 19:32:37 +01:00
Chip Davis
e50eecfeeb
MSL: Also pack members at unaligned offsets.
...
This is necessary to support `VK_KHR_relaxed_block_layout`.
2018-11-07 09:42:54 -06:00