This is an archive of the discontinued LLVM Phabricator instance.

[mips] Use the delay slot filler to convert branches for microMIPSR6.
ClosedPublic

Authored by sdardis on Nov 21 2017, 9:22 AM.

Details

Summary

The MIPS delay slot filler converts delay slot branches into compact
forms for the MIPS ISAs which support them. For branches that compare
(in)equality with with zero, it converts them into branches with implict
zero register operands. These branches have a slightly greater range
than normal two register operands branches.

Changing the branches at this point in the pipeline offers the long
branch pass the ability to mark better judgements if a long branch
sequence is required.

Diff Detail

Repository
rL LLVM

Event Timeline

sdardis created this revision.Nov 21 2017, 9:22 AM
atanasyan accepted this revision.Nov 22 2017, 5:17 AM

LGTM with the only nit.

test/CodeGen/Mips/llvm-ir/sub.ll
225 ↗(On Diff #123818)

Does it make a sense to keep this line but replace jr by jrc?

This revision is now accepted and ready to land.Nov 22 2017, 5:17 AM
sdardis added inline comments.Nov 22 2017, 8:28 AM
test/CodeGen/Mips/llvm-ir/sub.ll
225 ↗(On Diff #123818)

I elected to remove it as it isn't really providing any value for the purposes of the test. None of the other test stanzas included any sort of end marker, so I removed it in this case.

atanasyan added inline comments.Nov 22 2017, 8:29 AM
test/CodeGen/Mips/llvm-ir/sub.ll
225 ↗(On Diff #123818)

I see. ok

This revision was automatically updated to reflect the committed changes.