[llvm-dev] MachineBasicBlock asserts in erase() and move()

Jonas Paulsson via llvm-dev llvm-dev at lists.llvm.org
Mon Sep 16 01:53:10 PDT 2019


Hi,

It has been discovered that SystemZTargetLowering::emitSelect() calls 
erase() on a range of instructions on the wrong MBB, without any assert 
triggering with seemingly correct behaviour (!). StartMBB->erase() 
should be JoinMBB->erase() since that's where the SelectPseudo(s) will 
reside.

I am not sure why this "works" at the moment, or why there is not an 
assert checking for this. I made a patch to add asserts in erase() and 
remove() methods (attached), but found no other cases, though.

Is there a reason this is not asserted in ilist?

/Jonas


-------------- next part --------------
A non-text attachment was scrubbed...
Name: latest.patch
Type: text/x-patch
Size: 2351 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20190916/489c4a8e/attachment.bin>


More information about the llvm-dev mailing list