This is an archive of the discontinued LLVM Phabricator instance.

[RISCV] Don't set the SplatOperand flag on intrinsics that take a shift amount.
ClosedPublic

Authored by craig.topper on Mar 29 2021, 3:32 PM.

Details

Summary

The shift amount should always be a vector or an XLen scalar.
The SplatOperand flag is used to indicate we need to legalize
non-XLen scalars including special handling for i64 on RV32.
This will prevent us from silently adjusting these operands if
the intrinsics are misused.

I'll probably adjust the name of the SplatOperand flag slightly
in a follow up patch.

Diff Detail

Event Timeline

craig.topper created this revision.Mar 29 2021, 3:32 PM
craig.topper requested review of this revision.Mar 29 2021, 3:32 PM
Herald added a project: Restricted Project. · View Herald TranscriptMar 29 2021, 3:32 PM
Herald added a subscriber: MaskRay. · View Herald Transcript
khchen accepted this revision.Mar 29 2021, 5:23 PM

Agree! LGTM.

This revision is now accepted and ready to land.Mar 29 2021, 5:23 PM
frasercrmck accepted this revision.Mar 30 2021, 1:27 AM

LGTM. Renaming SplatOperand sounds like a good idea.