[PBQP] Improve the assert for conservatively allocatables.

Remember if the node ever was in this state instead of checking just the
final state.

Reviewed by Arnaud de Grandmaison.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@229400 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Jonas Paulsson
2015-02-16 15:39:26 +00:00
parent 989552ca7f
commit c21da273fe
2 changed files with 13 additions and 2 deletions

View File

@@ -190,7 +190,7 @@ namespace PBQP {
// Although a conservatively allocatable node can be allocated to a register,
// spilling it may provide a lower cost solution. Assert here that spilling
// is done by choice, not because there were no register available.
if (G.getNodeMetadata(NId).isConservativelyAllocatable())
if (G.getNodeMetadata(NId).wasConservativelyAllocatable())
assert(hasRegisterOptions(v) && "A conservatively allocatable node "
"must have available register options");