This is an archive of the discontinued LLVM Phabricator instance.

[ARM] Fix unwind info for Thumb1 functions that save high registers.
ClosedPublic

Authored by efriedma on Jun 28 2019, 4:17 PM.

Details

Summary

There were two issues here: one, some of the relevant instructions were missing the expected "FrameSetup" flag, and two, ARMAsmPrinter::EmitUnwindingInstruction wasn't expecting "mov" instructions in the prologue.

I'm sticking the additional state into ARMFunctionInfo so it's obvious it only applies to the current function.

I considered a few alternative approaches where we would compute the correct unwind information as part of the prologue/epilogue lowering, but it seems like a lot of work to introduce pseudo-instructions, and the current code seems to be reliable enough.

Fixes https://bugs.llvm.org/show_bug.cgi?id=42408.

Diff Detail

Repository
rL LLVM

Event Timeline

efriedma created this revision.Jun 28 2019, 4:17 PM
Herald added a project: Restricted Project. · View Herald TranscriptJun 28 2019, 4:17 PM
ostannard accepted this revision.Jul 2 2019, 3:40 AM

LGTM, thanks.

This revision is now accepted and ready to land.Jul 2 2019, 3:40 AM
This revision was automatically updated to reflect the committed changes.