Inline function expansion for compiling C programs
- 21 June 1989
- proceedings article
- Published by Association for Computing Machinery (ACM)
- Vol. 24 (7) , 246-257
- https://doi.org/10.1145/73141.74840
Abstract
Inline function expansion replaces a function call with the function body. With automatic inline function expansion, programs can be constructed with many small functions to handle complexity and then rely on the compilation to eliminate most of the function calls. Therefore, inline expansion serves a tool for satisfying two conflicting goals: minizing the complexity of the program development and minimizing the function call overhead of program execution. A simple inline expansion procedure is presented which uses profile information to address three critical issues: code expansion, stack expansion, and unavailable function bodies. Experiments show that a large percentage of function calls/returns (about 59%) can be eliminated with a modest code expansion cost (about 17%) for twelve UNIX* programs.Keywords
This publication has 15 references indexed in Scilit:
- Code optimization across proceduresComputer, 1989
- Achieving high instruction cache performance with an optimizing compilerPublished by Association for Computing Machinery (ACM) ,1989
- Comparing software and hardware schemes for reducing the cost of branchesPublished by Association for Computing Machinery (ACM) ,1989
- Minimizing register usage penalty at procedure callsPublished by Association for Computing Machinery (ACM) ,1988
- Register windows vs. register allocationPublished by Association for Computing Machinery (ACM) ,1988
- The hardware architecture of the CRISP microprocessorPublished by Association for Computing Machinery (ACM) ,1987
- A VLSI RISCComputer, 1982
- A practical interprocedural data flow analysis algorithmCommunications of the ACM, 1978
- A program data flow analysis procedureCommunications of the ACM, 1976
- A Simple Algorithm for Global Data Flow Analysis ProblemsSIAM Journal on Computing, 1975