summaryrefslogtreecommitdiffstats
path: root/src/amd
Commit message (Collapse)AuthorAgeFilesLines
* ac/nir: move ac_shader_variant_info and friends to radv folderSamuel Pitoiset2018-03-137-136/+139
| | | | | | | Also replace ac_ by radv_. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* ac/nir: move all RADV related code to radv_nir_to_llvm.cSamuel Pitoiset2018-03-137-3425/+3482
| | | | | | | | Now the "ac/nir" prefix will really be the shared code between RadeonSI and RADV, that might avoid confusions in the future. Signed-off-by: Samuel Pitoiset <[email protected]> Acked-by: Bas Nieuwenhuizen <[email protected]>
* ac/nir: make emit_barrier() non-staticSamuel Pitoiset2018-03-132-4/+6
| | | | | | | Required in order to move all RADV specific code outside of ac/nir. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* ac/nir: move radeon_llvm_reg_index_soa() to ac_nir_to_llvm.hSamuel Pitoiset2018-03-132-5/+5
| | | | | | | Required in order to move all RADV specific code outside of ac/nir. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* ac/nir: make handle_shader_output_decl() non-staticSamuel Pitoiset2018-03-132-10/+18
| | | | | | | Required in order to move all RADV specific code outside of ac/nir. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* ac/nir: change prototype of handle_shader_output_decl()Samuel Pitoiset2018-03-131-14/+14
| | | | | | | This allows to remove the ac_nir_context dependency. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* ac/nir: move unpack_param() to ac_llvm_build.cSamuel Pitoiset2018-03-133-33/+35
| | | | | Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* ac/nir: move trim_vector to ac_llvm_build.cSamuel Pitoiset2018-03-133-24/+27
| | | | | Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* ac/nir: move cast_ptr() to ac_llvm_build.cSamuel Pitoiset2018-03-133-10/+13
| | | | | Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* ac/nir: move ac_build_alloca() to ac_llvm_build.cSamuel Pitoiset2018-03-133-39/+41
| | | | | | | As well as si_build_alloca_undef() and drop the si prefix. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* radv: Increase the number of dynamic uniform buffers.Bas Nieuwenhuizen2018-03-122-3/+5
| | | | | | | | | | | | | The vulkan API is not ideal as it does not allow us have a shared limit. Feral needs 15+6 for one of their games, and I'm not a fan of overcommitting the limits, so increase the number of dynamic uniform buffers to 16. CC: <[email protected]> CC: Alex Smith <[email protected]> Reviewed-by: Dave Airlie <[email protected]>
* ac/gpu_info: print ib_start_alignment, add assertionMarek Olšák2018-03-091-0/+2
|
* radv: Fix the autotools build take 2.Bas Nieuwenhuizen2018-03-091-1/+1
| | | | | | Forgot to remove a word.... Fixes: 04ffabf17a "radv: Fix autotools build."
* radv: Fix autotools build.Bas Nieuwenhuizen2018-03-091-10/+7
| | | | | | | Forgot it again .... Fixes: b6347807a9 "radv: Generate icd files." Acked-by: Samuel Pitoiset <[email protected]>
* ac/nir: set number of channels for packed mrt exportsSamuel Pitoiset2018-03-091-0/+5
| | | | | | | | Bit 0 enables VSRC0 (R in low bits, G high) and bit 2 enables VSRC1 (B in low bits, A high). Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* radv: Update version to 1.1.70.Bas Nieuwenhuizen2018-03-091-2/+2
| | | | | | Turns out they did not reset the patch number on release. Reviewed-by: Dave Airlie <[email protected]>
* radv: Generate icd files.Bas Nieuwenhuizen2018-03-094-25/+70
| | | | | | | | If the api version is too low, the loader clamps the application requested version to the advertized version, which messes with which extensions are enabled. Reviewed-by: Dave Airlie <[email protected]>
* winsys/amdgpu: query GDS infoMarek Olšák2018-03-082-0/+13
| | | | Reviewed-by: Alex Deucher <[email protected]>
* radeonsi: align command buffer starting address to fix some Raven hangsMarek Olšák2018-03-082-1/+21
| | | | | | Cc: 17.3 18.0 <[email protected]> Reviewed-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
* ac/nir: do not emit unnecessary null exports in fragment shadersSamuel Pitoiset2018-03-081-13/+16
| | | | | | | | | | | | | | | | | | | | Null exports should only be needed when no other exports are emitted. This removes a bunch of 'exp null off, off, off, off done vm'. Affected games are Dota 2 and Wolfenstein 2, not sure if that really helps, but code size is decreasing there. Polaris10: Totals from affected shaders: SGPRS: 8216 -> 8216 (0.00 %) VGPRS: 7072 -> 7072 (0.00 %) Spilled SGPRs: 0 -> 0 (0.00 %) Spilled VGPRs: 0 -> 0 (0.00 %) Code Size: 454968 -> 453896 (-0.24 %) bytes Max Waves: 772 -> 772 (0.00 %) Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* ac/radeonsi: add emit_kill to the abiTimothy Arceri2018-03-082-1/+10
| | | | | | | | This should fix a regression with Rocket League grass rendering on the NIR backend. Reviewed-by: Marek Olšák <[email protected]> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=104717
* ac: make use of if/loop build helpersTimothy Arceri2018-03-081-42/+18
| | | | | | | | | | | | These helpers insert the basic block in the same order as they appear in NIR making it easier to follow LLVM IR dumps. The helpers also insert more useful labels onto the blocks. TGSI use the line number of the corresponding opcode in the TGSI dump as the label id, here we use the corresponding block index from NIR. Reviewed-by: Marek Olšák <[email protected]>
* ac: add if/loop build helpersTimothy Arceri2018-03-083-0/+211
| | | | | | These have been ported over from radeonsi. Reviewed-by: Marek Olšák <[email protected]>
* radv: enable AMD_gcn_shader extensionDaniel Schürmann2018-03-072-0/+4
| | | | | Signed-off-by: Daniel Schürmann <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* ac: implement AMD_gcn_shader extended instructionsDaniel Schürmann2018-03-071-0/+28
| | | | | | Co-authored-by: Dave Airlie <[email protected]> Signed-off-by: Daniel Schürmann <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* radv: Don't emit a warning on VI-GFX9.Bas Nieuwenhuizen2018-03-071-1/+3
| | | | | | | | | We are conformant: https://www.khronos.org/conformance/adopters/conformant-products#submission_308 v2: Actually not emit it on gfx9. Reviewed-by: Samuel Pitoiset <[email protected]>
* radv: Enable vulkan 1.1.0 for configurations that can support it.Bas Nieuwenhuizen2018-03-071-0/+2
| | | | Reviewed-by: Dave Airlie <[email protected]>
* radv: Disable sampler ycbcr conversion.Bas Nieuwenhuizen2018-03-072-0/+24
| | | | Reviewed-by: Dave Airlie <[email protected]>
* radv: Expose that we don't support any VK_KHR_16_bit_storage parts.Bas Nieuwenhuizen2018-03-071-0/+9
| | | | Reviewed-by: Dave Airlie <[email protected]>
* radv: Implement vkEnumerateInstanceVersion.Bas Nieuwenhuizen2018-03-071-0/+7
| | | | Reviewed-by: Dave Airlie <[email protected]>
* radv: Add trivial device group implementation.Bas Nieuwenhuizen2018-03-075-0/+79
| | | | Reviewed-by: Dave Airlie <[email protected]>
* radv: Implement vkCmdDispatchBase.Bas Nieuwenhuizen2018-03-072-3/+41
| | | | Reviewed-by: Dave Airlie <[email protected]>
* radv: Implement VkGetDeviceQueue2.Bas Nieuwenhuizen2018-03-071-2/+16
| | | | Reviewed-by: Dave Airlie <[email protected]>
* radv: Support VkPhysicalDeviceProtectedMemoryFeatures.Bas Nieuwenhuizen2018-03-071-0/+6
| | | | Reviewed-by: Dave Airlie <[email protected]>
* radv: Support VkPhysicalDeviceShaderDrawParameterFeatures.Bas Nieuwenhuizen2018-03-071-0/+6
| | | | Reviewed-by: Dave Airlie <[email protected]>
* radv: Implement VK_KHR_maintenance3.Bas Nieuwenhuizen2018-03-073-4/+90
| | | | Reviewed-by: Dave Airlie <[email protected]>
* radv: Add minimal subgroup support.Bas Nieuwenhuizen2018-03-074-0/+70
| | | | | | | Deliberately not implementing workgroup scopes as that is not needed for core vulkan. Reviewed-by: Dave Airlie <[email protected]>
* radv: Change client version check.Bas Nieuwenhuizen2018-03-071-1/+1
| | | | Reviewed-by: Dave Airlie <[email protected]>
* radv: Update MAX_API_VERSION to 1.1.0Bas Nieuwenhuizen2018-03-077-37/+37
| | | | | | | v2: Don't bump supported version. v3: Update json files. Reviewed-by: Dave Airlie <[email protected]>
* ac/nir: Add vote_ieq/vote_feq lowering pass.Bas Nieuwenhuizen2018-03-075-5/+99
| | | | | | | | | | | | The old vote_eq implementation supported only booleans, but now we have to support arbitrary values, so use the read_first_invocation intrinsic + ballot. I took this as an opportunity to figure out how easy it was to do this in nir instead of in the nir_to_llvm pass, and it actually turned out pretty okay IMO. Only creating the pass is some extra code. Reviewed-by: Dave Airlie <[email protected]>
* nir: Generalize nir_intrinsic_vote_eqJason Ekstrand2018-03-071-1/+1
| | | | | | | | | | | | | The SPIR-V extension wants us to be able to do an AllEqual on any vector or scalar type. This has two implications: 1) We need to be able to handle vectors so we switch the vote_eq intrinsics to be vectorized intrinsics. 2) We need to handle floats which have different behavior with respect to +-0, NaN, etc. than the integer variant so we need two variants. Reviewed-by: Lionel Landwerlin <[email protected]>
* vulkan: Rename multiview from KHX to KHRJason Ekstrand2018-03-073-8/+8
| | | | | | Reviewed-by: Lionel Landwerlin <[email protected]> Reviewed-by: Samuel Iglesias Gonsálvez <[email protected]> Reviewed-by: Dave Airlie <[email protected]>
* radeonsi: fix passing address32_hi to LLVM for high valuesMarek Olšák2018-03-072-3/+3
| | | | The old function treats high values as negative, which LLVM interprets as 0.
* radv: Add entrypoints generation with the new vk.xmlBas Nieuwenhuizen2018-03-071-107/+164
| | | | | | A lot of it is based on intel again. Reviewed-by: Dave Airlie <[email protected]>
* ac/nir: don't put lod into args if it's zero.Dave Airlie2018-03-071-2/+1
| | | | | | | | | | | If it's zero but put it in args we still end up consuming a register for it. This fixes some spilling in the NIR paths in Dirt Rally that isn't seen with TGSI. Reviewed-by: Timothy Arceri <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* radv: report the scratch private memory size with shader statsSamuel Pitoiset2018-03-061-1/+3
| | | | | Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Dave Airlie <[email protected]>
* ac/nir: count the scratch private memory sizeSamuel Pitoiset2018-03-062-2/+9
| | | | | Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Dave Airlie <[email protected]>
* ac: add ac_count_scratch_private_memory()Samuel Pitoiset2018-03-062-0/+34
| | | | | | | Imported from RadeonSI. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Dave Airlie <[email protected]>
* ac/nir: only enable used channels when exporting parametersSamuel Pitoiset2018-03-061-4/+20
| | | | | | | | | | This allows us to generate, for example, "exp param0 v0, off, off, off" if only the first channel is needed. Not sure if this improves performance but it's worth trying. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Dave Airlie <[email protected]>
* ac: update enabled channels mask when optimizing PARAM exportsSamuel Pitoiset2018-03-061-2/+16
| | | | | | | | | When the mask is not 0xf we need to update the number of enabled channels, otherwise the hardware won't emit the components that are combined. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Dave Airlie <[email protected]>