0% found this document useful (0 votes)
101 views4 pages

SP Unit Test 1

This document appears to be an exam for a Systems Programming class at Pune Institute of Computer Technology. It contains instructions for the exam, which will last 1 hour and contains multiple choice and descriptive questions. The exam is divided into sets A, B, C and D. Questions cover topics like assembly language, macro processing, and compiler design phases. Students are asked to complete tasks like generating symbol tables for assembly code, explaining compiler phases and macro directives, and converting regular expressions to DFAs. The exam is out of a total of 30 marks.

Uploaded by

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

SP Unit Test 1

This document appears to be an exam for a Systems Programming class at Pune Institute of Computer Technology. It contains instructions for the exam, which will last 1 hour and contains multiple choice and descriptive questions. The exam is divided into sets A, B, C and D. Questions cover topics like assembly language, macro processing, and compiler design phases. Students are asked to complete tasks like generating symbol tables for assembly code, explaining compiler phases and macro directives, and converting regular expressions to DFAs. The exam is out of a total of 30 marks.

Uploaded by

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

Pune Institute of Computer Technology, Pune-43

DEPARTMENT OF INFORMATION TECHNOLOGY


(Academic Year – 2019-20 Sem-II)
UNIT TEST - I
Subject: Systems Programming Subject Code: 314451
Class: TE ( IT ) Div: XI [ Max. Marks : 30]
Date: 07/02/2020 Day: Friday Duration: 1 Hour

Instructions to the candidate: SET-D


1. All questions are compulsory. Roll No: -
2. Assume suitable data, if necessary.

Ques. CO Bloom’s Max


Question
No. Mapped LL Marks
For the following piece of assembly language code, show the
contents of symbol table, literal table, pool table and IC
(Variant I and Variant II). Assume machine opcodes and size
of instruction as 1.
START 100
A DC 10
MOVER AREG, B
MOVEM BREG, = '1'
ADD AREG, = '2'
1-a CO-1 L3, L5 07
SUB BREG, = '1'
B EQU A + 20
LTORG
STORE AREG, NUM
MOVER CREG, LOOP
ADD BREG, = '1'
NUM DS 5
LOOP DC 10
END
1-b Write a short note on Language Processing Activities. CO-1 L1 03
Explain basic functions of loader. Also explain the working of
2-a CO-2 L1, L2 04
compile and go loader.
With format explain the following macro directives: MACRO,
2-b CO-2 L1, L2 06
MEND, AIF, AGO, LBL and GBL.
3-a Write a neat diagram explain the phases of compiler. CO-3 L2 05
Using RE to DFA algorithm generate the DFA for the given
3-b CO-3 L4, L5 05
Regular Expression. (a+b)*a*b.

-----------******-----------

Page 1 of 4
Pune Institute of Computer Technology, Pune-43
DEPARTMENT OF INFORMATION TECHNOLOGY
(Academic Year – 2019-20 Sem-II)
UNIT TEST - I
Subject: Systems Programming Subject Code: 314451
Class: TE ( IT ) Div: XI [ Max. Marks : 30]
Date: 07/02/2020 Day: Friday Duration: 1 Hour

Instructions to the candidate: SET-C


1. All questions are compulsory. Roll No: -
2. Assume suitable data, if necessary.

Ques. CO Bloom’s Max


Question
No. Mapped LL Marks
With syntax and example explain types of assembly language
1-a CO-1 L1 04
statements.
1-b What are the assembler Directives? Explain with Example. CO-1 L1, L2 04
1-c Explain Intermediate code generation. CO-1 L2 02
For the given assembly code generate MNT, MDT and expanded code

MACRO START 100


M1 &N, &A1 = ,&R=AREG READ VAR
MOVEM &R, &N M2 A, OPR =SUB
SUB &R, &A1 ADD AREG,VAR
ADD &R, &N LDA CREG,BREG
MEND SUB CREG,A
2-a MACRO
CO-2 L3, L5 07
M1 C, R = BREG, A1 =A
M2 &P, &Q = B, &OPR = A DS 1
DIV VAR DC 2
MOVER AREG,&P C DS 3
&OPR AREG,&Q
MOVEM BREG,&P
MEND

2-b What is subroutine linkage? How is it resolved? CO-2 L1, L2 03


Perform lexical analysis on the given 'C' program
main() {
float volume = 0.0, length, breadth, height;
clrscr();
3-a printf("Enter length, breadth and height of cube :\n"); CO-3 L5 05
scanf("%f %f %f ", &length, &breadth, &height);
volume = length *breadth* height;
printf("Volume = %f', volume);
getch(); }
3-b Explain Input Buffering. CO-3 L1 03
3-c Explain role of Lexical Analyzer. CO-3 L1 02

-----------******-----------

Page 2 of 4
Pune Institute of Computer Technology, Pune-43
DEPARTMENT OF INFORMATION TECHNOLOGY
(Academic Year – 2019-20 Sem-II)
UNIT TEST - I
Subject: Systems Programming Subject Code: 314451
Class: TE ( IT ) Div: XI [ Max. Marks : 30]
Date: 07/02/2020 Day: Friday Duration: 1 Hour

Instructions to the candidate: SET-B


1. All questions are compulsory. Roll No: -
2. Assume suitable data, if necessary.

Ques. CO Bloom’s Max


Question
No. Mapped LL Marks
Generate (Pass I) symbol table, literal table, pool table and
Intermediate code (Variant I and II) with Machine Code (Output of
Pass II) for the given assembler program. Assume a hypothetical
instruction set with every instruction of length 1 byte.
START 500
LAB DS 15
MOVEM AREG, VAR
ADD AREG, LAB
MOVER BREG, ='10'
SUB BREG, ='5'
1-a MULT BREG, ='10' CO-1 L3, L5 08
PRINT VAR
LTORG
ORIGIN LAB+3
LOOP MOVER CREG, ='5'
LOAD AREG, ='2'
VAR EQU LOOP
ORIGIN VAR + 25
ADD CREG, L1
STOP
L1 DC '12'
END
1-b Explain Listing and error reporting in assembler with example. CO-1 L1, L2 02
Explain following Macro facilities with example.
2-a i) Expansion time Variable CO-2 L1, L2 05
ii) Change of flow during Macro expansion
Explain different parameter passing mechanisms in macro processor
2-b CO-2 L1 05
with example.
Explain the processing of given statement w. r. t first three phases of
3-a CO-3 L5 05
compiler. R=(b*b-4*a*c)/(2*a).
Convert the following RE to DFA
3-b CO-3 L4, L5 05
(1+ )*01

-----------******-----------

Page 3 of 4
Pune Institute of Computer Technology, Pune-43
DEPARTMENT OF INFORMATION TECHNOLOGY
(Academic Year – 2019-20 Sem-II)
UNIT TEST - I
Subject: Systems Programming Subject Code: 314451
Class: TE ( IT ) Div: XI [ Max. Marks : 30]
Date: 07/02/2020 Day: Friday Duration: 1 Hour

Instructions to the candidate: SET-A


1. All questions are compulsory. Roll No: -
2. Assume suitable data, if necessary.

Ques. CO Bloom’s Max


Question
No. Mapped LL Marks
Explain how a single pass assembler works for the following example:
START 300
READ A
LOOP MOVER AREG, A
1-a SUB AREG, =’1’ CO-1 L3 06
BC GT, LOOP
STOP
A DS 1
END
Write an algorithm for Pass-II of two-pass assembler and explain with
1-b CO-1 L2 04
suitable example.
For the following assembly language program show MNT, MDT, stack
organization and the expanded code for the given assembly language
program.
MACRO START
XYZ &A MIT HELLO
MOVER AREG,&A ADD AREG, BREG
MEND
HELLO YALE
2-a MACRO CO-2 L3, L5 10
MIT &Z
YALE EQUS
MACRO ALL DC 3
&Z &W END
ADD BREG, &W
XYZ ALL
MEND
MOVER &Z, ALL
MEND
For the given 'C' code, generate the output of lexical analysis.
//My first C Program
void main ( ) {
int i, j; clrscr( );
3-a scanf("%d %d",&i,&j); CO-3 L4, L5 06
while (i <= j)
{ i++; j--; }
printf("C Programming!");
getch( ); }
3-b Define the term Lexeme, Token and Pattern with Example. CO-3 L1, L2 04
-----------******-----------
Page 4 of 4

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy