s390x: update some regalloc metadata to remove use of reg_mod. (#4856)

* s390x: update some regalloc metadata to remove use of `reg_mod`.

This is a step toward ultimately removing modify-operands, which along
with removal of pinned vregs, lets us move to a completely
constraint-based and fully-SSA regalloc input and get some nice
advantages eventually.

There are still a few uses of `mod` operands and pinned vregs remaining,
especially around the "regpair" abstraction. Those proved to be a bit
trickier to update though, so will have to be done separately.

* Review feedback: restore two-arg pretty-print form.

* Review feedback.
This commit is contained in:
Chris Fallin
2022-09-09 18:43:36 -05:00
committed by GitHub
parent 2986f6b0ff
commit 96bfd4e8c0
16 changed files with 653 additions and 420 deletions

View File

@@ -499,6 +499,7 @@ impl ABIMachineSpec for S390xMachineDeps {
insts.push(Inst::AluRUImm32 {
alu_op: ALUOp::AddLogical64,
rd: into_reg,
ri: into_reg.to_reg(),
imm,
});
}
@@ -546,12 +547,14 @@ impl ABIMachineSpec for S390xMachineDeps {
insts.push(Inst::AluRSImm16 {
alu_op: ALUOp::Add64,
rd: writable_stack_reg(),
ri: stack_reg(),
imm,
});
} else {
insts.push(Inst::AluRSImm32 {
alu_op: ALUOp::Add64,
rd: writable_stack_reg(),
ri: stack_reg(),
imm,
});
}