[MIPS][microMIPS] Fix PseudoMTLOHI_MM matching and expansion
authorSimon Atanasyan <simon@atanasyan.com>
Wed, 13 Mar 2019 11:04:38 +0000 (11:04 +0000)
committerSimon Atanasyan <simon@atanasyan.com>
Wed, 13 Mar 2019 11:04:38 +0000 (11:04 +0000)
commitc2b975a75cad1d8b0beeb532cc375432dc62f900
tree2f99f5f74c2d2e0d821173ce65f0925d52dc5064
parentc711002041531292f1ecf2bda0dcf6003d1db991
[MIPS][microMIPS] Fix PseudoMTLOHI_MM matching and expansion

On micromips MipsMTLOHI is always matched to PseudoMTLOHI_DSP regardless
of +dsp argument. This patch checks is HasDSP predicate is present for
PseudoMTLOHI_DSP so PseudoMTLOHI_MM can be matched when appropriate.

Add expansion of PseudoMTLOHI_MM instruction into a mtlo/mthi pair.

Patch by Mirko Brkusanin.

Differential Revision: http://reviews.llvm.org/D59203

llvm-svn: 356039
llvm/lib/Target/Mips/MipsDSPInstrInfo.td
llvm/lib/Target/Mips/MipsSEInstrInfo.cpp
llvm/test/CodeGen/Mips/micromips-pseudo-mtlohi-expand.ll [new file with mode: 0644]