mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 09:38:07 +02:00
aco: Add RegisterDemand(Temp) constructor
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29730>
This commit is contained in:
parent
ca7ce1fb33
commit
416a016127
1 changed files with 7 additions and 0 deletions
|
|
@ -1015,6 +1015,13 @@ private:
|
|||
struct RegisterDemand {
|
||||
constexpr RegisterDemand() = default;
|
||||
constexpr RegisterDemand(const int16_t v, const int16_t s) noexcept : vgpr{v}, sgpr{s} {}
|
||||
constexpr RegisterDemand(Temp t) noexcept
|
||||
{
|
||||
if (t.regClass().type() == RegType::sgpr)
|
||||
sgpr = t.size();
|
||||
else
|
||||
vgpr = t.size();
|
||||
}
|
||||
int16_t vgpr = 0;
|
||||
int16_t sgpr = 0;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue