pan/bi: Move bi_word_node to common code
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11327>
This commit is contained in:
committed by
Marge Bot
parent
7ad9e1e5a5
commit
7db6d8d748
@@ -34,13 +34,6 @@ bi_is_copy(bi_instr *ins)
|
||||
|| ins->src[0].type == BI_INDEX_CONSTANT);
|
||||
}
|
||||
|
||||
static inline unsigned
|
||||
bi_word_node(bi_index idx)
|
||||
{
|
||||
assert(idx.type == BI_INDEX_NORMAL && !idx.reg);
|
||||
return (idx.value << 2) | idx.offset;
|
||||
}
|
||||
|
||||
static bool
|
||||
bi_reads_fau(bi_instr *ins)
|
||||
{
|
||||
|
||||
@@ -989,6 +989,12 @@ bi_builder_insert(bi_cursor *cursor, bi_instr *I)
|
||||
unreachable("Invalid cursor option");
|
||||
}
|
||||
|
||||
static inline unsigned
|
||||
bi_word_node(bi_index idx)
|
||||
{
|
||||
assert(idx.type == BI_INDEX_NORMAL && !idx.reg);
|
||||
return (idx.value << 2) | idx.offset;
|
||||
}
|
||||
|
||||
/* NIR passes */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user