[RISCV][NFC] Add RISCVSubtarget field to RISCVExpandPseudo and RISCVPreRAExpandPseudo
authorAlex Bradbury <asb@igalia.com>
Fri, 21 Jul 2023 15:37:50 +0000 (16:37 +0100)
committerAlex Bradbury <asb@igalia.com>
Fri, 21 Jul 2023 15:50:11 +0000 (16:50 +0100)
commitb81b4cfc654784f19af7296f01719630ea24fc89
treea388c4a7a4c3bbbe1e0b0ca590ee373d2a5afbf5
parentd3aabeb7b56b27cfacdc8af74d49d72186d89725
[RISCV][NFC] Add RISCVSubtarget field to RISCVExpandPseudo and RISCVPreRAExpandPseudo

To my eye, it's cleaner to just get hold of STI in runOnMachineFunction
(as we do already for InstrInfo) and then accessing the field as needed
rather than to have repeated lookup code in the member functions or
helpers that need it.

Differential Revision: https://reviews.llvm.org/D155840
llvm/lib/Target/RISCV/RISCVExpandPseudoInsts.cpp