This is an archive of the discontinued LLVM Phabricator instance.

[RISCV] Eliminate the need to pass both RISCVSubtarget and MCSubtargetInfo to isCompressibleInst.
ClosedPublic

Authored by craig.topper on Jan 17 2023, 1:56 PM.

Details

Summary

RISCVSubtarget should be a superclass of MCSubtargetInfo so should
have all the same information. Now we pass RISCVSubtarget by
reference and name it STI.

Confusingly, we seem to have been using an MCSubtargetInfo from
the TargetMachine rather than the one associated with the function
we are operating. I'm going to assume that was a mistake and not
intentional.

Diff Detail

Event Timeline

craig.topper created this revision.Jan 17 2023, 1:56 PM
Herald added a project: Restricted Project. · View Herald TranscriptJan 17 2023, 1:56 PM
craig.topper requested review of this revision.Jan 17 2023, 1:56 PM
Herald added a project: Restricted Project. · View Herald TranscriptJan 17 2023, 1:56 PM
This revision is now accepted and ready to land.Jan 17 2023, 5:39 PM
This revision was landed with ongoing or failed builds.Jan 17 2023, 6:28 PM
This revision was automatically updated to reflect the committed changes.