An intermediate representation (IR) is a data structure that is constructed from input data to a program, and from which part or all of the output data of the program is constructed in turn. Use of the term usually implies that most of the information present in the input is retained by the intermediate representation, with further annotations or rapid lookup features.
A canonical example is found in most modern compilers, where the linear human-readable text representing a program is transformed into an intermediate graph data structure that allows flow analysis and re-arrangements before starting to create the list of actual CPU instructions that will do the work. Use of an intermediate representation allows compiler systems like LLVM to be targeted by many different source languages, and support generation for many different target architectures.
Read more about this topic: Intermediate Language
Famous quotes containing the word intermediate:
“Complete courage and absolute cowardice are extremes that very few men fall into. The vast middle space contains all the intermediate kinds and degrees of courage; and these differ as much from one another as mens faces or their humors do.”
—François, Duc De La Rochefoucauld (16131680)