mesa/src/panfrost/compiler
Ludvig Lindau 4573110e4e pan/v9+: Make texel buffers use BufferDescriptor
Texel buffers are currently described by a TextureDescriptor,which leads
to restrictive limits on size and alignment.
These limits can be avoided by using a BufferDescriptor instead.

This requires first embedding a ConversionDescriptor into some of the
currently empty space of the BufferDescriptor, and modifying the
compiler so that instead of outputting TEX_FETCH, it will:

1. Load the ConversionDescriptor with LD_PKA
2. Get the buffer address with LEA_BUF[_IMM]
3. Use LD_CVT to get the value

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37007>
2025-11-07 17:03:53 +00:00
..
bifrost panfrost: Rename (LD|LEA)_BUFFER to (LD|LEA)_PKA 2025-11-07 17:03:53 +00:00
test treewide: use UTIL_DYNARRAY_INIT 2025-11-04 13:39:48 +00:00
valhall pan/va: Add LD_CVT 2025-11-07 17:03:53 +00:00
bi_builder.h.py build: avoid redefining unreachable() which is standard in C23 2025-07-31 17:49:42 +00:00
bi_helper_invocations.c panfrost: Add BI_OPCODE_WMASK to bi_instr_uses_helpers 2025-02-28 08:55:32 +00:00
bi_iterator_schedule.c treewide: use UTIL_DYNARRAY_INIT 2025-11-04 13:39:48 +00:00
bi_layout.c
bi_liveness.c pan: Make W_entry loop aware 2025-11-05 16:15:11 +00:00
bi_lower_divergent_indirects.c all: rename gl_shader_stage to mesa_shader_stage 2025-08-06 10:28:40 +08:00
bi_lower_swizzle.c pan/bi: Propagate MKVEC.v2i8 and V2X8_TO_V2X16 for replicate swizzle 2025-09-08 14:25:22 +00:00
bi_opcodes.c.py pan/bi: ignore ftz mode when scheduling int instructions 2025-04-10 16:21:09 +00:00
bi_opcodes.h.py pan/bi: ignore ftz mode when scheduling int instructions 2025-04-10 16:21:09 +00:00
bi_opt_constant_fold.c panfrost: fix shift overflow in bi_fold_constant 2024-01-26 09:40:48 +00:00
bi_opt_control_flow.c util/dynarray: infer type in append 2025-10-24 18:32:07 +00:00
bi_opt_copy_prop.c panfrost: use an accessor function to read from bi_opcode_props 2025-02-20 23:33:00 +00:00
bi_opt_cse.c panfrost: Make instrs_equal check res table/index 2025-11-07 17:03:53 +00:00
bi_opt_dce.c treewide: use BITSET_CALLOC 2025-10-09 12:29:55 +00:00
bi_opt_dual_tex.c build: avoid redefining unreachable() which is standard in C23 2025-07-31 17:49:42 +00:00
bi_opt_mod_props.c treewide: use BITSET_CALLOC 2025-10-09 12:29:55 +00:00
bi_opt_push_ubo.c pan: Use a consistent pan_ prefix across src/panfrost/* 2025-05-21 14:58:20 +02:00
bi_packer.c.py build: avoid redefining unreachable() which is standard in C23 2025-07-31 17:49:42 +00:00
bi_pressure_schedule.c treewide: use BITSET_BYTES, BITSET_RZALLOC 2025-11-05 18:44:23 +00:00
bi_print.c
bi_print_common.c
bi_print_common.h
bi_printer.c.py panfrost: fix debug print of spilled registers 2025-09-03 16:19:42 -03:00
bi_quirks.h pan/kmod: Expose the raw GPU ID through pan_kmod_dev_props 2025-07-09 08:40:12 +00:00
bi_ra.c pan: Add spill cost metric 2025-11-05 16:15:11 +00:00
bi_ra_ssa.c panfrost/panvk: Add size calculations to compiler register code 2025-10-31 10:12:21 +00:00
bi_spill_ssa.c panfrost: Rename (LD|LEA)_BUFFER to (LD|LEA)_PKA 2025-11-07 17:03:53 +00:00
bi_swizzles.c.py panfrost: use bifrost instruction table for bi_lower_swizzle 2025-04-10 10:15:46 -07:00
bi_swizzles.h panfrost: use bifrost instruction table for bi_lower_swizzle 2025-04-10 10:15:46 -07:00
bi_test.h pan: Use a consistent pan_ prefix across src/panfrost/* 2025-05-21 14:58:20 +02:00
bi_validate.c panvk: fix typo in printf in bi_validate 2025-06-20 08:29:54 +00:00
bifrost.h pan/bi: Normalize with pan_model.rates 2025-09-16 15:54:48 +00:00
bifrost_compile.c pan/v9+: Make texel buffers use BufferDescriptor 2025-11-07 17:03:53 +00:00
bifrost_compile.h pan/va: Add late lowering passes for texel buffers 2025-11-07 17:03:53 +00:00
bifrost_isa.py panfrost: Update bifrost_isa.py to support saturate for valhall 2025-05-22 14:39:32 +00:00
bifrost_nir.h pan/bi: Stop exposing bifrost_nir_lower_load_output 2025-08-20 12:11:43 +00:00
bifrost_nir_algebraic.py pan/bi: Handle needless conversions in nir_lower_bool_to_bitsize 2025-08-11 11:38:57 +00:00
bir.c build: avoid redefining unreachable() which is standard in C23 2025-07-31 17:49:42 +00:00
cmdline.c pan/bi: use os_read_file-helper 2025-08-21 08:45:33 +00:00
compiler.h pan: Make W_entry loop aware 2025-11-05 16:15:11 +00:00
gen_disasm.py bi: Move bi_disasm definitions to their own header 2024-06-17 07:31:50 +00:00
IR_pseudo.xml pan/bi: rework memory barriers 2025-06-13 12:05:02 +02:00
meson.build pan: Lift pan_get_model into its own lib 2025-09-16 15:54:48 +00:00
nodearray.h
Notes.txt
README.md

Bifrost compiler

Register file

Defined partially in software, partially in hardware.

Blend shaders

R0 - R3: input (color #0) R4 - R7: input (color #1) R8 - R15: general purpose R48: return address

Fragment

Anything live during BLEND must respect blend shader registers.

R0 - R3: preloaded (message #0) R4 - R7: preloaded (message #1) R57 - R63: preloaded (various)

R0 - R15: general purpose (full threads) R48 - R63: general purpose (full threads)

R32 - R47: general purpose (half threads, or v6)