This is an archive of the discontinued LLVM Phabricator instance.

[CodeGen] Set FrameSetup/FrameDestroy on BUNDLE instructions
ClosedPublic

Authored by bjope on Aug 13 2018, 8:20 AM.

Details

Summary

If any of the bundled instructions are marked as FrameSetup
or FrameDestroy, then that property is set on the BUNDLE
instruction as well.

As long as the scheduler/packetizer aren't mixing
prologue/epilogue instructions (i.e. all the bundled
instructions have the same property) then this simply gives
the bundle the correct property (so when using a bundle
iterator in late passes a bundle will be correctly identified
as FrameSetup/FrameDestroy).

When for example bundling a mix of FrameSetup instructions
with non-FrameSetup instructions it could be discussed if
the bundle should have the property or not. The choice here
has been to set these properties on the BUNDLE instruction if
any of the bundled instructions have the property set.

Diff Detail

Repository
rL LLVM

Event Timeline

bjope created this revision.Aug 13 2018, 8:20 AM
vsk added a subscriber: vsk.Aug 16 2018, 3:10 PM

Not having worked in this area I can't give an official lgtm, but this seems reasonable to me.

kparzysz accepted this revision.Aug 23 2018, 7:13 AM
This revision is now accepted and ready to land.Aug 23 2018, 7:13 AM
This revision was automatically updated to reflect the committed changes.