This is an archive of the discontinued LLVM Phabricator instance.

[NFC][RISCV] Move getSEWLMULRatio function to header
ClosedPublic

Authored by asi-sc on Oct 3 2022, 9:40 AM.

Details

Summary

More uses of getSEWLMULRatio will be added in D130895.

Diff Detail

Event Timeline

asi-sc created this revision.Oct 3 2022, 9:40 AM
Herald added a project: Restricted Project. · View Herald TranscriptOct 3 2022, 9:40 AM
asi-sc requested review of this revision.Oct 3 2022, 9:40 AM
craig.topper added inline comments.Oct 3 2022, 10:41 AM
llvm/lib/Target/RISCV/MCTargetDesc/RISCVBaseInfo.cpp
191

Is the namespace qualifier on decodeVLMUL still needed?

asi-sc updated this revision to Diff 464917.Oct 4 2022, 1:38 AM

Addressed review comments

frasercrmck accepted this revision.Oct 4 2022, 2:28 AM

LGTM

llvm/lib/Target/RISCV/MCTargetDesc/RISCVBaseInfo.cpp
191

I don't know if this is something that benefits from a structured binding.

This revision is now accepted and ready to land.Oct 4 2022, 2:28 AM
asi-sc added inline comments.Oct 4 2022, 9:22 AM
llvm/lib/Target/RISCV/MCTargetDesc/RISCVBaseInfo.cpp
191

Honestly, exactly here I don't see any reason to use structured binding as the current solution has better readability (imo) and there is no need for extra optimizations. Though, if anybody has concerns regarding to this, let's use structured bindings.

asi-sc added a comment.Oct 5 2022, 1:23 AM

Thanks for the review.
@frasercrmck, could you please submit the patch on my behalf? Author: Anton Sidorenko <anton.sidorenko@syntacore.com>

This revision was automatically updated to reflect the committed changes.