[MIPS GlobalISel] Refactor MipsRegisterBankInfo [NFC]
authorPetar Avramovic <Petar.Avramovic@rt-rk.com>
Tue, 15 Oct 2019 09:18:42 +0000 (09:18 +0000)
committerPetar Avramovic <Petar.Avramovic@rt-rk.com>
Tue, 15 Oct 2019 09:18:42 +0000 (09:18 +0000)
commitf7c213c9c43cba30fb22edde29ccbd19131660e4
tree64d9da36a6204625883d1a04e1ebbd4330c18092
parent9318c94ebbf28beb843852246beb34082c659bae
[MIPS GlobalISel] Refactor MipsRegisterBankInfo [NFC]

Check if size of operand LLT matches sizes of available register banks
before inspecting the opcode in order to reduce number of checks.
Factor commonly used pieces of code into functions.

Differential Revision: https://reviews.llvm.org/D68866

llvm-svn: 374870
llvm/lib/Target/Mips/MipsRegisterBankInfo.cpp
llvm/lib/Target/Mips/MipsRegisterBankInfo.h