Compiler Design and Construction - Old Questions

10.  Differentiate between C compiler and Pascal compiler.

6 marks | Asked in 2071-II

Pascal Compiler

C/C++ Compiler

It is one pass compiler where all the phases are combined into one pass.

It is multi-pass compiler where different phases of compiler are grouped into multiple phases.

Here intermediate representation of source program is not created.

Here intermediate representation of source program is created.

It is faster than C/C++ compiler.

It is slightly slower than Pascal compiler.

It does not look back at code it

previously processed

Each pass takes the result of the previous pass as the input and create intermediate output.

Unable to generate efficient programs due to limited scope available.

Due to wider scope availability, these

compiler allows better code generation

It simplifies the job of writing a compiler but limited.

It is complex job writing a multi-pass compiler, code is improved pass by pass until final code.

Memory consumption is lower.

Memory consumption is higher.