Граф коммитов

270 Коммитов

Автор SHA1 Сообщение Дата
Ehsan 101730c57b
[spirv] Respect the -auto-binding-space option in SPIR-V backend (#2211)
* [spirv] Respect the -auto-binding-space option in SPIR-V backend.

* [spirv] Use default space if vk::binding doesn't provide dset.

* Address code review comments.
2019-06-04 09:35:04 -04:00
Tex Riddell ba668cf13e Merge remote-tracking branch 'ms/master' into dxil-1-5 2019-05-20 11:49:53 -07:00
alelenv b830b09bc5 [spirv] Add support for [[vk::shader_record_nv]] (#2179)
* Add support for [[vk::shader_record_nv]]

* Fixes after first review of ehsannas.
2019-05-16 00:36:28 -04:00
Jaebaek Seo dd183fec9f
Force cmake to use python3 (#2187)
Force cmake to use python3
2019-05-15 09:56:11 -04:00
Ehsan 5648e43f18
[spirv] Command line option for providing $Globals binding. (#2156) 2019-05-01 18:28:14 -04:00
Tex Riddell faacd80b74
Allow clip/cull elements to be declared as array [2] (#2109)
* Allow clip/cull elements to be declared as array [2]

- This approach fixes validation and packing to handle this case.
- There could be implications to runtime ViewID validation
- fix some issues found in packing related to rowsUsed result from Pack
  functions.  Make these return 0 on failure, instead of startRow.
- Split PackNext into FindNext and PackNext that uses it for greater
  flexibility.
2019-04-10 17:37:47 -07:00
alelenv e58ecd4c2f Add support to convert DXR HLSL to SPV_NV_ray_tracing (#1920)
* Add support to convert DXR HLSL to SPV_NV_ray_tracing

* Fix multiple typos and cleanup using clang-format.

* Update tests to verify transpose and custom matrix type
Update tests to add multple entry functions of same shader stage

* Replace ExecutionModel class with ShaderModel::Kind

- This change removes ExecutionModel class and relies on ShaderModel::Kind to track current entry point shader stage
- Also instead of declaring it in SpirvEmitter, DeclResultIdMapper & GlPerVertex, we declare it only once in common object SpirvContext

* Dont create a stageVar for raytracing interface variables.

* Don't perform 'new' memory allocation for FunctionInfo object

This change also -
- removes invalid "SpirvEmitter::" from function declarations in SpirvEmitter class.
- fix build errors by adding a default constructor in FunctionInfo struct to allow functionInfoMap allocate an empty object for no search results.

* Fix some more typos and fomatting errors.

* Update RST with raytracing stage info

* In SpirvContext.h, replace unsigned by uint32_t

* Test add ascii art and fixup grammar mistakes.

* Use placement new to allocate FunctionInfo objects.

Also bundle the insertion into functionInfoMap and workQueue together.

* Remove outdated comment.

* Update RST with intrinsic mapping and typo fixes.

* Some more wording fixes to RST for raytracing.

* Accidently broke table in RST due to missing '-'

* Add tick marks for supported stages in RST

* Final clang-format formatting fixes.

* Add missing labels to flowchart and spacing.
2019-02-27 09:58:59 -05:00
Justin Holewinski bc72038998 Add support for WaveMatch and WaveMultiPrefix<Op> (#1867)
These new DXIL instructions are added to SM 6.5. The valid operations
for <Op> are:

    - BitAnd
    - BitOr
    - BitXor
    - CountBits
    - Product
    - Sum

In HLSL, these are exposed as:

    uint4 WaveMatch(<type> val)
    <type> WaveMultiPrefixBitAnd(<type> val, uint4 mask)
    <type> WaveMultiPrefixBitOr(<type> val, uint4 mask)
    <type> WaveMultiPrefixBitXor(<type> val, uint4 mask)
    uint WaveMultiPrefixCountBits(bool val, uint4 mask)
    <type> WaveMultiPrefixProduct(<type> val, uint4 mask)
    <type> WaveMultiPrefixSum(<type> val, uint4 mask)

In DXIL, these are exposed as:

    [BitAnd,BitOr,BitXor,Product,Sum]
    %dx.types.fouri32 @dx.op.waveMatch.T(i32 %opc, T %val)
    T @dx.op.waveMultiPrefixOp.T(i32 %opc, T %val, i32 %mask_x,
                                 i32 %mask_y, i32 %mask_y, i32 %mask_z,
                                 i8 %operation, i8 %signed)

    [CountBits]
    i32 @dx.op.waveMultiPrefixBitCount(i32 %opc, i1 %val, i32 %mask_x,
                                       i32 %mask_y, i32 %mask_y,
                                       i32 %mask_z)

Scalarization of vector types occur as per the existing wave intrinsics.
For WaveMatch, the match is performed on each scalar and the results
are combined with bitwise AND. For WaveMultiPrefix, the operation is
performed on each scalar and combined into an aggregate.
2019-02-25 14:42:43 -08:00
Ehsan ebb720ced3
[spirv] Support HLSL 'register(c#)' annotation. (#1912) 2019-02-12 10:07:20 -05:00
Lei Zhang 7a2a95e36c
[spirv] Add support for VK_EXT_scalar_block_layout (#1716)
Ref: https://github.com/KhronosGroup/Vulkan-Docs/issues/854
2018-11-20 11:24:57 -05:00
Tex Riddell ecb4e3b4bb Add SV_ShadingRate plus optional feature flag
- Move/fix flag collection based on signature properties to be computed
  per entry function (including for libraries)
2018-10-22 20:25:12 -07:00
Tex Riddell 79bc013b4d Add dot2add and dot4add_*8packed intrinsics 2018-10-22 20:21:55 -07:00
Steven Perron fe2d48b984 Add the HLSL-spirv cookbook. (#1618)
Add a document to give examples of what HLSL code patterns will generate
valid Vulkan SPIR-V.
2018-10-22 14:22:44 -04:00
Lei Zhang 2ecc36b382
[spirv] Add doc about supported extensions 2018-10-01 14:47:11 -04:00
Tex Riddell 89697bbad5 Merge branch 'master' into dxr-master
# Conflicts:
#	include/dxc/HLSL/DxilUtil.h
#	lib/DxcSupport/HLSLOptions.cpp
#	lib/HLSL/DxilUtil.cpp
#	tools/clang/lib/CodeGen/CGHLSLMS.cpp
#	tools/clang/unittests/HLSL/DxilContainerTest.cpp
2018-09-12 22:28:35 -07:00
Lei Zhang d0fcff32fd
[spirv] Fix doc about half translation (#1539) 2018-09-11 14:49:20 -04:00
Lei Zhang 81b3451b4a
[spirv] Add mechanism for fine-grained control of debug info (#1518)
Added a new command-line option: -fspv-debug=<category>, where
category can be file, source, line, and tool, to give developers
fine-grained control of what debug information they want in
the generated SPIR-V code.
2018-08-29 11:11:30 -04:00
Lei Zhang 4d6e2cfc64
[spirv] Fix array index out of bound in doc (#1516) 2018-08-27 19:40:11 -04:00
Lei Zhang 2b47a4363e
[linux-port] Update on HLSL/DXIL test suite (#1495) 2018-08-09 16:27:16 -04:00
Lei Zhang 05cda8da2a
[spirv] Add support for -fvk-bind-register (#1480)
format: -fvk-bind-register <type-number> <space> <binding> <set>

Also created a short alias for it: -vkbr.

This option gives the ultimate manual control of descriptor
assignment. It requires:

* All resources are annotated with :register() in the source code
* -fvk-bind-register is specified for every resource

It overrules all other mechanisms.
It cannot be used together with -fvk-{u|b|s|t}-shift.
2018-08-03 07:36:18 -04:00
Lei Zhang 474954a6ea
[spirv] Update mapping manual w.r.t. debugging and options (#1475) 2018-08-01 10:49:51 -04:00
Ehsan 90103b38c2
[spirv] Expose -Oconfig for running custom optimizer recipes (#1466) 2018-07-31 13:49:19 -04:00
Tex Riddell 2f5afecf67 Merge remote-tracking branch 'ms/master' into user/texr/integrate-master 2018-07-30 15:36:07 -07:00
Ehsan f9882c84a7
[spirv] Support for post_depth_coverage extension. (#1461) 2018-07-27 17:16:41 -04:00
Tex Riddell 2330c74b1a Merge remote-tracking branch 'ms/master' into user/texr/integrate-master
# Conflicts:
#	tools/clang/tools/dxcompiler/dxcompilerobj.cpp
#	tools/clang/unittests/HLSL/ValidationTest.cpp
#	tools/clang/unittests/HLSL/VerifierTest.cpp
2018-07-26 17:17:36 -07:00
Tex Riddell ec4219002e Merge branch 'rtmaster' into user/texr/integrate-master 2018-07-26 16:07:02 -07:00
Tex Riddell fec1adb90e Merged PR 110: Validate raytracing shader properties and RDAT blob part
Validate raytracing shader properties and RDAT blob part

- no signatures for ray tracing shader functions
- payload/params/attribute sizes are >= argument type allocation sizes
- RDAT is bit-identical to RDAT generated
- Minor fix for CS: should not have input signature elements either.
- update val version comment
- Prevent strange behavior with library target and entry point not empty.
- remove DXASSERT in LoadDxilMetadata (validation should catch this case)
2018-07-26 22:44:51 +00:00
Tex Riddell 7fe628800d Merged PR 108: Validate function params for libraries.
Validate function params for libraries.
2018-07-25 19:02:59 +00:00
Lei Zhang f40667e931
[spirv] Rename -fvk-invert-w to -fvk-use-dx-position-w (#1448) 2018-07-24 20:46:14 -04:00
Lei Zhang dbc67dc4f4
[spirv] -fvk-invert-w in non-PS stages is no-op (#1441)
Allow using -fvk-invert-w in non-PS stages and make it a no-op.
2018-07-21 06:57:55 -04:00
Xiang_Li (XBox) 94157e54ab Merged PR 105: update handle validation.
update handle validation.
2018-07-21 01:54:30 +00:00
Lei Zhang ef6c9eff15
[spirv] Add -fvk-invert-w (#1429)
This option reciprocates (multiplicatively inverts) SV_Position.w
after reading it from stage input in PS. This is used to accommodate
the difference between Vulkan and DirectX.
2018-07-19 10:34:51 -04:00
Tex Riddell 95c382de3f Merge branch 'master' into user/texr/integrate-master
# Conflicts:
#	lib/HLSL/DxilContainerReflection.cpp
#	tools/clang/tools/CMakeLists.txt
#	tools/clang/unittests/CMakeLists.txt
2018-07-13 15:01:10 -07:00
Ehsan 18545516b0
[spirv] Handle CalculateLevelOfDetailUnclamped. (#1400) 2018-07-04 15:55:21 -04:00
Lei Zhang ed29623d9a
[spirv] Handle nested structs for [[vk::offset]] (#1399)
Also update the SPIR-V doc about [[vk::offset]
2018-07-04 10:58:35 -04:00
Lei Zhang 3987db0fa8
[spirv] Do not build tests by default and hook up with ctest (#1394)
This way we can just run ctest to invoke the tests, instead of
remembering the binary and its parameters.
2018-06-29 12:46:07 -04:00
Ehsan 579b9c656f
[linux-port] Add documentation file for Linux/macOS port. (#1389) 2018-06-28 16:34:07 -04:00
Xiang_Li (XBox) 4ade2fccc0 Merged PR 92: Enable ValidateResourceDxilOp for lib profile.
Enable ValidateResourceDxilOp for lib profile.
2018-06-20 18:53:19 +00:00
Tex Riddell d37f956c70 Merged PR 86: Finalize OpCode changes for Dxil 1.3 / SM 6.3
Finalize OpCode changes for Dxil 1.3 / SM 6.3

- Rename CreateHandleFromResourceStructForLib to CreateHandleForLib
- Add PrimitiveIndex
- Add final NumOp[Codes|Classes]_Dxil_1_3 values
- Fix legal shader stage set for PrimitiveID
2018-06-09 00:22:19 +00:00
Tex Riddell a26681c807 Merge branch 'master' into rtmaster
# Conflicts:
#	lib/HLSL/DxilGenerationPass.cpp
#	lib/HLSL/DxilValidation.cpp
#	tools/clang/tools/dxcompiler/dxclinker.cpp
2018-05-22 20:52:03 -07:00
Lei Zhang 8c6d72a2a7
[spirv] Add option to ignore warnings on features without Vulkan support (#1289)
Added -Wno-vk-ignored-features to suppress warnings on features
that are ignored because of no Vulkan support. Examples include
cbuffer member initializer.
2018-05-16 14:32:30 -04:00
Lei Zhang babfc756c3
[spirv] Convert to use 2 as the depth value for OpTypeImage (#1261)
2 means no indication as to whether this is a depth or non-depth
image.

Reverted "Hack OpSampledImage for depth-comparison sampling".

This reverts commit 0f165c6483.
2018-05-11 10:57:26 -04:00
Lei Zhang 4dd7aee306
[spirv] Add doc about synchronization intrinsics (#1263) 2018-05-08 13:18:28 -04:00
Lei Zhang a1a33a4199
[spirv] Convert to use stand-alone variables for gl_PerVertex (#1259)
It's actually a spec reading issue that it seems we cannot
have stand-alone variables for Position, PointSize, ClipDistance,
or CullDistance in HS/DS/GS.

Removed all code regarding Position and PointSize from GlPerVertex.
We still need to keep GlPerVertex aroudn to handle ClipDistance
and CullDistance though.
2018-05-07 10:21:20 -04:00
Lei Zhang 2095fef62c
[spirv] Add support for arrays of structured/byte buffers (#1257)
They are translated into, of course, (runtime) arrays of
structured/byte buffers.
2018-05-03 13:36:09 -04:00
Lei Zhang 9b856626d6
[spirv] Add support for dual-source blending (#1251)
In HLSL, dual-source color blending is enabled only via API;
the shader needs no special marks: it only writes SV_Target0
& SV_Target1 like normal.

But in Vulkan, to enable dual-source blending, the shader need
to mark the two participating output variables with Index = 0
and Index = 1, respectively.

So we introduce a new attribute, vk::index(), to let developers
to specify the index of an output variable so dual-source
blending can be enabled.

See Vulkan spec "26.1.2. Dual-Source Blending".
2018-04-26 16:02:12 -04:00
Lei Zhang 23be4804b6
[spirv] Remove -fvk-ignore-unused-resources (#1246) 2018-04-24 14:47:28 -04:00
Tex Riddell 5ab102a352 Merge branch 'master' into rtmaster 2018-04-16 15:25:53 -07:00
Lei Zhang 4491a30fba
[spirv] Support non-constant offsets in .Gather*() methods (#1232)
They are emulated via 4 separate OpImage*Gather instructions.
2018-04-16 17:21:02 -04:00
Lei Zhang 4ac938cc5b
[spirv] Clarify doc about SPIR-V target environment (#1230) 2018-04-16 17:16:07 -04:00
Lei Zhang a4491dd439
[spirv] Support shifting all sets with -fvk-*-shift N all (#1224) 2018-04-13 15:40:44 -04:00
Young Kim 0777a7a020 Merge branch 'master' into rtmaster 2018-04-10 16:47:47 -07:00
Lei Zhang 0a8b8c4e1d
[spirv] Rename -fvk-use-glsl-layout to -fvk-use-gl-layout (#1206)
GLSL as a shading language does not define the layout rules for
std140/std430; the OpenGL graphics environment defines that.

This is also more consistent with -fvk-use-dx-layout.
2018-04-10 10:25:26 -04:00
Lei Zhang 99c142be0b
[spirv] Add support for DX layout rules (#1198)
These layout rules can be turned on with -fvk-use-dx-layout.
For both cbuffer/tbuffer and structured buffers.
2018-04-08 12:50:57 -04:00
Ehsan 68984b316a
[spirv] Specify "KHR" to enable all KHR extensions (#1195) 2018-04-03 15:21:23 -04:00
Ehsan 2a0b7c49fd
[spirv] Add -fspv-target-env command line option. (#1187)
* [spirv] Add -fspv-target-env command line option.

The valid values for this option currently are:
vulkan1.0
vulkan1.1

If no target environment is specified, vulkan1.0 is used as default.
2018-04-03 09:12:51 -04:00
Young Kim fd54e1927c
Update docs (#1046) 2018-03-29 17:08:55 -07:00
Lei Zhang 241d32c810
[spirv] Allow explicitly controlling SPIR-V extensions (#1151)
Added FeatureManager to record all extensions specified from
the command-line and emit error if trying to use one not permitted.

Added command-line option -fspv-extension= to specify
whitelisted extensions.
2018-03-27 17:42:16 -04:00
Ehsan c66c37cfa1
[spirv] Add support for DeviceIndex builtin. (#1171) 2018-03-23 10:40:02 -04:00
Lei Zhang 66a8998f87
[spirv] Translate SV_InnerCoverage into FullyCoveredEXT (#1165)
Fixes https://github.com/Microsoft/DirectXShaderCompiler/issues/999
2018-03-22 10:08:43 -04:00
Lei Zhang 9b0167be56
[spirv] Add support for :packoffset() (#1156) 2018-03-20 12:18:31 -04:00
Lei Zhang 0d8a15a61a
[spirv] Better reflection support via new extensions (#1111)
This commit uses the HlslCounterBufferGOOGLE decoration to link
the main RW/Append/Consume StructuredBuffer with its associated
counter buffer. It also uses HLSLSemanticGOOGLE to decorate
stage IO variables with their semantic strings from the source code.
2018-03-17 13:05:31 -04:00
Lei Zhang cfd787a18e
[spirv] Cull RHS of shift operations (#1148)
In SPIR-V, if shifting a value by an amount that is greater than
the value's bitwidth, the result is undefined.

FXC and DXC/DXIL performs a bitwise and over the RHS of the shift
operation to only consider its (n - 1) least significant bits,
where n is the bitwidth of LHS.
2018-03-16 20:19:20 -04:00
Lei Zhang f6f79e744d
[spirv] Emit OpSource debug instruction (#1145) 2018-03-16 13:40:00 -04:00
Lei Zhang e3662ff353
[spirv] Collect global non-resource variables into $Globals (#1138)
This commit changes the behavior of how to handle externally-visiable
non-resource-type stand-alone variables. Previously they are emitted
as stand-alone SPIR-V variables. Now they are grouped into a cbuffer
that named as $Globals. This is more aligned with how DirectX handles
them.
2018-03-14 11:15:14 -04:00
Lei Zhang c133d935eb
[spirv] Support SM6.0 wave ops using Vulkan 1.1 (#1118)
Support promoting to SPIR-V 1.3 when necessary

Support SM6.0 wave query and vote ops

* WaveIsFirstLane
* WaveGetLaneCount
* WaveGetLaneIndex
* WaveActiveAnyTrue
* WaveActiveAllTrue
* WaveActiveBallot

Support SM6.0 wave reduction ops

* WaveActiveAllEqual
* WaveActiveCountBits
* WaveActiveSum
* WaveActiveProduct
* WaveActiveBitAnd
* WaveActiveBitOr
* WaveActiveBitXor
* WaveActiveMin
* WaveActiveMax

Support SM6.0 wave scan/prefix ops

* WavePrefixSum
* WavePrefixProduct
* WavePrefixCountBits

Support SM6.0 wave broadcast ops

* WaveReadLaneAt
* WaveReadLaneFirst

Support SM6.0 quad-wide shuffle ops

*  QuadReadAcrossX
*  QuadReadAcrossY
*  QuadReadAcrossDiagonal
*  QuadReadLaneAt
2018-03-13 15:24:48 -04:00
Lei Zhang c859bb040f
[spirv] Support SPV_KHR_shader_draw_parameters (#1127)
Added support for the following SPIR-V builtins exposed in
SPV_KHR_shader_draw_parameters:
* BaseVertex
* BaseInstance
* DrawIndex
2018-03-13 10:07:54 -04:00
Tex Riddell cb5f27c080 Merge branch 'master' into user/texr/rt-merge-rebase 2018-03-12 13:11:12 -07:00
Lei Zhang 26bf35450a
[spirv] Update doc about reflection (#1130) 2018-03-12 11:32:00 -04:00
Lei Zhang 70990344ed
[spirv] Implement relaxed layout for vector types (#1092)
Based on GLSL std140/std430 layout rules, relaxed layout allows
using vector's element type's alignment as the vector types's
alignment, so that we can pack a float value and a float3 value
tightly. This is the default right now.

Also add an option, -fvk-use-glsl-layout, to turn off the relaxed
layout for vectors and use conventional GLSL std140/std430 layout
rules.
2018-03-12 10:21:54 -04:00
Tex Riddell f8e1af0417 Merge branch 'master' into user/texr/rt-merge-rebase 2018-03-09 00:55:21 -08:00
Lei Zhang 451d095898
[spirv] Update doc about texture concepts (#1123) 2018-03-08 12:11:09 -05:00
Ehsan b02d940813
[spirv] Don't emit Float16 capability. (#1109)
Capability Float16 is not allowed by Vulkan 1.0 specification.
SPV_AMD_gpu_shader_half_float should be used if 16bit floats are used.
2018-03-06 11:25:20 -05:00
Lei Zhang c1ea245a16
[spirv] Add support for WaveReadLineFirst() (#1106) 2018-03-01 15:48:09 -05:00
Young Kim 81ecfef34b
Fix denorm preserve division with high value of denominator (#1093) 2018-03-01 07:41:10 -08:00
Lei Zhang c8970cdf6b
[spirv] Ignore static when seeing both static and groupshared (#1101) 2018-02-28 12:12:13 -05:00
Tex Riddell 914c040b14 Merged PR 26: Fix intrinsic names to match spec.
Fix intrinsic names to match spec.

- PrimitiveIndex still maps to low level dx.op.primitiveID
2018-02-21 21:51:20 +00:00
Lei Zhang 5c4ca12efc
[spirv] Update doc and SPIRV-Tools (#1088)
Add explanation of legalization, optimization, validation in doc.
2018-02-21 14:12:01 -05:00
Lei Zhang 4221a698e1
[spirv] Support WaveGetLaneCount() and WaveGetLaneIndex() (#1077)
They are translated into SPIR-V builtin varibles. The translation
requires the SPV_KHR_shader_ballot extension.
2018-02-21 10:34:01 -05:00
Tex Riddell 7d145d64d5 Merge branch 'master' into user/texr/rt-merge-rebase 2018-02-12 17:51:50 -08:00
Ehsan 774e85eb20 [spirv] Add initial support for non-fp matrices (#1057)
This is the support for non-floating-point matrices,
which are emulated using arrays of vectors because
SPIR-V does not allow non-floating-point matrices.

* Initial support for non-fp matrix
* Add support for non-fp matrix in all()
* Conversion of float matrix to int matrix
* support for modf returning an int matrix
* Add tests for non-fp matrix access
* Mixed arithmetic for non-fp matrices
* Support non-fp matrix in flat conversion
* Non-fp matrix in asint/asuint/asfloat
* Mul of non-fp Matrix with Vector/Scalar
* Add tests for non-fp matrix cast

TODO: Layout decoration of non-fp matrices
TODO: Majorness of non-fp matrices
2018-02-12 15:33:41 -05:00
Xiang Li fdf2c31ca6 1. Fix IgnoreHit and AcceptHitAndEndSearch.
2. Support init list for RayDesc.
3. Remove range_id for lib.
4. Update some test.
2018-02-05 18:51:47 -08:00
Xiang Li 519938f12e Lower HLCreateHandle into CreateHandleFromResourceStructForLib. 2018-02-05 17:54:07 -08:00
Xiang Li c45aa784ac Add AcceptHitAndEndSearch, CallShader, CommitHitAndStopRay and change ReportIntersection into ReportHit.
Also change RayTracingAccelerationStructure into RaytracingAccelerationStructure.
2018-02-05 17:54:06 -08:00
Xiang Li eb4b0ae768 Support user define type for dxil operation.
Add RayTracingAccelerationStructure to dxil resource.
Lower ReportIntersection and TraceRay.
2018-02-05 17:54:05 -08:00
Lei Zhang 240a5d8e7f
[spirv] Wrap global matrix variables in structs (#1050)
According to HLSL doc, "variables that are placed in the global scope
are added implicitly to the $Global cbuffer, using the same packing
method that is used for cbuffers."

But we emit all global variables as stand-alone SPIR-V variables.
This causes issues for matrix variables since we cannot annotate
them with majorness decoration anymore.

Wrap global matrix variables in a struct to solve the problem.
2018-02-02 12:44:48 -05:00
Ehsan d7e95a7f3c
[spirv] Explain reasoning of matrix representation (#1048) 2018-02-01 15:21:17 -05:00
Lei Zhang 14c3c0d92c
[spirv] Add initial support for specialization constant (#1009)
This commit add support for generating OpSpecConstant* instructions
with SpecId decorations. Spec constants are only allowed to be of
scalar boolean/integer/float types. Using spec constant as the array
size does not work at the moment.
2018-01-22 15:36:14 -05:00
Lei Zhang 4cbada6181
[spirv] Translate SubpassInput(MS) and their methods (#1013) 2018-01-22 10:45:56 -05:00
Lei Zhang 6af2a123d8
[spirv] Add support for .GetSamplePosition() (#1008)
This only supports .GetSamplePosition() for standard sample
positions, i.e., sample count is 1, 2, 4, 8, or 16. For other
cases, the method will just return float2(0, 0).
2018-01-19 16:00:23 -05:00
Lei Zhang f9d613b795
[spirv] Add support for -fvk-invert-y (#967)
This is to accommodate Vulkan's coordinate system, which is different
from DX's.
2018-01-08 11:42:47 -05:00
Ehsan eeab612da9
[spirv] 16-bit and 64-bit int, uint, and float. (#966)
* [spirv] 16-bit and 64-bit int, uint, and float.

* Added Int64, Uint64, Int16, Uint16.
* Added 16-bit float constants.
* Get the -enable-16bit-types cmd option.
* Add tests for constant Int64/Uint64/Int16/etc.
2018-01-05 16:52:15 -05:00
Lei Zhang d39c94c56f
[spirv] Emit warning for packoffset (#951)
We do not support packoffset right now. Emit warning and ignore it.
2018-01-03 10:13:04 -05:00
Lei Zhang cf39455abf
[spirv] Update doc about variable storage classes (#945) 2017-12-20 18:34:25 -05:00
Xiang Li b816c124f1
Support resource select for lib profile. (#940) 2017-12-20 10:47:29 -08:00
Ehsan fc52dbced0
[spirv] Document missing pow2 partitioning feature. (#937)
* [spirv] Document missing pow2 partitioning feature.
* Provide more accurate location for attributes.
2017-12-19 13:37:48 -05:00
Ehsan cb4e570b82
[spirv] warn {row|col}_major on standalone matrix. (#935) 2017-12-18 16:48:16 -05:00
Ehsan 1d4509f35d
[spirv] Support Load methods that take Status arg. (#905) 2017-12-12 17:38:30 -05:00
Ehsan 679b7c80c7
[spirv] Support CheckAccessFullyMapped intrinsic. (#897) 2017-12-11 14:02:21 -05:00
Lei Zhang 5de265fddb
[spirv] Add support for ignoring unused resources (#875)
Added a new command line option -fvk-ignore-unused-resources
to avoid emitting SPIR-V code for resources defined but not statically
referenced by the call tree of the entry point in question.
2017-12-05 12:21:55 -05:00