[PATCH] D76500: GlobalISel: Lower funnel shifts
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Mar 20 09:11:04 PDT 2020
arsenm marked an inline comment as done.
arsenm added inline comments.
================
Comment at: llvm/lib/CodeGen/GlobalISel/LegalizerHelper.cpp:4167-4168
+LegalizerHelper::lowerFunnelShift(MachineInstr &MI) {
+ // G_FSHL: (X << (Z % BW)) | (Y >> (BW - (Z % BW)))
+ // G_FSHR: (X << (BW - (Z % BW))) | (Y >> (Z % BW))
+ Register Dst = MI.getOperand(0).getReg();
----------------
foad wrote:
> This won't work when Z is 0 if shifting by BW is undefined.
That's handled below but not included in the high level comment
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D76500/new/
https://reviews.llvm.org/D76500
More information about the llvm-commits
mailing list