]> granicus.if.org Git - llvm/commit
RegAllocPBQP: Do not assign reserved physical register
authorMatthias Braun <matze@braunis.de>
Thu, 8 Jun 2017 21:30:54 +0000 (21:30 +0000)
committerMatthias Braun <matze@braunis.de>
Thu, 8 Jun 2017 21:30:54 +0000 (21:30 +0000)
commit9b4cf76a1ef63a2b160f431ad2c9d76dfac49942
treec829d54dc417cc12068a6613f6e4607adc501cff
parentfe0f895a8f56e7c71d13d10c1a95d489f559d885
RegAllocPBQP: Do not assign reserved physical register

(0) RegAllocPBQP: Since getRawAllocationOrder() may return a collection that includes reserved physical registers, iterate to find an un-reserved physical register.

(1) VirtRegMap: Enforce the invariant: "no reserved physical registers" in assignVirt2Phys(). Previously, this was checked only after the fact in VirtRegRewriter::rewrite.

(2) MachineVerifier: updated the test per MatzeB's review.

(3) +testcase

Patch by Nick Johnson<Nicholas.Paul.Johnson@deshawresearch.com>!

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@305016 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/CodeGen/VirtRegMap.h
lib/CodeGen/MachineVerifier.cpp
lib/CodeGen/RegAllocPBQP.cpp
lib/CodeGen/VirtRegMap.cpp
test/CodeGen/Mips/pbqp-reserved-physreg.ll [new file with mode: 0644]