Tex Riddell
ef8a94b23f
Don't directly lower patch constant signatures (indirect through HS)
...
- likely bug still where multiple HS share patch constant function
2018-02-05 17:54:08 -08:00
Tex Riddell
03179abb36
Skip HL intrinsic function defs (createhandle) in HLMatrixLowerPass
2018-02-05 17:54:08 -08:00
Tex Riddell
456a78da3a
Remove transpose during library arg translation of matrix load/store
...
(should be present already if necesssary)
2018-02-05 17:54:07 -08:00
Tex Riddell
ee190f6357
Update lib_rt test to remove prototype declarations.
2018-02-05 17:54:07 -08:00
Xiang Li
519938f12e
Lower HLCreateHandle into CreateHandleFromResourceStructForLib.
2018-02-05 17:54:07 -08:00
Tex Riddell
15cd5f16e6
Matrix lowering for functions with UDT params preserved.
...
- Keep track of patch constant functions for later identification
- functions that require input/output signature processing identified
with IsEntryThatUsesSignatures
- update lib_rt.hlsl intrinsics and naming
2018-02-05 17:54:07 -08:00
Xiang Li
1c8218861a
Lower ObjectToWorld and WorldToObject.
2018-02-05 17:54:07 -08:00
Xiang Li
69bc49ffe4
Support System Value retrieval functions.
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
Xiang Li
b9ec4014d0
Add res type map for RayTracingAccelerationStructure.
2018-02-05 17:54:05 -08:00
Xiang Li
bc2e19b771
Support TraceRay and ReportIntersection which has user-define param at front-end.
2018-02-05 17:54:04 -08:00
Tex Riddell
2ae113596a
HLMatrixLower: Handle unflattened lib function matrix return val and param.
2018-02-05 17:52:21 -08:00
Tex Riddell
ea73161d6f
In SROAHLSL undo change to legalize input/output condition.
2018-02-05 17:52:21 -08:00
Tex Riddell
88ec4ea96b
Add BitCastValueOrPtr or UserCall utility funcs for HLMatrixLowerPass.
2018-02-05 17:52:21 -08:00
Tex Riddell
e286979310
Change HLMatrixLowerPass::matToVecMap key from Instruction* to Value*.
2018-02-05 17:52:21 -08:00
Tex Riddell
20bf20391a
Skip flattening for library function parameters or modifying return value.
2018-02-05 17:52:21 -08:00
Tex Riddell
24624613d1
Modify linker passes for function parameter simplification after inlining.
2018-02-05 17:52:21 -08:00
Tex Riddell
9a3bbb6603
Support SV_RayPayload and SV_IntersectionAttributes
2018-02-05 17:52:21 -08:00
Tex Riddell
69a7d31e7c
Add test for RT targets in lib
2018-02-05 17:52:21 -08:00
Tex Riddell
e67ee2ae17
Treat RT entry like export - flatten params and don't clone
2018-02-05 17:52:21 -08:00
Tex Riddell
e9ce3e97d1
Add RT shader types for function attribution in lib target.
2018-02-05 17:52:21 -08:00
Jeff Noyle
bd399a59f4
Remove no-longer-needed stream-out and RTV tracking ( #1053 )
...
* Remove no-longer-needed stream-out and RTV tracking
* restore similar enum to match PIX to reduce confusion
2018-02-05 16:44:59 -08:00
Lei Zhang
1f1ea2b7f5
[spirv] Avoid getting constant zero for static resources ( #1056 )
...
For static resources not explicitly initialized, we cannot initialize
them since there are no meaningful zero values. Just do nothing.
Fixes https://github.com/Microsoft/DirectXShaderCompiler/issues/1055
2018-02-05 17:00:27 -05: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
Lei Zhang
7a86911302
[spirv] Add support for casting from derived to base ( #1052 )
...
This is for the explicit (Base)derived kind of cast.
2018-02-02 12:41:33 -05:00
Lei Zhang
67770e37d4
[spirv] Use invalid instruction replacement legalization pass ( #1051 )
2018-02-02 12:20:34 -05:00
Lei Zhang
9503f80c18
Carry BasePath within CK_HLSLDerivedToBase casts ( #1047 )
...
This will enable us to trace back the whole base chain.
2018-02-02 08:26:39 -05:00
Lei Zhang
cb47cfd0af
[spirv] Initialize isSpecConstant_ in SpirvEvalInfo ( #1049 )
2018-02-01 16:12:01 -05:00
Ehsan
d7e95a7f3c
[spirv] Explain reasoning of matrix representation ( #1048 )
2018-02-01 15:21:17 -05:00
Lei Zhang
eefa2ffa88
Add missing entry for HLSLDerivedToBase in getCastKindName() ( #1045 )
2018-01-31 17:21:53 -05:00
Tex Riddell
c225dead63
Merge types in linker, and recognize class.matrix.* type for library. ( #1033 )
2018-01-31 13:47:05 -08:00
Tex Riddell
acf2bc48d9
Set !dx.valver in Linker ( #1031 )
2018-01-31 13:45:54 -08:00
Lei Zhang
88b02078a1
[spirv] Accept array types for PS stage input variables ( #1044 )
...
We need to check the element types of PS input variables to
properly apply interpolation decorations. Previously the method
used to query element type does not support array types, which
caused an assertion eventually.
2018-01-31 12:31:15 -05:00
Lei Zhang
a7aaccef9f
[spirv] Support OO inheritance in GS stage IOs ( #1043 )
...
We have special handling of the extra level of arrayness and
different code path for emitting vertices in GS.
2018-01-31 11:33:00 -05:00
Ehsan
d47339e142
[spirv] Handle literal float type in getValueOne() ( #1040 )
2018-01-31 10:25:38 -05:00
Young Kim
6f2aaa6ab3
Preserve denorms for frc on half inputs, and fix sqrt(-denorm) for float ( #1042 )
2018-01-30 16:52:58 -08:00
Lei Zhang
902b1ee3c1
[spirv] Handle OO inheritance in stage IOs ( #1041 )
...
We need to go over all base classes and handle stage IOs inside
them too.
2018-01-30 19:33:13 -05:00
Young Kim
1e97116e9f
Fix countbits, reversebits, firstbitlow intrinsics for int16 types ( #1037 )
...
Fix countbits, reversebits, firstbitlow intrinsics for int16 types
2018-01-30 14:29:10 -08:00
Young Kim
d5d3d8d49a
Fix Shader Model 6.2 tests ( #1036 )
...
Fixing a bunch of SM 6.2 Tests
- BinaryHalfOp tests reading input2 instead of input1
- Fixed converting signed zero from float to float16
- Fixed compiler options for float16 min,max test
- Fixed expected results for following float16 operations
- cos(0), sin(314), sin(-314)
- frc(-7.39)
- rsqrt(65504)
- int16 subtraction
- int16 unsigned multiplication
- sqrt, rsqrt, round_pi, round_ni, fmad treat denorm as it is
2018-01-30 14:28:49 -08:00
Lei Zhang
e9120a1594
[spirv] Add support for OO inheritance ( #1039 )
...
An field will be created at the very beginning of the struct
for the base class.
2018-01-30 15:50:42 -05:00
Lei Zhang
d90f31f177
[spirv] Support assigning arrays as a whole ( #1038 )
...
For array wholesale assignments, the rhs will be wrapped in a
FlatConversion implicit cast. This cast can be ignored since it
does not affect CodeGen.
2018-01-30 14:09:26 -05:00
Lei Zhang
d81941c4cb
[spirv] Majorness decoration for *StructuredBuffer<matrix> ( #1035 )
2018-01-29 16:53:46 -08:00
Ehsan
e6f6fd91a1
[spirv] Provide literal type hint in cast function ( #1034 )
2018-01-29 16:58:34 -05:00
Lei Zhang
2876f84356
[spirv] Treat (non-)literal the same to avoid unnecessary cast ( #1030 )
2018-01-29 11:13:44 -08:00
Jeff Noyle
004c681a97
Move PIX options out of DxilGenerationPass.*, use option string properly, reduce header usage ( #1022 )
...
* Clean up option usage, includes, and move PIX passes to their own header
* move utils to header
* use radix, pass proper default
2018-01-26 15:43:44 -08:00
Xiang Li
53c54eb8b7
Add IDiaInjectedSource to dndxc. ( #1025 )
...
* Add IDiaInjectedSource to dndxc.
* Implement findFileById
2018-01-25 12:24:09 -08:00
Marcelo Lopez Ruiz
c8c6ed8128
Adds support for inf literals and for asuint in constant expressions ( #1029 )
2018-01-25 10:28:09 -08:00
Lei Zhang
1c24fef0bf
[spirv] Consider storage class when creating temporary variable ( #1027 )
2018-01-24 11:27:48 -08:00
Sebastian Tafuri
0915ae5458
Removed inline from function to solve unresolved link error ( #1026 )
2018-01-24 08:23:43 -08:00