mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-04-19 10:10:39 +02:00
agx: add num_successors helper
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28483>
This commit is contained in:
parent
da18ac5dfa
commit
5bfdb20dac
1 changed files with 7 additions and 0 deletions
|
|
@ -562,6 +562,13 @@ agx_num_predecessors(agx_block *block)
|
|||
return util_dynarray_num_elements(&block->predecessors, agx_block *);
|
||||
}
|
||||
|
||||
static inline unsigned
|
||||
agx_num_successors(agx_block *block)
|
||||
{
|
||||
STATIC_ASSERT(ARRAY_SIZE(block->successors) == 2);
|
||||
return (block->successors[0] ? 1 : 0) + (block->successors[1] ? 1 : 0);
|
||||
}
|
||||
|
||||
static inline agx_block *
|
||||
agx_start_block(agx_context *ctx)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue