[LLVMdev] Hit a snag while attempting to write a backend - any advice?

Jakob Stoklund Olesen stoklund at 2pi.dk
Thu Mar 21 11:51:11 PDT 2013


On Mar 21, 2013, at 6:09 AM, Tim Northover <t.p.northover at gmail.com> wrote:

> Ah! It looks like the isReturn is to blame then. LLVM is presumably
> going through adding an implicit use of any register that will hold a
> return value to instructions that will actually return. This would
> prevent it from removing instructions that actually define R0 as dead
> code (it's "used" by the RET and should certainly be defined by the
> time the function does return).

This behaviour was removed recently. Now, targets themselves have to add return values as implicit uses on return instructions in their LowerReturn() functions.

/jakob




More information about the llvm-dev mailing list