Architectural and compiler support for efficient function calls