[all-commits] [llvm/llvm-project] 7d076e: [PowerPC] Fix computation of offset for load-and-s...

Nemanja Ivanovic via All-commits all-commits at lists.llvm.org
Fri Jul 24 12:39:13 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 7d076e19e31a2a32e357cbdcf0183f88fe1fb0fb
      https://github.com/llvm/llvm-project/commit/7d076e19e31a2a32e357cbdcf0183f88fe1fb0fb
  Author: Nemanja Ivanovic <nemanja.i.ibm at gmail.com>
  Date:   2020-07-24 (Fri, 24 Jul 2020)

  Changed paths:
    M llvm/lib/Target/PowerPC/PPCISelLowering.cpp
    M llvm/test/CodeGen/PowerPC/canonical-merge-shuffles.ll

  Log Message:
  -----------
  [PowerPC] Fix computation of offset for load-and-splat for permuted loads

Unfortunately this is another regression from my canonicalization patch
(1fed131660b2). The patch contained two implicit assumptions:
1. That we would have a permuted load only if we are loading a partial vector
2. That a partial vector load would necessarily be as wide as the splat

However, assumption 2 is not correct since it is possible to do a wider
load and only splat a half of it. This patch corrects this assumption by
simply checking if the load is permuted and adjusting the offset if it is.




More information about the All-commits mailing list