[PATCH] D134323: AtomicExpand: Avoid some operations if the atomic is overaligned
Stanislav Mekhanoshin via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 20 16:04:46 PDT 2022
rampitec added inline comments.
================
Comment at: llvm/lib/CodeGen/AtomicExpandPass.cpp:726
- PMV.ShiftAmt = Builder.CreateTrunc(PMV.ShiftAmt, PMV.WordType, "ShiftAmt");
PMV.Mask = Builder.CreateShl(
ConstantInt::get(PMV.WordType, (1 << (ValueSize * 8)) - 1), PMV.ShiftAmt,
----------------
Should this also go under if? Looks like for an overaligned case it is a no-op. I can actually see shl by 0 in the produced IR.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D134323/new/
https://reviews.llvm.org/D134323
More information about the llvm-commits
mailing list