0% found this document useful (0 votes)
28 views5 pages

SPCC PYQs

The document outlines the previous year questions (PYQs) for a System Programming and Compiler Construction course, organized by modules. Each module covers various topics such as system software, assemblers, macros, loaders, linkers, and compiler phases, with specific questions assigned varying weightages. The questions include definitions, comparisons, explanations, and practical applications related to the respective topics.

Uploaded by

amaancoatwala
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
28 views5 pages

SPCC PYQs

The document outlines the previous year questions (PYQs) for a System Programming and Compiler Construction course, organized by modules. Each module covers various topics such as system software, assemblers, macros, loaders, linkers, and compiler phases, with specific questions assigned varying weightages. The questions include definitions, comparisons, explanations, and practical applications related to the respective topics.

Uploaded by

amaancoatwala
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 5

SPCC PYQs (Module wise)

Module 1: Introduction to System Software (Avg. weightage = 5M)


Q1) Define System Programming. Differentiate between application software and system
software [5M] (x3)
Q2) Compare between Complier and Interpreter. [5M]

Module 2: Assemblers (Avg. weightage = 20M)


Q1) Explain with flowchart design of two pass assembler. [10M] (x2)
Q2) Explain in brief “forward reference problem”. (x3)
Explain how TII handles forward reference problem in single pass assembler. [5M]
Q3) Draw the flowchart of pass 1 of assembler and explain its working with the databases.
[10M]
Q4) State and explain the types of assembly language statements with examples. [10M] (x2)
Q5) Draw and explain the flowchart of pass 1 of two pass assembler with suitable example.
[10M]

Module 3: Macros and Macroprocessor (Avg. weightage = 20M)


Q1) Explain Macro and Macro expansion with example. [5M]
Q2) Explain different features of macros (or advanced macro facilities) with suitable
example. [10M] (x2)
Q3) Explain the working of a single pass macroprocessor with neat flowchart. [10M] (x2)
Q4) Explain conditional macro with suitable example. [5M]
Q5) Construct the necessary data structures after compiling the following code by pass 1 of
two pass macroprocessor. [10M]
Q6) Explain with help of a flowchart, the first pass of two-pass macroprocessor. [10M]
Q7) Write a short note on Macro Facilities. [5M]

Module 4: Loader and Linker (Avg. weightage = 15M)


Q1) What are the functions of a Loader? Enlist the loader schemes. [5M] (x2)
Q2) Explain Direct Linking Loader in detail with a suitable example. [10M] (x3)
Q3) Discuss the databases used in Direct Linking Loader. [10M]
Q4) Explain Dynamic Linking Loader in detail. [10M]
Q5) Explain Absolute Loader. State its advantages and disadvantages. [5M]

Module 5: Compilers – Analysis Phase (Avg. weightage = 25M)


Q1) Compare Bottom-up and Top-down parsers. [5M]
Q2) Design LL(1) parsing table for the given grammar.

Also state that whether the given grammar is LL(1) or not. [10M]
Q3) Explain the different phases of a compiler with suitable example. [10M] (x2)
Q4) Compute FIRST and FOLLOW for the following grammar. [5M]
Q5) Construct LR(0) parsing table for the following grammar and analyze the contents of
stack and input buffer and action taken after each step while parsing the input string
“abbcbcde”. [10M]

Q6) What are the phases of compiler? Give working of each phase for the following
statement: [10M]
P=Q+R–S*3

Q7) Construct operator precedence parser for the grammar:


Parse the string “a+a*a” using the same parser. [5M]
Q8) Design LL(1) parsing table for the given grammar:

Also state that whether the given grammar is LL(1) or not. [10M]
Q9) Construct SLR parser for the following grammar and parse the input “()()”: [10M]

Q10) Write short note on Syntax-directed translation. [5M]


Q11) Test whether following grammar is LL(1) or not. If it is LL(1), construct parsing table for
the same: [10M]

Q12) Explain the phases of a compiler. Discuss the action taken in various phases to compile
the statement:
a=b*c+10, where a, b, c are of type real. [10M]

Module 6: Compilers – Synthesis Phase (Avg. weightage = 35M)


Q1) Construct three address code for the following program: [10M]
Q2) What are the different ways of representing intermediate code? Explain with suitable
example. [10M] (x2)
Q3) Explain different issues in code generation phase of compiler. [10M] (x2)
Q4) Construct DAG for the following expression. [10M]
x=m+p/q-t+p/q*q
Q5) Generate 3-address code for the following C program and construct flow graph with the
help of basic blocks: [10M]

Q6) Explain different code optimization techniques in detail. [10M] (x2)


Q7) Construct three address code for the following program: [10M]

Q8) Explain DAG with suitable example. [10M]


Q9) What is three address code? Generate three address code for: [5M]

Q10) Explain the concept of basic blocks and flow graph with example of three address code.
[10M]
Q11) What is code optimization? Explain with example, the following code optimization
techniques: [10M]
(i) Common sub-expression elimination
(ii) Code Motion
(iii) Dead code elimination
(iv) Constant propagation

You might also like