SP ESE QuestionPaper Sem1 2019
SP ESE QuestionPaper Sem1 2019
: ( )
PNOV19 Total No. of Pages in Paper (02)
B.Tech Computer Engineering
(Semester –I)
BTECHCS516 /BTECHCS603 – Systems Programming
Time: 2.15hr. Max. Marks: 50
Instructions to the Candidates:
i All questions are compulsory.
ii Figures to right indicate full marks.
iii Assume suitable data if necessary.
Q No Question Marks
START
MOV A , = ' 6 '
LOOP : READ N
MOV B , N
SUB A,B
JZ LOOP
ORG 500
LTORG
ADD B , = ' 30 '
LTORG
INC B
N DC 10
STR DS ( 20 )
NUM EQU N
END
Assume each imperative instruction is of length 2.
Perform LC processing 2
Q2 A Compare Variant I and Variant II forms of Intermediate Code of assembler with example. 8
OR
What are expansion time variables? Explain with a relevant example their usage.
Q3 A Justify the reason to create the additional tables SEGTAB and EXTTAB during second pass of 8
8080 linker.
OR
Consider the following "C" code. Generate the tokens with lexemes and token values.
if ( a == 10)
c = a–b;
else
b= a%c;
START 500
ENTRY TOTAL 10
READ STR
JMP LOOP
STR DS 10
TOTAL DS 20
END
READ 09 1
MOVER 04 1
ADD 05 1
JMP 06 2
Write the contents of all the components of object module for the above program Unit.
Q No Question Marks
Q2 A Describe the structure, scope and purpose of following tables in Macro Processing with example: 8
OR
Differentiate between lexical expansion and semantic expansion of macro with a suitable
example.
Q3 A With a neat diagram describe the data structures for expanding nested macro calls. 8
OR
Elaborate the processing of EXTRN and ENTRY definitions by Linker with an example.
Q4 A Write LEX specification to count the number of words, constants and special characters in the 8
input text.
i) Block Vs Character
ii) Dedicated Vs Shared
iii) Sequential Vs Random access
Q6. A Consider the following code. Assume mnemonic op codes and length.
START 500
ENTRY TOTAL
EXTERN ALPHA, BETA, GAMMA
READ N
NEXT : MOV C, N
..
..
MOV A, ALPHA
MOV B, BETA
SUB A, B
JC NEXT
MOV C, GAMMA
N DC 10
TOTAL DS 20
END
Generate RELOCTAB 2
Generate LINKTAB 3
Generate Object code as produced by assembler with LC. (Assume opcodes and size for each 5
mnemonic)
Total No. of Question: 6 Seat No.: ( )
PNOV19 Total No. of Pages in Paper (02)
B.Tech Computer Engineering
(Semester – I)
BTECHCS516 / BTECHCS603 – Systems Programming
Time: 2.15hr. Max. Marks: 50
Instructions to the Candidates:
i All questions are compulsory.
ii Figures to right indicate full marks.
iii Assume suitable data if necessary.
Q No Question Marks
Q1 A Consider the following Assembly language code.
START
MOV A , = ' 6 '
NEXT : READ N
MOV B , N
SUB A,B
JZ NEXT
ORG 500
LTORG
ADD B , = ' 30 '
LTORG
INC B
N DC 10
STR DS ( 20 )
RESULT EQU N
END
Q2 A Discuss the issues in single pass assembly. Propose an algorithm for the same with tables 8
required.
With an example explain the purpose and usage of FIXUPP records in 8088 Linker.
OR
START 500 10
ENTRY TOTAL
READ STR
JMP LOOP
STR DS 10
TOTAL DS 20
END
READ 09 1
MOVER 04 1
ADD 05 1
JMP 06 2
Write the contents of all the components of object module for the above program Unit.