Saturday, May 22, 2010

What does a compiler do while doing compilation of a c progranm?

Essentially a C-compiler converts a C-program into something which machine can understand.





visit wikipedia for more details http://en.wikipedia.org/wiki/Compiler

What does a compiler do while doing compilation of a c progranm?
A compiler is a program which converts the code written high level language to low level language (Machine Language). A C compiler first converts the c language source code to a file with .obj extention. Still not done. Then the linker links this code with the library files and makes the file output that is an EXE file.
Reply:Compiles your source code.





Haha... it creates machine code from your C source code. Machine code is written in a specific instruction set understood by your computer. It's much more complex than straight text source code.
Reply:A compiler is just a program that converts your written code into machine code or another form of code.

sundew

No comments:

Post a Comment