[all-commits] [llvm/llvm-project] 1354a0: [PowerPC][Future] Implement PC Relative Tail Calls
stefanp-ibm via All-commits
all-commits at lists.llvm.org
Mon Apr 27 10:58:31 PDT 2020
Branch: refs/heads/master
Home: https://github.com/llvm/llvm-project
Commit: 1354a03e74c2f59e424dce12c0592c5ceecb0809
https://github.com/llvm/llvm-project/commit/1354a03e74c2f59e424dce12c0592c5ceecb0809
Author: Stefan Pintilie <stefanp at ca.ibm.com>
Date: 2020-04-27 (Mon, 27 Apr 2020)
Changed paths:
M llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
M llvm/lib/Target/PowerPC/PPCFrameLowering.cpp
M llvm/lib/Target/PowerPC/PPCISelLowering.cpp
M llvm/lib/Target/PowerPC/PPCMCInstLower.cpp
M llvm/test/CodeGen/PowerPC/pcrel-call-linkage-simple.ll
M llvm/test/CodeGen/PowerPC/pcrel-call-linkage-with-calls.ll
M llvm/test/CodeGen/PowerPC/pcrel-got-indirect.ll
M llvm/test/CodeGen/PowerPC/pcrel-indirect-call.ll
A llvm/test/CodeGen/PowerPC/pcrel-tail-calls.ll
Log Message:
-----------
[PowerPC][Future] Implement PC Relative Tail Calls
Tail Calls were initially disabled for PC Relative code because it was not safe
to make certain assumptions about the tail calls (namely that all compiled
functions no longer used the TOC pointer in R2). However, once all of the
TOC pointer references have been removed it is safe to tail call everything
that was tail called prior to the PC relative additions as well as a number of
new cases.
For example, it is now possible to tail call indirect functions as there is no
need to save and restore the TOC pointer for indirect functions if the caller
is marked as may clobber R2 (st_other=1). For the same reason it is now also
possible to tail call functions that are external.
Differential Revision: https://reviews.llvm.org/D77788
More information about the All-commits
mailing list