File tree Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -68,6 +68,8 @@ def __repr__(self):
68
68
@staticmethod
69
69
def is_renamed (ty ):
70
70
"""Indicate if register type should be subject to renaming"""
71
+ if ty == RegisterType .HINT :
72
+ return False
71
73
return True
72
74
73
75
@staticmethod
@@ -99,21 +101,21 @@ def list_registers(
99
101
gprs += gprs_extra
100
102
vregs += vregs_extra
101
103
102
- hints = (
103
- [f"t{ i } " for i in range (100 )]
104
- )
105
-
106
104
return {
107
105
RegisterType .GPR : gprs ,
108
106
RegisterType .StackGPR : stack_locations ,
109
107
RegisterType .StackMVE : qstack_locations ,
110
108
RegisterType .MVE : vregs ,
111
- RegisterType .HINT : hints ,
109
+ RegisterType .HINT : [] ,
112
110
}[reg_type ]
113
111
114
112
@staticmethod
115
113
def find_type (r ):
116
114
"""Find type of architectural register"""
115
+
116
+ if r .startswith ("hint_" ):
117
+ return RegisterType .HINT
118
+
117
119
for ty in RegisterType :
118
120
if r in RegisterType .list_registers (ty ):
119
121
return ty
@@ -126,14 +128,15 @@ def from_string(string):
126
128
"stack" : RegisterType .StackGPR ,
127
129
"mve" : RegisterType .MVE ,
128
130
"gpr" : RegisterType .GPR ,
131
+ "hint" : RegisterType .HINT ,
129
132
}.get (string , None )
130
133
131
134
def default_aliases ():
132
135
return {"lr" : "r14" }
133
136
134
137
def default_reserved ():
135
138
"""Return the list of registers that should be reserved by default"""
136
- return set (["r13" , "r14" ])
139
+ return set (["r13" , "r14" ] + RegisterType . list_registers ( RegisterType . HINT ) )
137
140
138
141
139
142
class LeLoop (Loop ):
You can’t perform that action at this time.
0 commit comments