This is an archive of the discontinued LLVM Phabricator instance.

[RISCV] Remove XLen field from RISCVSubtarget [nfc]
ClosedPublic

Authored by reames on Aug 31 2023, 12:00 PM.

Details

Summary

We also have IsRV64 which, unless I'm missing something, contains the same information. I did add an assert to catch the case where the triple and cpu are out of sync. I haven't checked, but I assume a more useful error is reported by clang. Or at least, I can't think of a configuration where a rv32 triple and a rv64 cpu definition (and thus ISEL) make sense. Posting this for review mostly to make sure I'm not missing something on that point.

Diff Detail

Event Timeline

reames created this revision.Aug 31 2023, 12:00 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 31 2023, 12:00 PM
reames requested review of this revision.Aug 31 2023, 12:00 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 31 2023, 12:00 PM

There's a CPU check in llvm/lib/Target/RISCV/MCTargetDesc//RISCVBaseInfo.cpp in the validate function

This revision is now accepted and ready to land.Aug 31 2023, 7:33 PM
This revision was automatically updated to reflect the committed changes.