stackoverflow : LLVM tail call optimization
http://en.wikipedia.org/wiki/Tail_call
Tail call optimization, callee reusing the stack of the caller, is currently supported on x86/x86-64 and PowerPC.
It is performed if:
- Caller and callee have the calling convention fastcc, cc 10 (GHC calling convention) or cc 11 (HiPE calling convention).
- The call is a tail call - in tail position (ret immediately follows call and ret uses value of call or is void).
- Option -tailcallopt is enabled.
- Platform-specific constraints are met.
- x86/x86-64 constraints:
- No variable argument lists are used.
- On x86-64 when generating GOT/PIC code only module-local calls (visibility = hidden or protected) are supported.
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.