diff options
author | Kristian Høgsberg Kristensen <[email protected]> | 2015-06-18 16:17:58 -0700 |
---|---|---|
committer | Kristian Høgsberg Kristensen <[email protected]> | 2015-06-19 15:42:15 -0700 |
commit | 9e59003fb198ecf23a386c21a0c8a7696d69cc95 (patch) | |
tree | 8838aa89560edb9ffcb562daab73fda53aad4d68 | |
parent | b20794cfa81191993e702b333cef4efe908f5841 (diff) |
vk: Undo relocs for scratch bos
-rw-r--r-- | src/vulkan/gen75_pack.h | 42 | ||||
-rw-r--r-- | src/vulkan/gen7_pack.h | 42 | ||||
-rw-r--r-- | src/vulkan/gen8_pack.h | 49 |
3 files changed, 38 insertions, 95 deletions
diff --git a/src/vulkan/gen75_pack.h b/src/vulkan/gen75_pack.h index c4e71686c2a..1653cb11ae3 100644 --- a/src/vulkan/gen75_pack.h +++ b/src/vulkan/gen75_pack.h @@ -1856,7 +1856,7 @@ struct GEN75_3DSTATE_DS { uint32_t AccessesUAV; uint32_t IllegalOpcodeExceptionEnable; uint32_t SoftwareExceptionEnable; - __gen_address_type ScratchSpaceBasePointer; + uint32_t ScratchSpaceBasePointer; uint32_t PerThreadScratchSpace; uint32_t DispatchGRFStartRegisterForURBData; uint32_t PatchURBEntryReadLength; @@ -1898,14 +1898,11 @@ GEN75_3DSTATE_DS_pack(__gen_user_data *data, void * restrict dst, __gen_field(values->SoftwareExceptionEnable, 7, 7) | 0; - uint32_t dw3 = + dw[3] = __gen_offset(values->ScratchSpaceBasePointer, 10, 31) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - dw[3] = - __gen_combine_address(data, &dw[3], values->ScratchSpaceBasePointer, dw3); - dw[4] = __gen_field(values->DispatchGRFStartRegisterForURBData, 20, 24) | __gen_field(values->PatchURBEntryReadLength, 11, 17) | @@ -2261,7 +2258,7 @@ struct GEN75_3DSTATE_GS { uint32_t GSaccessesUAV; uint32_t MaskStackExceptionEnable; uint32_t SoftwareExceptionEnable; - __gen_address_type ScratchSpaceBasePointer; + uint32_t ScratchSpaceBasePointer; uint32_t PerThreadScratchSpace; uint32_t OutputVertexSize; uint32_t OutputTopology; @@ -2323,14 +2320,11 @@ GEN75_3DSTATE_GS_pack(__gen_user_data *data, void * restrict dst, __gen_field(values->SoftwareExceptionEnable, 7, 7) | 0; - uint32_t dw3 = + dw[3] = __gen_offset(values->ScratchSpaceBasePointer, 10, 31) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - dw[3] = - __gen_combine_address(data, &dw[3], values->ScratchSpaceBasePointer, dw3); - dw[4] = __gen_field(values->OutputVertexSize, 23, 28) | __gen_field(values->OutputTopology, 17, 22) | @@ -2446,7 +2440,7 @@ struct GEN75_3DSTATE_HS { uint32_t StatisticsEnable; uint32_t InstanceCount; uint32_t KernelStartPointer; - __gen_address_type ScratchSpaceBasePointer; + uint32_t ScratchSpaceBasePointer; uint32_t PerThreadScratchSpace; uint32_t SingleProgramFlow; #define Dmask 0 @@ -2494,14 +2488,11 @@ GEN75_3DSTATE_HS_pack(__gen_user_data *data, void * restrict dst, __gen_offset(values->KernelStartPointer, 6, 31) | 0; - uint32_t dw4 = + dw[4] = __gen_offset(values->ScratchSpaceBasePointer, 10, 31) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - dw[4] = - __gen_combine_address(data, &dw[4], values->ScratchSpaceBasePointer, dw4); - dw[5] = __gen_field(values->SingleProgramFlow, 27, 27) | __gen_field(values->VectorMaskEnable, 26, 26) | @@ -2869,7 +2860,7 @@ struct GEN75_3DSTATE_PS { uint32_t IllegalOpcodeExceptionEnable; uint32_t MaskStackExceptionEnable; uint32_t SoftwareExceptionEnable; - __gen_address_type ScratchSpaceBasePointer; + uint32_t ScratchSpaceBasePointer; uint32_t PerThreadScratchSpace; uint32_t MaximumNumberofThreads; uint32_t SampleMask; @@ -2926,14 +2917,11 @@ GEN75_3DSTATE_PS_pack(__gen_user_data *data, void * restrict dst, __gen_field(values->SoftwareExceptionEnable, 7, 7) | 0; - uint32_t dw3 = + dw[3] = __gen_offset(values->ScratchSpaceBasePointer, 10, 31) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - dw[3] = - __gen_combine_address(data, &dw[3], values->ScratchSpaceBasePointer, dw3); - dw[4] = __gen_field(values->MaximumNumberofThreads, 23, 31) | __gen_field(values->SampleMask, 12, 19) | @@ -4741,7 +4729,7 @@ struct GEN75_3DSTATE_VS { uint32_t IllegalOpcodeExceptionEnable; uint32_t VSaccessesUAV; uint32_t SoftwareExceptionEnable; - __gen_address_type ScratchSpaceBaseOffset; + uint32_t ScratchSpaceBaseOffset; uint32_t PerThreadScratchSpace; uint32_t DispatchGRFStartRegisterforURBData; uint32_t VertexURBEntryReadLength; @@ -4782,14 +4770,11 @@ GEN75_3DSTATE_VS_pack(__gen_user_data *data, void * restrict dst, __gen_field(values->SoftwareExceptionEnable, 7, 7) | 0; - uint32_t dw3 = + dw[3] = __gen_offset(values->ScratchSpaceBaseOffset, 10, 31) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - dw[3] = - __gen_combine_address(data, &dw[3], values->ScratchSpaceBaseOffset, dw3); - dw[4] = __gen_field(values->DispatchGRFStartRegisterforURBData, 20, 24) | __gen_field(values->VertexURBEntryReadLength, 11, 16) | @@ -5532,7 +5517,7 @@ struct GEN75_MEDIA_VFE_STATE { uint32_t MediaCommandOpcode; uint32_t SubOpcode; uint32_t DwordLength; - __gen_address_type ScratchSpaceBasePointer; + uint32_t ScratchSpaceBasePointer; uint32_t StackSize; uint32_t PerThreadScratchSpace; uint32_t MaximumNumberofThreads; @@ -5586,15 +5571,12 @@ GEN75_MEDIA_VFE_STATE_pack(__gen_user_data *data, void * restrict dst, __gen_field(values->DwordLength, 0, 15) | 0; - uint32_t dw1 = + dw[1] = __gen_offset(values->ScratchSpaceBasePointer, 10, 31) | __gen_field(values->StackSize, 4, 7) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - dw[1] = - __gen_combine_address(data, &dw[1], values->ScratchSpaceBasePointer, dw1); - dw[2] = __gen_field(values->MaximumNumberofThreads, 16, 31) | __gen_field(values->NumberofURBEntries, 8, 15) | diff --git a/src/vulkan/gen7_pack.h b/src/vulkan/gen7_pack.h index 88780322540..75f193891d6 100644 --- a/src/vulkan/gen7_pack.h +++ b/src/vulkan/gen7_pack.h @@ -1521,7 +1521,7 @@ struct GEN7_3DSTATE_DS { uint32_t FloatingPointMode; uint32_t IllegalOpcodeExceptionEnable; uint32_t SoftwareExceptionEnable; - __gen_address_type ScratchSpaceBasePointer; + uint32_t ScratchSpaceBasePointer; uint32_t PerThreadScratchSpace; uint32_t DispatchGRFStartRegisterForURBData; uint32_t PatchURBEntryReadLength; @@ -1561,14 +1561,11 @@ GEN7_3DSTATE_DS_pack(__gen_user_data *data, void * restrict dst, __gen_field(values->SoftwareExceptionEnable, 7, 7) | 0; - uint32_t dw3 = + dw[3] = __gen_offset(values->ScratchSpaceBasePointer, 10, 31) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - dw[3] = - __gen_combine_address(data, &dw[3], values->ScratchSpaceBasePointer, dw3); - dw[4] = __gen_field(values->DispatchGRFStartRegisterForURBData, 20, 24) | __gen_field(values->PatchURBEntryReadLength, 11, 17) | @@ -1621,7 +1618,7 @@ struct GEN7_3DSTATE_GS { uint32_t IllegalOpcodeExceptionEnable; uint32_t MaskStackExceptionEnable; uint32_t SoftwareExceptionEnable; - __gen_address_type ScratchSpaceBasePointer; + uint32_t ScratchSpaceBasePointer; uint32_t PerThreadScratchSpace; uint32_t OutputVertexSize; uint32_t OutputTopology; @@ -1680,14 +1677,11 @@ GEN7_3DSTATE_GS_pack(__gen_user_data *data, void * restrict dst, __gen_field(values->SoftwareExceptionEnable, 7, 7) | 0; - uint32_t dw3 = + dw[3] = __gen_offset(values->ScratchSpaceBasePointer, 10, 31) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - dw[3] = - __gen_combine_address(data, &dw[3], values->ScratchSpaceBasePointer, dw3); - dw[4] = __gen_field(values->OutputVertexSize, 23, 28) | __gen_field(values->OutputTopology, 17, 22) | @@ -1800,7 +1794,7 @@ struct GEN7_3DSTATE_HS { uint32_t StatisticsEnable; uint32_t InstanceCount; uint32_t KernelStartPointer; - __gen_address_type ScratchSpaceBasePointer; + uint32_t ScratchSpaceBasePointer; uint32_t PerThreadScratchSpace; uint32_t SingleProgramFlow; #define Dmask 0 @@ -1846,14 +1840,11 @@ GEN7_3DSTATE_HS_pack(__gen_user_data *data, void * restrict dst, __gen_offset(values->KernelStartPointer, 6, 31) | 0; - uint32_t dw4 = + dw[4] = __gen_offset(values->ScratchSpaceBasePointer, 10, 31) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - dw[4] = - __gen_combine_address(data, &dw[4], values->ScratchSpaceBasePointer, dw4); - dw[5] = __gen_field(values->SingleProgramFlow, 27, 27) | __gen_field(values->VectorMaskEnable, 26, 26) | @@ -2217,7 +2208,7 @@ struct GEN7_3DSTATE_PS { uint32_t IllegalOpcodeExceptionEnable; uint32_t MaskStackExceptionEnable; uint32_t SoftwareExceptionEnable; - __gen_address_type ScratchSpaceBasePointer; + uint32_t ScratchSpaceBasePointer; uint32_t PerThreadScratchSpace; uint32_t MaximumNumberofThreads; uint32_t PushConstantEnable; @@ -2271,14 +2262,11 @@ GEN7_3DSTATE_PS_pack(__gen_user_data *data, void * restrict dst, __gen_field(values->SoftwareExceptionEnable, 7, 7) | 0; - uint32_t dw3 = + dw[3] = __gen_offset(values->ScratchSpaceBasePointer, 10, 31) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - dw[3] = - __gen_combine_address(data, &dw[3], values->ScratchSpaceBasePointer, dw3); - dw[4] = __gen_field(values->MaximumNumberofThreads, 24, 31) | __gen_field(values->PushConstantEnable, 11, 11) | @@ -3927,7 +3915,7 @@ struct GEN7_3DSTATE_VS { uint32_t FloatingPointMode; uint32_t IllegalOpcodeExceptionEnable; uint32_t SoftwareExceptionEnable; - __gen_address_type ScratchSpaceBaseOffset; + uint32_t ScratchSpaceBaseOffset; uint32_t PerThreadScratchSpace; uint32_t DispatchGRFStartRegisterforURBData; uint32_t VertexURBEntryReadLength; @@ -3966,14 +3954,11 @@ GEN7_3DSTATE_VS_pack(__gen_user_data *data, void * restrict dst, __gen_field(values->SoftwareExceptionEnable, 7, 7) | 0; - uint32_t dw3 = + dw[3] = __gen_offset(values->ScratchSpaceBaseOffset, 10, 31) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - dw[3] = - __gen_combine_address(data, &dw[3], values->ScratchSpaceBaseOffset, dw3); - dw[4] = __gen_field(values->DispatchGRFStartRegisterforURBData, 20, 24) | __gen_field(values->VertexURBEntryReadLength, 11, 16) | @@ -4699,7 +4684,7 @@ struct GEN7_MEDIA_VFE_STATE { uint32_t MediaCommandOpcode; uint32_t SubOpcode; uint32_t DwordLength; - __gen_address_type ScratchSpaceBasePointer; + uint32_t ScratchSpaceBasePointer; uint32_t PerThreadScratchSpace; uint32_t MaximumNumberofThreads; uint32_t NumberofURBEntries; @@ -4754,14 +4739,11 @@ GEN7_MEDIA_VFE_STATE_pack(__gen_user_data *data, void * restrict dst, __gen_field(values->DwordLength, 0, 15) | 0; - uint32_t dw1 = + dw[1] = __gen_offset(values->ScratchSpaceBasePointer, 10, 31) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - dw[1] = - __gen_combine_address(data, &dw[1], values->ScratchSpaceBasePointer, dw1); - dw[2] = __gen_field(values->MaximumNumberofThreads, 16, 31) | __gen_field(values->NumberofURBEntries, 8, 15) | diff --git a/src/vulkan/gen8_pack.h b/src/vulkan/gen8_pack.h index 04d4e6126f9..3b9e6235975 100644 --- a/src/vulkan/gen8_pack.h +++ b/src/vulkan/gen8_pack.h @@ -166,7 +166,7 @@ struct GEN8_3DSTATE_VS { uint32_t IllegalOpcodeExceptionEnable; uint32_t AccessesUAV; uint32_t SoftwareExceptionEnable; - __gen_address_type ScratchSpaceBasePointer; + uint64_t ScratchSpaceBasePointer; uint32_t PerThreadScratchSpace; uint32_t DispatchGRFStartRegisterForURBData; uint32_t VertexURBEntryReadLength; @@ -215,14 +215,11 @@ GEN8_3DSTATE_VS_pack(__gen_user_data *data, void * restrict dst, __gen_field(values->SoftwareExceptionEnable, 7, 7) | 0; - uint32_t dw4 = + uint64_t qw4 = __gen_offset(values->ScratchSpaceBasePointer, 10, 63) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - uint64_t qw4 = - __gen_combine_address(data, &dw[4], values->ScratchSpaceBasePointer, dw4); - dw[4] = qw4; dw[5] = qw4 >> 32; @@ -2247,7 +2244,7 @@ struct GEN8_3DSTATE_DS { uint32_t AccessesUAV; uint32_t IllegalOpcodeExceptionEnable; uint32_t SoftwareExceptionEnable; - __gen_address_type ScratchSpaceBasePointer; + uint64_t ScratchSpaceBasePointer; uint32_t PerThreadScratchSpace; uint32_t DispatchGRFStartRegisterForURBData; uint32_t PatchURBEntryReadLength; @@ -2297,14 +2294,11 @@ GEN8_3DSTATE_DS_pack(__gen_user_data *data, void * restrict dst, __gen_field(values->SoftwareExceptionEnable, 7, 7) | 0; - uint32_t dw4 = + uint64_t qw4 = __gen_offset(values->ScratchSpaceBasePointer, 10, 63) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - uint64_t qw4 = - __gen_combine_address(data, &dw[4], values->ScratchSpaceBasePointer, dw4); - dw[4] = qw4; dw[5] = qw4 >> 32; @@ -2683,7 +2677,7 @@ struct GEN8_3DSTATE_GS { uint32_t MaskStackExceptionEnable; uint32_t SoftwareExceptionEnable; uint32_t ExpectedVertexCount; - __gen_address_type ScratchSpaceBasePointer; + uint64_t ScratchSpaceBasePointer; uint32_t PerThreadScratchSpace; uint32_t OutputVertexSize; uint32_t OutputTopology; @@ -2755,14 +2749,11 @@ GEN8_3DSTATE_GS_pack(__gen_user_data *data, void * restrict dst, __gen_field(values->ExpectedVertexCount, 0, 5) | 0; - uint32_t dw4 = + uint64_t qw4 = __gen_offset(values->ScratchSpaceBasePointer, 10, 63) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - uint64_t qw4 = - __gen_combine_address(data, &dw[4], values->ScratchSpaceBasePointer, dw4); - dw[4] = qw4; dw[5] = qw4 >> 32; @@ -2897,7 +2888,7 @@ struct GEN8_3DSTATE_HS { uint32_t MaximumNumberofThreads; uint32_t InstanceCount; uint64_t KernelStartPointer; - __gen_address_type ScratchSpaceBasePointer; + uint64_t ScratchSpaceBasePointer; uint32_t PerThreadScratchSpace; uint32_t SingleProgramFlow; #define Dmask 0 @@ -2947,14 +2938,11 @@ GEN8_3DSTATE_HS_pack(__gen_user_data *data, void * restrict dst, dw[3] = qw3; dw[4] = qw3 >> 32; - uint32_t dw5 = + uint64_t qw5 = __gen_offset(values->ScratchSpaceBasePointer, 10, 63) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - uint64_t qw5 = - __gen_combine_address(data, &dw[5], values->ScratchSpaceBasePointer, dw5); - dw[5] = qw5; dw[6] = qw5 >> 32; @@ -3292,7 +3280,7 @@ struct GEN8_3DSTATE_PS { uint32_t IllegalOpcodeExceptionEnable; uint32_t MaskStackExceptionEnable; uint32_t SoftwareExceptionEnable; - __gen_address_type ScratchSpaceBasePointer; + uint64_t ScratchSpaceBasePointer; uint32_t PerThreadScratchSpace; uint32_t MaximumNumberofThreadsPerPSD; uint32_t PushConstantEnable; @@ -3347,14 +3335,11 @@ GEN8_3DSTATE_PS_pack(__gen_user_data *data, void * restrict dst, __gen_field(values->SoftwareExceptionEnable, 7, 7) | 0; - uint32_t dw4 = + uint64_t qw4 = __gen_offset(values->ScratchSpaceBasePointer, 10, 63) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - uint64_t qw4 = - __gen_combine_address(data, &dw[4], values->ScratchSpaceBasePointer, dw4); - dw[4] = qw4; dw[5] = qw4 >> 32; @@ -6419,10 +6404,10 @@ struct GEN8_MEDIA_VFE_STATE { uint32_t MediaCommandOpcode; uint32_t SubOpcode; uint32_t DwordLength; - __gen_address_type ScratchSpaceBasePointer; + uint32_t ScratchSpaceBasePointer; uint32_t StackSize; uint32_t PerThreadScratchSpace; - __gen_address_type ScratchSpaceBasePointerHigh; + uint32_t ScratchSpaceBasePointerHigh; uint32_t MaximumNumberofThreads; uint32_t NumberofURBEntries; #define Maintainingtheexistingtimestampstate 0 @@ -6473,22 +6458,16 @@ GEN8_MEDIA_VFE_STATE_pack(__gen_user_data *data, void * restrict dst, __gen_field(values->DwordLength, 0, 15) | 0; - uint32_t dw1 = + dw[1] = __gen_offset(values->ScratchSpaceBasePointer, 10, 31) | __gen_field(values->StackSize, 4, 7) | __gen_field(values->PerThreadScratchSpace, 0, 3) | 0; - dw[1] = - __gen_combine_address(data, &dw[1], values->ScratchSpaceBasePointer, dw1); - - uint32_t dw2 = + dw[2] = __gen_offset(values->ScratchSpaceBasePointerHigh, 0, 15) | 0; - dw[2] = - __gen_combine_address(data, &dw[2], values->ScratchSpaceBasePointerHigh, dw2); - dw[3] = __gen_field(values->MaximumNumberofThreads, 16, 31) | __gen_field(values->NumberofURBEntries, 8, 15) | |