summaryrefslogtreecommitdiffstats
path: root/src/amd/addrlib/r800/ciaddrlib.cpp
Commit message (Collapse)AuthorAgeFilesLines
* amd/addrlib: add support for VegaMMarek Olšák2018-04-181-0/+5
| | | | Acked-by: Nicolai Hähnle <[email protected]>
* amd/addrlib: update to the latest version for Vega12Marek Olšák2018-03-281-11/+29
| | | | Reviewed-by: Alex Deucher <[email protected]>
* amd/addrlib: update to latest versionMarek Olšák2017-11-081-27/+20
| | | | | | | | | | | | This uses C++11 initializer lists. I just overwrote all Mesa files with internal addrlib and discarded hunks that we should probably keep, but I might have missed something. The code depending on ADDR_AM_BUILD is removed. We can add it back next time if needed. Acked-by: Nicolai Hähnle <[email protected]>
* ac/addrlib: relax an assertionNicolai Hähnle2017-09-131-1/+1
| | | | | | | | | This assertion is triggered on Stoney in Piglit ./bin/framebuffer-blit-levels {draw,read} stencil -auto -fbo and similar tests. It should be harmless -- just relax it until we can get internal clarification. Reviewed-by: Marek Olšák <[email protected]>
* amd/addrlib: fix typo in api name.Dave Airlie2017-07-171-1/+1
| | | | | | | | This fixes the misspelling of ALIGNMENTS in addrlib. Reviewed-by: Eduardo Lima Mitev <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* amd/addrlib: second update for Vega10 + bug fixesMarek Olšák2017-04-041-39/+71
| | | | | | | | | | | | | | | | | | | | | | | Highlights: - Display needs tiled pitch alignment to be at least 32 pixels - Implement Addr2ComputeDccAddrFromCoord(). - Macro-pixel packed formats don't support Z swizzle modes - Pad pitch and base alignment of PRT + TEX1D to 64KB. - Fix support for multimedia formats - Fix a case "PRT" entries are not selected on SI. - Fix wrong upper bits in equations for 3D resource. - We can't support 2d array slice rotation in gfx8 swizzle pattern - Set base alignment for PRT + non-xor swizzle mode resource to 64KB. - Bug workaround for Z16 4x/8x and Z32 2x/4x/8x MSAA depth texture - Add stereo support - Optimize swizzle mode selection - Report pitch and height in pixels for each mip - Adjust bpp/expandX for format ADDR_FMT_GB_GR/ADDR_FMT_BG_RG - Correct tcCompatible flag output for mipmap surface - Other fixes and cleanups Acked-by: Alex Deucher <[email protected]> Acked-by: Nicolai Hähnle <[email protected]>
* amdgpu/addrlib: Seperate 2 dcc related workarounds by different flagsNicolai Hähnle2017-03-301-2/+2
| | | | | 1) dccCompatible for padding MSAA surface to support fast clear 2) dccPipeWorkaround for padding surface to support dcc
* amdgpu/addrlib: add matchStencilTileCfg and tcCompatible fixesXavi Zhang2017-03-301-14/+126
| | | | | | | | | | | | | | | | | | | | | | | | | | | The usage should be client first call AddrComputeSurfaceInfo() on depth surface with flag "matchStencilTilecfg", AddrLib will use 2DThin1 tile index for depth as much as possible and do not down grade unless alignment requirement cannot be met. 1. If there is a matched 2DThin1 tile index for stencil which make sure they will share same tile config parameters, then return the stencil 2DThin1 tile index as well. 2. If using 2DThin1 tile mode cannot make sure such thing happen, and TcCompatible flag was set, then ignore this flag then try 2DThin1 tile mode for depth and stencil again. 3. If 2DThin1 tile mode cannot make sure depth and stencil to have same tile config parameters, then down grade depth surface tile mode to 1DThin1. 4. If depth surface's tile mode was 1DThin1, then return 1DThin1 tile index for stencil. 5. If depth surface's tile mode is PRT, then return invalid tile index to stencil since their tile config parameters will never be met. Client driver then check the returned tile index of stencil -- if it is not invalid tile index, then call AddrComputeSurfaceInfo() on stencil surface with the returned stencil tile index to get full output information. Please note, client needs to set flag "useTileIndex" when AddrLib get created.
* amdgpu/addrlib: Adjust bank equation bit order based on macro tile aspect ↵Frans Gu2017-03-301-37/+43
| | | | | | | | ratio settings By this way, we can have valid equation for 2D_THIN1 tile mode. Add flag "preferEquation" to return equation index without adjusting input tile mode.
* amdgpu/addrlib: Check prt flag for PRT_THIN1 extra padding for DCC.Xavi Zhang2017-03-301-18/+17
|
* amdgpu/addrlib: Add new flags minimizePadding and maxBaseAlignFrans Gu2017-03-301-46/+106
| | | | | | | | | 1) minimizePadding - Use 1D tile mode if padded size of 2D is bigger than 1D 2) maxBaseAlign - Force PRT tile mode if macro block size is bigger than requested alignment. Also, related changes to tile mode optimization for needEquation.
* amdgpu/addrlib: Add flag to report if a surface can have dcc ramFrans Gu2017-03-301-1/+24
|
* amdgpu/addrlib: Fix family setting for VI and CZ ASICsFrans Gu2017-03-301-0/+2
|
* amdgpu/addrlib: style cleanupNicolai Hähnle2017-03-301-19/+6
| | | | Signed-off-by: Nicolai Hähnle <[email protected]>
* amdgpu/addrlib: Pad pitch to multiples of 256 for DCC surface on FijiNicolai Hähnle2017-03-301-16/+50
| | | | | The change also modifies function CiLib::HwlPadDimensions to report adjusted pitch alignment.
* amdgpu/addrlib: Fix number of //Xavi Zhang2017-03-301-2/+2
| | | | | | Find ^/{80,99}$ and replace them to 100 "/" Signed-off-by: Nicolai Hähnle <[email protected]>
* amdgpu/addrlib: Cleanup.Nicolai Hähnle2017-03-301-7/+7
| | | | Signed-off-by: Nicolai Hähnle <[email protected]>
* amdgpu/addrlib: Use namespacesXavi Zhang2017-03-301-99/+106
| | | | Signed-off-by: Nicolai Hähnle <[email protected]>
* amdgpu/addrlib: Adjust 99 "*" to 100 "*" alignmentKevin Zhao2017-03-301-65/+65
| | | | Signed-off-by: Nicolai Hähnle <[email protected]>
* amdgpu/addrlib: Add a new tile mode ADDR_TM_UNKNOWNFrans Gu2017-03-301-0/+96
| | | | | This can be used by address lib client to ask address lib to select tile mode.
* amdgpu/addrlib: Disable tcComaptible when depth surface is not macro tiledRoy Zhan2017-03-301-17/+20
| | | | Experiment show 1D tiling + TcCompatible cannot work together.
* amdgpu/addrlib: add equation generationNicolai Hähnle2017-03-301-20/+67
| | | | | | | | | | | | | | | | 1. Add new surface flags needEquation for client driver use to force the surface tile setting equation compatible. Override 2D/3D macro tile mode to PRT_* tile mode if this flag is TRUE and num slice > 1. 2. Add numEquations and pEquationTable in ADDR_CREATE_OUTPUT structure to return number of equations and the equation table to client driver 3. Add equationIndex in ADDR_COMPUTE_SURFACE_INFO_OUTPUT structure to return the equation index to client driver Please note the use of address equation has following restrictions: 1) The surface can't be splitable 2) The surface can't have non zero tile swizzle value 3) Surface with > 1 slices must have PRT tile mode, which disable slice rotation
* amdgpu/addrlib: rename ComputeSurfaceThickness to ThicknessNicolai Hähnle2017-03-301-4/+4
|
* amdgpu/addrlib: Fix invalid access to m_tileTableNicolai Hähnle2017-03-301-6/+17
| | | | | | | | Sometimes client driver passes valid tile info into address library, in this case, the tile index is computed in function HwlPostCheckTileIndex instead of CiAddrLib::HwlSetupTileCfg. We need to call HwlPostCheckTileIndex to calculate the correct tile index to get tile split bytes for this case.
* amdgpu/addrlib: add tcCompatible htile addr from coordinate support.XiaoYuan Zheng2017-03-301-1/+46
|
* amdgpu/addrlib: force all zero tile info for linear general.Carlos Xiong2017-03-301-1/+10
|
* amdgpu/addrlib: Add a member "bpp" for input of method AddrConvertTileIndex ↵Nicolai Hähnle2017-03-301-12/+27
| | | | | | | | | | | and AddrConvertTileInfoToHW When clients queries tile Info from tile index and expects accurate tileSplit info, bits per pixel info is required to be provided since this is necessary for computing tileSplitBytes; otherwise Addrlib will return value of "tileBytes" instead if bpp is 0 - which is also current logic. If clients don't need tileSplit info, it's OK to pass bpp with value 0.
* amdgpu/addrlib: Refine the PRT tile mode selectionFrans Gu2017-03-301-49/+19
| | | | | Switch the tile index based on logic instead of hardcoded threshold for different ASIC.
* amdgpu/addrlib: add dccRamSizeAligned output flagXavi Zhang2017-03-301-0/+5
| | | | | This flag indicates to the client if this level's DCC memory is aligned or not. No aligned means there are padding to the end.
* amdgpu/addrlib: style changes and minor cleanupsNicolai Hähnle2017-03-301-0/+1
| | | | Signed-off-by: Nicolai Hähnle <[email protected]>
* amdgpu/addrlib: Add GetMaxAlignmentsXavi Zhang2017-03-301-0/+40
|
* amdgpu/addrlib: Let Kaveri go general stereo right eye offset padding pathXavi Zhang2017-03-301-30/+0
| | | | | | | | Kaveri (2-pipe) macro tiling mode table was initially set to all 4-aspect-ratio so the swizzling path did not work for it and then we chose to pad the offset. We now discover the root cause is that if ratio > 2, the swizzling path does not work. So we can safely use the same path for Kaveri.
* amdgpu/addrlib: Add a flag "tcCompatible" to surface info output structure.Carlos Xiong2017-03-301-12/+39
| | | | | | | Even if surface info input flag "tcComaptible" is enabled, tc compatible may be not supported if tile split happens for depth surfaces. Add a new flag in output structure to notify client to disable tc compatible in this case.
* amdgpu/addrlib: add new flag nonSplitXiaoYuan Zheng2017-03-301-1/+1
| | | | | Flag tcCompatible has different usage in CI and VI. Add a new flag "nonSplit" for CI.
* amdgpu/addrlib: Change to compute TC compatible stencil infoCarlos Xiong2017-03-301-65/+57
| | | | | | | | | | | | Change the logic to compute tc compatible stencil info via depth's tileIndex instead of using depth's tileInfo. So the clients can get the stencil's tileInfo computed from macroModeTable. If the stencil tileInfo is same as depth tileInfo, then stencil is tc compatible; otherwise, stencil is not tc compatible. The current suggestion is to create another stencil buffer with the tc compatible tileInfo, use depth-to-color copy to decompress and tile convert the rendered stencil to tc compoatible stencil (And use the new stencil buffer to program TC).
* amdgpu/addrlib: rename SiAddrLib/CiAddrLib to match internal spellingNicolai Hähnle2017-03-301-55/+55
| | | | Signed-off-by: Nicolai Hähnle <[email protected]>
* radeonsi: add Polaris12 support (v3)Junwei Zhang2016-12-211-1/+2
| | | | | | | | | | | v2: use gfxip names for llvm 4.0+ v3: use tonga for llvm <= 3.8, drop gfxip name, we can just change that we change the other asics. Reviewed-by: Marek Olšák <[email protected]> Signed-off-by: Junwei Zhang <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]> Acked-by: Christian König <[email protected]>
* amd/addrlib: move addrlib from amdgpu winsys to common codeDave Airlie2016-09-061-0/+1831
Acked-by: Marek Olšák <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]>