[RISCV] Allow fp as an alias of s0
authorAlex Bradbury <asb@lowrisc.org>
Mon, 11 Mar 2019 21:35:26 +0000 (21:35 +0000)
committerAlex Bradbury <asb@lowrisc.org>
Mon, 11 Mar 2019 21:35:26 +0000 (21:35 +0000)
commitb6d322bdc25e67d538c1d14d3ead9724837f057c
tree50715ae0be5eb68a929f11300d5defd275443c86
parent231306bd436e322f571182f56928761db54c3755
[RISCV] Allow fp as an alias of s0

The RISC-V Assembly Programmer's Manual defines fp as another alias of x8.
However, our tablegen rules only recognise s0. This patch adds fp as another
alias of x8. GCC also accepts fp.

Differential Revision: https://reviews.llvm.org/D59209
Patch by Ferran Pallarès Roca.

llvm-svn: 355867
llvm/lib/Target/RISCV/RISCVRegisterInfo.td
llvm/test/MC/RISCV/rvi-alternate-abi-names.s [new file with mode: 0644]