[all-commits] [llvm/llvm-project] 7e78d8: [PowerPC] Fix for compiler side issue in PCRelativ...

stefanp-ibm via All-commits all-commits at lists.llvm.org
Tue Sep 22 06:28:41 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 7e78d89052b15f32ea56f018698194c7c9627152
      https://github.com/llvm/llvm-project/commit/7e78d89052b15f32ea56f018698194c7c9627152
  Author: Stefan Pintilie <stefanp at ca.ibm.com>
  Date:   2020-09-22 (Tue, 22 Sep 2020)

  Changed paths:
    M llvm/lib/Target/PowerPC/PPCISelDAGToDAG.cpp
    M llvm/test/CodeGen/PowerPC/pcrel-tls-local-exec.ll

  Log Message:
  -----------
  [PowerPC] Fix for compiler side issue in PCRelative Local Exec

Stop combining loads and stores with PPCISD::ADD_TLS before we can merge the
node with with TLS_LOCAL_EXEC_MAT_ADDR. The issue is that
TLS_LOCAL_EXEC_MAT_ADDR cannot be selected by itself and requires the previous
ADD_TLS node that goes with it. However, we sometimes try to combine ADD_TLS
with loads and stores that come after it. If this happens then the ADD_TLS is
removed and TLS_LOCAL_EXEC_MAT_ADDR cannot be selected.

While this bug fix will address the issue it my not be ideal from a performance
perspective as we may be able to add patterns to combine TLS_LOCAL_EXEC_MAT_ADDR
with ADD_TLS with the load and store that comes after it all in one. However,
this is beyond the scope of this patch.

Reviewed By: NeHuang

Differential Revision: https://reviews.llvm.org/D88030




More information about the All-commits mailing list