Commit Graph

3506 Commits

Author SHA1 Message Date
手机用户Xh2vb13n
d1ac6524d3
HLSL: support Texture2D::GatherCmp function
refer to https://learn.microsoft.com/en-us/windows/win32/direct3dhlsl/sm5-object-texture2d-gathercmp
2023-04-10 16:55:38 +08:00
Hans-Kristian Arntzen
3327924add
Merge pull request #2130 from KhronosGroup/fix-2129
GLSL: Fix expression reorder bug with legacy FMA fallback.
2023-03-30 18:25:35 +02:00
Hans-Kristian Arntzen
abd23cc233
Merge pull request #2127 from attackgoat/aliased-descriptor-fix
Aliased descriptor fix
2023-03-30 18:01:09 +02:00
Hans-Kristian Arntzen
50623e13c8 GLSL: Fix expression reorder bug with legacy FMA fallback. 2023-03-30 17:24:11 +02:00
John Wells
4c622ce030 Revert "Make argument buffer padding testable"
This reverts commit 275e4d7e88.
2023-03-30 11:13:39 -04:00
John Wells
275e4d7e88 Make argument buffer padding testable 2023-03-29 21:55:32 -04:00
Hans-Kristian Arntzen
8e64f8ee40
Merge pull request #2123 from piegfx/main
Implement set_scalar functions in the specialization constants C API
2023-03-29 20:36:10 +02:00
John Wells
42a89a5885 Add code braces 2023-03-29 13:52:42 -04:00
Skye
a3b5cdc519 update f32 to u32 2023-03-28 16:47:43 +01:00
Skye
f3d05a5aad
Merge branch 'KhronosGroup:main' into main 2023-03-28 16:46:03 +01:00
John Wells
e31deb8340 Fix for typo in help 2023-03-23 19:05:12 -04:00
John Wells
4a4ac7f946 Fix for argument buffer index compare when invalid 2023-03-23 19:04:50 -04:00
Hans-Kristian Arntzen
09e60d74f6
Merge pull request #2124 from Try/hlsl-task-shader
HLSL: Add task(amplification) shader support
2023-03-22 12:36:47 +01:00
Try
cb45e4be6f cleanup 2023-03-21 21:11:07 +01:00
Try
4a5d21bf1c virtual emit_mesh_tasks 2023-03-21 21:08:59 +01:00
Hans-Kristian Arntzen
763dbe14ab
Merge pull request #2125 from gulfemsavrun/main
Add missing <exception> include
2023-03-21 12:56:03 +01:00
Hans-Kristian Arntzen
8c509fec7b HLSL: Update rayquery reference. 2023-03-21 12:23:40 +01:00
Hans-Kristian Arntzen
202bf05386 Merge branch 'hlsl_fix_hit_t_arg' of https://github.com/skkkksdkfak/SPIRV-Cross 2023-03-21 12:21:47 +01:00
Gulfem Savrun Yeniceri
a25d0acaad Add missing <exception> include
https://reviews.llvm.org/D146097 removed the transitive include for
<exception>, which caused the following issue:

In file included from ../../third_party/spirv-cross/spirv_common.hpp:28:
../../third_party/spirv-cross/spirv_cross_containers.hpp:334:9: error:
no member named 'terminate' in namespace 'std

This patch adds the missing include to fix the issue.
2023-03-20 20:50:03 +00:00
Try
7ac2c84ff3 code-style 2023-03-18 19:50:28 +01:00
Try
dd8839c6f9 task shader initial 2023-03-18 17:20:16 +01:00
Skye
0c1302bb4e bumped version, corrected function signatures 2023-03-17 17:49:08 +00:00
Skye
5ca8266e58 Implement setscalar fns for all getscalar fns 2023-03-16 19:09:55 +00:00
Hans-Kristian Arntzen
d26c233e1c
Merge pull request #2121 from Keenuts/licenses
adds Khronos license to LICENSES folder.
2023-03-13 17:22:12 +01:00
Nathan Gauër
0d8cfdb4f0 revert trailing space fix 2023-03-13 15:41:15 +01:00
Nathan Gauër
ada706403d applying pr feedback 2023-03-13 14:01:13 +01:00
Nathan Gauër
2d598f29c0 try adding SPDX notice 2023-03-09 18:23:49 +01:00
Nathan Gauër
46a7ce8d72 adds Khronos license to LICENSES folder.
This license is in spirv.h, but absent from the LICENSES file.
2023-03-09 17:03:53 +01:00
Hans-Kristian Arntzen
7512345f61
Merge pull request #2110 from EpicGames/fixes_glsl
GLSL: Don't create temporaries for sampled image types in GLSL.
2023-02-27 20:36:36 +01:00
Laura Hermanns
83650af3fb GLSL: Don't create temporaries for sampled image types in GLSL.
This fixes a bug that was exposed when targeting GLSL with
Vulkan semantics while 'force_temporary' is enabled.
2023-02-27 11:51:49 -05:00
skkkksdkfak
f086cd021e Fix argument for CommitProceduralPrimitiveHit. 2023-02-24 11:00:41 +01:00
Hans-Kristian Arntzen
3550a54ae0
Merge pull request #2105 from goki/main
add support for OpAtomicFAddEXT atomic add, and also Min, Max
2023-02-21 13:05:31 +01:00
Randall C. O'Reilly
c76111f22e cleaner version check 2023-02-20 04:41:28 -08:00
Hans-Kristian Arntzen
5e51297118
Merge pull request #2108 from cdavis5e/msl-duplicate-spec-id
MSL: Deduplicate function constants.
2023-02-20 12:56:25 +01:00
Randall C. O'Reilly
29f959db67 update msl_compiler_supports_version to work with metal 3.0 2023-02-18 03:10:58 -08:00
Chip Davis
41007cdc7d MSL: Deduplicate function constants.
It is possible in SPIR-V to declare multiple specialization constants
with the same constant ID. The most common cause of this in GLSL is
defining a spec constant, then declaring the workgroup size to use that
spec constant by its ID. But, MSL forbids defining multiple function
constants with the same function constant ID. So, we must only emit one
definition of the actual function constant (with the
`[[function_constant(id)]]` attribute); but we can point the other
variables at this one definition.

Fixes three tests in the Vulkan CTS under
`dEQP-VK.compute.basic.max_local_size_*`.
2023-02-17 10:43:50 -08:00
Randall C. O'Reilly
8e20860b9e added tests and added msl3 to test_shaders.py 2023-02-15 00:04:44 -08:00
Randall C. O'Reilly
bff7680cc4 revert FMinEXT, FMaxExt 2023-02-14 16:43:50 -08:00
Randall C. O'Reilly
c4b7ec105d add OpAtomicFMinEXT and Max as well, while we're at it -- I didn't test those but presumably work the same. 2023-02-04 21:52:07 -08:00
Randall C. O'Reilly
a57dba530c add support for OpAtomicFAddEXT atomic add on float types, now avail in metal 3.0 2023-02-04 21:47:08 -08:00
Hans-Kristian Arntzen
4e2fdb2567
Merge pull request #2104 from Ravbug/fix-int-sm6.7
Support integer samplers in Shader Model 6.7
2023-02-03 17:05:31 +01:00
Hans-Kristian Arntzen
388431604a
Merge pull request #2103 from cdavis5e/msl-sample-dref-lod-array-workaround
MSL: Add a workaround for broken `level()` arguments.
2023-02-03 16:36:44 +01:00
Chip Davis
e8d419854f MSL: Add a workaround for broken level() arguments.
Some Metal devices have a bug with depth array textures using comparison
with explicit LoD, where the LoD given will be biased by some amount.
For these devices, we can use a gradient instead, which does not exhibit
this problem. As with the fragment demote workaround, this is only
expected to be needed until the bug is fixed in Metal.
2023-02-02 22:01:46 -08:00
Ravbug
36691f902c Check for SM < 6.7 2023-02-02 12:42:17 -05:00
Hans-Kristian Arntzen
459fa67937
Merge pull request #2101 from rdb/glsl-fix-missing-qualifier
GLSL: Fix missing precision qualifier in spvDeterminant return value
2023-02-02 11:26:06 +01:00
rdb
c356dd6220 GLSL: Fix missing precision qualifier in spvDeterminant return value
Follow-up to #2100
2023-01-27 21:44:47 +01:00
Hans-Kristian Arntzen
199d0cb8a9
Merge pull request #2100 from rdb/glsl-matrix-polyfills
GLSL: Add matrix inverse/determinant polyfills, outerProduct()
2023-01-27 14:37:45 +01:00
rdb
20981666cc GLSL: Legacy matrix inverse/determinant polyfills, outerProduct()
Also refactors polyfill mechanism in GLSL and fixes transpose() lowering precision.
2023-01-27 13:51:47 +01:00
Hans-Kristian Arntzen
86a985f28c
Merge pull request #2093 from rdb/emulate-unsupported-hyperbolic-funcs
GLSL/HLSL: Add emulated fallbacks for hyperbolic math functions
2023-01-27 12:15:28 +01:00
Hans-Kristian Arntzen
cd612e7dde
Merge pull request #2090 from rdb/glsl-legacy-math-funcs
GLSL: Add support for trunc, modf, isnan and isinf in legacy GLSL
2023-01-27 12:13:14 +01:00