Adam Jackson
b8236bcb74
glx: Be more robust against null fbconfigs
...
These can happen along the internal paths for no-config contexts, and we
shouldn't crash.
Acked-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9992 >
2021-04-13 22:58:58 +00:00
Adam Jackson
a2b474c333
glx: Move {Bind,Release}TexImage from context to screen vtable
...
All the other operations on drawables live there, be consistent.
Acked-by: Eric Engestrom <eric@engestrom.ch >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9992 >
2021-04-13 22:58:58 +00:00
Adam Jackson
e8d10a15f1
glx: Don't pointlesly add -D_REENTRANT to libGL's cflags
...
Reviewed-by: Eric Engestrom <eric@engestrom.ch >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9992 >
2021-04-13 22:58:58 +00:00
Adam Jackson
b1cb0af596
glx: Remove some #if 0'd DRI config attribute fetch
...
We've never read any of this out. The transparency stuff we've never
implemented and the shift/mask stuff doesn't vary independently enough
to need to match on.
Reviewed-by: Eric Engestrom <eric@engestrom.ch >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9992 >
2021-04-13 22:58:58 +00:00
Adam Jackson
2f9dd41701
glx: Clean up fbconfig attribute handling
...
Move the macros defining the expected number of attributes into the same
file as their consumer, remove a pointless maximum, and allocate more
space for attribs on the stack to avoid malloc in the common case.
glxext.c knows about 46 config attribs, 46 - 18 = 28, round up to 32 to
future proof a bit.
Reviewed-by: Eric Engestrom <eric@engestrom.ch >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9992 >
2021-04-13 22:58:58 +00:00
Adam Jackson
a7474f19d4
glx: Default sRGBCapable in the same place as the other config attribs
...
Reviewed-by: Eric Engestrom <eric@engestrom.ch >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9992 >
2021-04-13 22:58:58 +00:00
Mike Blumenkrantz
dc265008c7
aux/trace: use ralloc_free for ralloc()ed state pointers
...
Reviewed-by: Vasily Khoruzhick <anarsoul@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10221 >
2021-04-13 18:26:20 -04:00
Iván Briano
8328989130
intel, anv: propagate robustness setting to nir_opt_load_store_vectorize
...
Closes #4309
Fixes dEQP-VK-robustness.robustness2.*.readonly.*
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10147 >
2021-04-13 13:30:09 -07:00
Jason Ekstrand
e6c79329dd
intel: fix querying mip levels on null surfaces on SKL and prior
...
When a surface of type SURFTYPE_NULL is accessed by resinfo, the MIPCount
returned is undefined instead of 0.
Closes #4309
Fixes dEQP-VK.robustness.robustness2.*.sampled_image.*.null_descriptor.*
Reviewed-by: Ivan Briano <ivan.briano@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10147 >
2021-04-13 13:30:09 -07:00
Ella-0
a18ac347cf
glsl: build without bison
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8739 >
2021-04-13 19:12:48 +00:00
Alyssa Rosenzweig
e7977b8c49
docs: Add some notes on building for macOS
...
I intend this page to grow as I explore more about Mesa/Darwin.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10152 >
2021-04-13 19:09:13 +00:00
Daniel Schürmann
b6a28aaa8b
aco/cssa: don't create parallelcopies for constants and exec
...
if we are able to spill these directly.
Totals from 4913 (3.60% of 136546) affected shaders (Raven):
SpillSGPRs: 16021 -> 15451 (-3.56%); split: -3.87%, +0.31%
CodeSize: 58102020 -> 57371464 (-1.26%); split: -1.26%, +0.00%
Instrs: 11411454 -> 11230105 (-1.59%); split: -1.59%, +0.00%
Latency: 555706331 -> 550058635 (-1.02%); split: -1.07%, +0.05%
InvThroughput: 273023354 -> 271854469 (-0.43%); split: -0.44%, +0.01%
SClause: 385168 -> 385371 (+0.05%); split: -0.01%, +0.06%
Copies: 1342084 -> 1175762 (-12.39%); split: -12.40%, +0.01%
Branches: 392619 -> 378662 (-3.55%); split: -3.56%, +0.00%
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9196 >
2021-04-13 18:40:57 +00:00
Daniel Schürmann
18ba93e673
aco/cssa: rewrite lower_to_cssa pass
...
The previous pass was based on misconceptions and
rounded up with bug fixes. The new pass is entirely
rewritten and basically just one-to-one from the paper:
"Revisiting Out-of-SSA Translation for Correctness, CodeQuality, and Efficiency"
by B. Boissinot et al.
It also incorporates the value-equality testing.
The regressions are mainly due to creating parallelcopies for
exec phis at loop headers (mitigated in the next commit).
Totals from 4933 (3.61% of 136546) affected shaders (Raven):
SpillSGPRs: 16249 -> 16527 (+1.71%); split: -0.28%, +1.99%
SpillVGPRs: 1771 -> 1595 (-9.94%)
CodeSize: 57544436 -> 58280304 (+1.28%); split: -0.00%, +1.28%
Scratch: 176128 -> 179200 (+1.74%)
Instrs: 11265783 -> 11445884 (+1.60%); split: -0.00%, +1.60%
Latency: 552596156 -> 555880540 (+0.59%); split: -0.53%, +1.13%
InvThroughput: 271431862 -> 273097423 (+0.61%); split: -0.18%, +0.79%
VClause: 160240 -> 160241 (+0.00%); split: -0.02%, +0.02%
SClause: 386863 -> 386685 (-0.05%); split: -0.07%, +0.02%
Copies: 1180801 -> 1345633 (+13.96%); split: -0.02%, +13.98%
Branches: 379129 -> 393052 (+3.67%); split: -0.01%, +3.69%
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9196 >
2021-04-13 18:40:57 +00:00
Daniel Schürmann
9d73a4a412
aco: add new reindex_ssa() pass
...
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9196 >
2021-04-13 18:40:57 +00:00
Daniel Schürmann
d75c73e6a6
aco: fix kill flags on phi operands
...
Fossil-db changes are likely due to how the CSSA pass works.
Totals from 1782 (1.31% of 136546) affected shaders (Raven):
CodeSize: 25333292 -> 25294020 (-0.16%); split: -0.16%, +0.00%
Instrs: 4916059 -> 4908218 (-0.16%); split: -0.16%, +0.00%
Latency: 282860167 -> 282707176 (-0.05%); split: -0.08%, +0.03%
InvThroughput: 136487564 -> 136394958 (-0.07%); split: -0.12%, +0.05%
VClause: 74791 -> 74795 (+0.01%)
Copies: 542115 -> 534280 (-1.45%); split: -1.48%, +0.04%
Branches: 168977 -> 168966 (-0.01%); split: -0.01%, +0.01%
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9196 >
2021-04-13 18:40:57 +00:00
Daniel Schürmann
13e4fed01f
aco: lower p_spill with constants correctly
...
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9196 >
2021-04-13 18:40:57 +00:00
Daniel Schürmann
4a57787006
aco/spill: use correct next_use_distances at loop header
...
To decide which variables to spill, we must use the distances at the
beginning of the loop-header, and not the distances at the end of the
loop-preheader. The difference are that the former includes phis which are
viable to be spilled as opposed to the phi operands which would be reloaded
by add_coupling_code(), ending up in potentially too high register pressure
before the loop.
Totals from 206 (0.15% of 136546) affected shaders (Raven):
SpillSGPRs: 5154 -> 5000 (-2.99%)
CodeSize: 3654072 -> 3647184 (-0.19%); split: -0.19%, +0.00%
Instrs: 701482 -> 700526 (-0.14%); split: -0.14%, +0.00%
Latency: 40988780 -> 40872506 (-0.28%); split: -0.29%, +0.00%
InvThroughput: 20364560 -> 20306006 (-0.29%)
SClause: 20192 -> 20198 (+0.03%)
Copies: 77732 -> 77688 (-0.06%); split: -0.08%, +0.03%
Branches: 24204 -> 24050 (-0.64%)
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9196 >
2021-04-13 18:40:57 +00:00
Daniel Schürmann
b56ea19111
aco/spill: refactor live-in registerDemand calculation
...
This also fixes some hypothetical issue for loops without phis
and for loops with higher register pressure at the end of the
loop preheader.
No fossil-db changes.
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9196 >
2021-04-13 18:40:57 +00:00
Daniel Schürmann
282eacc3e0
aco/spill: refactor some more spill decision taking
...
No fossil-db changes.
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9196 >
2021-04-13 18:40:57 +00:00
Daniel Schürmann
dfb10e4f4b
aco/spill: don't count phis as variable access
...
This increases the chance of evicting phis
if these have longer next-use distances.
Totals from 6 (0.00% of 146267) affected shaders (Navi10):
CodeSize: 476992 -> 464388 (-2.64%)
Instrs: 81785 -> 79952 (-2.24%)
VClause: 2380 -> 2374 (-0.25%)
Copies: 26836 -> 25131 (-6.35%)
Branches: 2494 -> 2492 (-0.08%)
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9196 >
2021-04-13 18:40:57 +00:00
Daniel Schürmann
b2a6346df7
aco/spill: spill phi constants and exec directly to VGPR
...
This lets us avoid some CSSA copies.
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9196 >
2021-04-13 18:40:57 +00:00
Daniel Schürmann
99936d7142
aco/spill: reload spilled exec masks directly to exec
...
This handles the case of
exec = p_linear_phi %a, %b
where %a or %b might have been spilled.
By directly reloading these variables into the exec mask register,
we can avoid additional CSSA parallelcopies.
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9196 >
2021-04-13 18:40:57 +00:00
Daniel Schürmann
beb292343a
aco/spill: refactor spill decision taking
...
No fossil-db changes.
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9196 >
2021-04-13 18:40:57 +00:00
Boris Brezillon
17429b8ad4
panfrost: Pass a tile enable map to avoid reloading untouched tiles
...
We only do that when there are more than one damage rectangle and the
number of tiles to reload is significantly lower than the total number
of tiles covered by the damage extent, otherwise the overhead of the
TEM read might defeat the optimization that we might get from using one.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
988b0d2863
panfrost: Kill the old tile-buffer preload logic
...
Now that the gallium driver uses the pan_preload() helpers we can get
rid of the code in pan_blit.c and all its dependencies.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
ff3eada7eb
panfrost: Use the generic preload and FB helpers in the gallium driver
...
We also rework the code to have the FB descriptor shared by the tiler
and fragment jobs, instead of allocating a separate FB descriptor for
tiler jobs.
The new implementation seems to fix a few dEQP failures on T720.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
d7008a6d7b
panfrost: Fix partial update
...
The KHR_partial_update spec says:
"
If EGL_EXT_buffer_age is supported, the contents of the buffer inside
the damage region may also be relied upon to contain the same content
as the last time they were defined for the current back buffer.
"
but we currently assume that everything inside the damage region will
be overwritten by new data and that the previous content doesn't need
to be reloaded.
Let's get rid of the damage rect inversion logic for now and reload
everything inside the damage extent. We will optimize things further
down the line, using pre-frame DCDs on Bifrost, and a tile enable map
on Midgard.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
8ba2f9f698
panfrost: Create a blitter library to replace the existing preload helpers
...
pan_blitter.c is meant to replace the pan_blit.c which currently
provides helpers to preload the tile buffer. Some changes
are worth mentioning:
- we use pre-frame DCDs on Bifrost (Midgard still uses a tiler job
to preload the tile buffer)
- the blit shaders are now stored in a hash table and created lazily
- we now cache blend shader binaries and blit RSDs too
This library will soon be extended to cover regular blits.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
a11807b795
panfrost: Always pass a non-NULL screen to set_damage_region()
...
We will soon have a different handling for Bifrost, and we need to know
which GPU we're targeting to choose the right path.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
c5d6abae5b
panfrost: Extend pan_fb_info to allow passing pre/post frame DCDs
...
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
c52c3e2424
panfrost: Extend pan_fb_info to allow passing a tile enable map
...
We will use this tile enable map to implement KHR_partial_update and
replace the current solution where the preload process is done by
inverting damage regions, merging the resulting inverted regions and
issuing preloading draws for those rectangles.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
96b71a59c0
panfrost: Decode pre/post frame DCDs
...
Bifrost FB descritptors can be attached 3 DCDs describing pre/post frame
operations (pre frames DCDs can be used to preload the tile buffers).
Decode them when mode != NEVER.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
9f1bbced3c
panfrost: s/pandecode_vertex_tiler_postfix_pre/pandecode_dcd/
...
We will soon use this function to decode pre/post frame DCDs which are
not part of a job descriptor.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
9d7a5a6b75
panfrost: Add the early ZS pre frame mode
...
We will use that one when preloading ZS buffers.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
bacd9df8de
panfrost: Add align info to the draw and draw padding definitions
...
Needed if we want to allocate pre/post frame draw descriptors.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
25f948d4d9
panfrost: Add an helper to emit fragment jobs
...
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
387f8c037d
panfrost: Add various helpers to simplify FB desc emission
...
Now that image and image views are gallium-agnostic and contain enough
information, we can provide generic helpers to emit FB descriptors and
their dependencies, thread storage and tiler descriptors.
This helpers will be re-used in the Vulkan driver.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
0fc7c1f971
pan/midg: Use the sampler index passed to the texture instruction
...
Sampler index and texture index can differ.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
477c67d79e
panfrost: Pass a const device to panfrost_sample_positions()
...
This function doesn't modify the dev object, we can constify this
argument.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
e23cbac70e
panfrost: Provide a helper to retrieve image surface pointers
...
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
af34e29f15
panfrost: Provide a helper to calculate the polygon list size
...
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
f5d7c419e7
panfrost: Pass an image view to panfrost_new_texture()
...
pan_image_view contains everything we need to emit a texture
descriptor. Pass this object instead of the dozen of arguments
we have now.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
9d0ad7fd2e
panfrost: Patch the gallium driver to use pan_image_layout_init()
...
Now that we have a generic implementation, we can use it and get rid
of panfrost_setup_layout().
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
051d62cf04
panfrost: Add a pan_image_layout_init() helper
...
We will need it for Vulkan.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
f1d4df1cd7
panfrost: Move special Z32_S8X24 case out of panfrost_setup_layout()
...
We are about to move the panfrost_setup_layout() logic out of the
gallium driver, and the Z32_S8X24 split is not mandatory (some GPU
support this format natively). Let's move this special case out of
panfrost_setup_layout() and patch the format of the first plane
instead.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
50f39908aa
panfrost: Move out-of-band CRC info to pan_image
...
We already have the data BO stored there, let's move the out-of-band
CRC BO too. We also add a CRC mode to pan_image_layout so we can easily
know where the CRC resides.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
1c7e8a1692
panfrost: Add an offset field so we can attach a sub-buffer to an image
...
Needed for Vulkan.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
8bd70ea6ea
panfrost: Split pan_image in two
...
Move the image view bit out of pan_image and create a separate
pan_image_view struct. Once this is done we can embed a pan_image
object in panfrost_resource which will be referenced by the image
view that we pass to panfrost_load_{midgard,bifrost}().
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
cfe9bca912
panfrost: Add extra info to the pan_image_layout struct
...
This means duplicating some of the bits we already have in the
pipe_resource object embedded in panfrost_resource, but if will also
allow us to move some code out of the gallium driver without requiring
copy those fields every time we call a generic helper.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00
Boris Brezillon
efcb1e494b
panfrost: Stop passing a depth > 1 when creating 2D textures
...
The depth field is ignored if dim != 3D, but it's a bit confusing.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10033 >
2021-04-13 18:06:37 +00:00