diff options
author | Thomas Lively <tlively@google.com> | 2019-06-26 16:17:15 +0000 |
---|---|---|
committer | Thomas Lively <tlively@google.com> | 2019-06-26 16:17:15 +0000 |
commit | a1d97a960e622ee21550d92809512cb0870be499 (patch) | |
tree | 678b01b3a42a707b3be32cf74c635072c14f74da /llvm/docs/CodeGenerator.rst | |
parent | c95046501dc2cb535a82c38a5c004a6eddd33e00 (diff) | |
download | bcm5719-llvm-a1d97a960e622ee21550d92809512cb0870be499.tar.gz bcm5719-llvm-a1d97a960e622ee21550d92809512cb0870be499.zip |
[WebAssembly] Implement tail calls and unify tablegen call classes
Summary:
Implements direct and indirect tail calls enabled by the 'tail-call'
feature in both DAG ISel and FastISel. Updates existing call tests and
adds new tests including a binary encoding test.
Reviewers: aheejin
Subscribers: dschuff, sbc100, jgravelle-google, hiraditya, sunfish, llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D62877
llvm-svn: 364445
Diffstat (limited to 'llvm/docs/CodeGenerator.rst')
-rw-r--r-- | llvm/docs/CodeGenerator.rst | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/llvm/docs/CodeGenerator.rst b/llvm/docs/CodeGenerator.rst index 090273524f2..60048df010d 100644 --- a/llvm/docs/CodeGenerator.rst +++ b/llvm/docs/CodeGenerator.rst @@ -2075,7 +2075,8 @@ Tail call optimization ---------------------- Tail call optimization, callee reusing the stack of the caller, is currently -supported on x86/x86-64 and PowerPC. It is performed if: +supported on x86/x86-64, PowerPC, and WebAssembly. It is performed on x86/x86-64 +and PowerPC if: * Caller and callee have the calling convention ``fastcc``, ``cc 10`` (GHC calling convention) or ``cc 11`` (HiPE calling convention). @@ -2103,6 +2104,10 @@ PowerPC constraints: * On ppc32/64 GOT/PIC only module-local calls (visibility = hidden or protected) are supported. +On WebAssembly, tail calls are lowered to ``return_call`` and +``return_call_indirect`` instructions whenever the 'tail-call' target attribute +is enabled. + Example: Call as ``llc -tailcallopt test.ll``. |