[mips][FastISel] Clobber HI0/LO0 registers in MUL instructions.
authorVasileios Kalintiris <Vasileios.Kalintiris@imgtec.com>
Mon, 1 Jun 2015 15:48:09 +0000 (15:48 +0000)
committerVasileios Kalintiris <Vasileios.Kalintiris@imgtec.com>
Mon, 1 Jun 2015 15:48:09 +0000 (15:48 +0000)
commit30b5412d92e7202566bfa039f81344a3638d25c6
tree71bc7d25c6e5f49e2ac872ac189f2a9bac1b74d6
parent1758082f64077aeaa33b397a561e0483a2e02d37
[mips][FastISel] Clobber HI0/LO0 registers in MUL instructions.

Summary:
The contents of the HI/LO registers are unpredictable after the execution of
the MUL instruction. In addition to implicitly defining these registers in the
MUL instruction definition, we have to mark those registers as dead too.

Without this the fast register allocator is running out of registers when the
MUL instruction is followed by another one that tries to allocate the AC0
register.

Based on a patch by Reed Kotler.

Reviewers: dsanders, rkotler

Subscribers: llvm-commits, rfuhler

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238755 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/Mips/MipsFastISel.cpp
test/CodeGen/Mips/Fast-ISel/mul1.ll [new file with mode: 0644]