nikic wrote: @pcc I think using fsh should at least help to get a ror instead of the shr+shl+or.
Actually getting the value duplicated+sunk into each block is typically done in CGP, which has a bunch of related transforms. The most generic is probably tryToSinkFreeOperands driven by TTI.isProfitableToSinkOperands. https://github.com/llvm/llvm-project/pull/141326 _______________________________________________ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits