Optimizing Compiler

In computing and computer science, an optimizing compiler is a compiler that tries to minimize or maximize some attributes of an executable computer program. The most common requirement is to minimize the time taken to execute a program; a less common one is to minimize the amount of memory occupied. The growth of portable computers has created a market for minimizing the power consumed by a program. Compiler optimization is generally implemented using a sequence of optimizing transformations, algorithms which take a program and transform it to produce a semantically equivalent output program that uses fewer resources.

It has been shown that some code optimization problems are NP-complete, or even undecidable. In practice, factors such as the programmer's willingness to wait for the compiler to complete its task place upper limits on the optimizations that a compiler implementor might provide. (Optimization is generally a very CPU- and memory-intensive process.) In the past, computer memory limitations were also a major factor in limiting which optimizations could be performed. Because of all these factors, optimization rarely produces "optimal" output in any sense, and in fact an "optimization" may impede performance in some cases; rather, they are heuristic methods for improving resource usage in typical programs.

Read more about Optimizing CompilerTypes of Optimizations, Factors Affecting Optimization, Common Themes, Problems With Optimization, List of Static Code Analyses

Other articles related to "optimizing compiler, compiler, compilers":

History Of Compiler Construction - Optimizing Compilers
... Compiler optimization is the process of improving the quality of object code without changing the results it produces ... The developers of the first FORTRAN compiler aimed to generate code that was better than the average hand-coded assembler, so that customers would ... In one of the first real compilers, they often succeeded ...
Algorithmic Efficiency - Optimization Techniques - Choice of Instruction or Data Type
... as that type will result in faster execution—since even a non-optimizing compiler will, in-effect, be 'forced' to choose appropriate instructions that will execute faster than would have been the ... Assembler programmers (and optimizing compiler writers) can then also benefit from the ability to perform certain common types of arithmetic for instance—divi ... if penalties result—something even the best optimizing compiler may not be designed to handle ...