Nov 16th, 2000, 02:22 PM
Science Fact of the Day
Thursday November 16, 2000
Compilers
In computer science, a compiler is a special type of program that translates high-level computer languages into the low-level instructions that the CPU (central processing unit) understands. In the early days of computers, they were programmed using assembly language, in which each line of a program corresponded to a trivial operation, such as retrieving a number stored in memory, adding two numbers together, or comparing them.
Then, along came the higher level languages such as C, C++, Pascal, Fortran, Cobol and others, which were developed because writing assembly code was tedious -- involving the programmer in many nitty-gritty details that could be figured out automatically. In a high level language, a single statement might correspond to a concept such as "repeat this operation until the count is higher than 10," which might translate into many lines of assembly. Early compilers generated code that was not as efficient as that which could be written by hand, but modern optimizing compilers are often able to figure out "tricks" that are beyond the reach of all but the most skilled hand-coders.
- Michael Natkin
Thursday November 16, 2000
Compilers
In computer science, a compiler is a special type of program that translates high-level computer languages into the low-level instructions that the CPU (central processing unit) understands. In the early days of computers, they were programmed using assembly language, in which each line of a program corresponded to a trivial operation, such as retrieving a number stored in memory, adding two numbers together, or comparing them.
Then, along came the higher level languages such as C, C++, Pascal, Fortran, Cobol and others, which were developed because writing assembly code was tedious -- involving the programmer in many nitty-gritty details that could be figured out automatically. In a high level language, a single statement might correspond to a concept such as "repeat this operation until the count is higher than 10," which might translate into many lines of assembly. Early compilers generated code that was not as efficient as that which could be written by hand, but modern optimizing compilers are often able to figure out "tricks" that are beyond the reach of all but the most skilled hand-coders.
- Michael Natkin