mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 03:08:05 +02:00
agx: commonize ra_class
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31532>
This commit is contained in:
parent
a07faaf6c9
commit
ab8d1cfe95
2 changed files with 17 additions and 18 deletions
|
|
@ -269,6 +269,23 @@ agx_is_equiv(agx_index left, agx_index right)
|
|||
return (left.type == right.type) && (left.value == right.value);
|
||||
}
|
||||
|
||||
enum ra_class {
|
||||
/* General purpose register */
|
||||
RA_GPR,
|
||||
|
||||
/* Memory, used to assign stack slots */
|
||||
RA_MEM,
|
||||
|
||||
/* Keep last */
|
||||
RA_CLASSES,
|
||||
};
|
||||
|
||||
static inline enum ra_class
|
||||
ra_class_for_index(agx_index idx)
|
||||
{
|
||||
return idx.memory ? RA_MEM : RA_GPR;
|
||||
}
|
||||
|
||||
enum agx_icond {
|
||||
AGX_ICOND_UEQ = 0,
|
||||
AGX_ICOND_ULT = 1,
|
||||
|
|
|
|||
|
|
@ -17,24 +17,6 @@
|
|||
#include "shader_enums.h"
|
||||
|
||||
/* SSA-based register allocator */
|
||||
|
||||
enum ra_class {
|
||||
/* General purpose register */
|
||||
RA_GPR,
|
||||
|
||||
/* Memory, used to assign stack slots */
|
||||
RA_MEM,
|
||||
|
||||
/* Keep last */
|
||||
RA_CLASSES,
|
||||
};
|
||||
|
||||
static inline enum ra_class
|
||||
ra_class_for_index(agx_index idx)
|
||||
{
|
||||
return idx.memory ? RA_MEM : RA_GPR;
|
||||
}
|
||||
|
||||
struct phi_web_node {
|
||||
/* Parent index, or circular for root */
|
||||
uint32_t parent;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue