From 8349864dbdf49ec7637d8c2903dadafb5747990f Mon Sep 17 00:00:00 2001 From: Reid Kleckner Date: Tue, 26 Aug 2014 00:33:28 +0000 Subject: Declare that musttail calls in variadic functions forward the ellipsis Summary: There is no functionality change here except in the way we assemble and dump musttail calls in variadic functions. There's really no need to separate out the bits for musttail and "is forwarding varargs" on call instructions. A musttail call by definition has to forward the ellipsis or it would fail verification. Reviewers: chandlerc, nlewycky Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D4892 llvm-svn: 216423 --- llvm/docs/LangRef.rst | 3 +++ 1 file changed, 3 insertions(+) (limited to 'llvm/docs') diff --git a/llvm/docs/LangRef.rst b/llvm/docs/LangRef.rst index a310240804d..8e574dfd7af 100644 --- a/llvm/docs/LangRef.rst +++ b/llvm/docs/LangRef.rst @@ -6591,6 +6591,9 @@ This instruction requires several arguments: - The calling conventions of the caller and callee must match. - All ABI-impacting function attributes, such as sret, byval, inreg, returned, and inalloca, must match. + - The callee must be varargs iff the caller is varargs. Bitcasting a + non-varargs function to the appropriate varargs type is legal so + long as the non-varargs prefixes obey the other rules. Tail call optimization for calls marked ``tail`` is guaranteed to occur if the following conditions are met: -- cgit v1.2.3