Ch 05: Subroutines and Stack Architecture

222 Questions222 MCQs0 Short Questions0 Long Questions
๐ŸŽฏ Exam Practice Papers
SEMESTER PASS

CS401 - Computer Architecture and Assembly Language Programming Examination Practice

Timed practice exam simulation for CS401 - Computer Architecture and Assembly Language Programming.

๐Ÿ“˜ VU MID TERM EXAMLectures 1 to 22
โฑ๏ธ 60 Mins

Mid Term Examination

Covers syllabus of Lectures 1 to 22 with 30 high-yield MCQs in a timed exam environment.

๐Ÿ“30 MCQs
โฑ๏ธ60 Minutes
๐Ÿ“— VU FINAL TERM EXAMLectures 23 to 45
โฑ๏ธ 90 Mins

Final Term Examination

Comprehensive semester exam preparation with 45 MCQs covering Lectures 23 to 45 with complete course coverage.

๐Ÿ“45 MCQs
โฑ๏ธ90 Minutes
Showing 161 โ€“ 170 of 222 Questions
Page 17 of 23
Q161
โ“ MCQ๐Ÿ“˜ CS401๐Ÿ“‘ Lec 5๐Ÿท๏ธ Subroutine Calling Conventions (C vs Pascal)Medium๐Ÿ”โญ๐Ÿ’ก๐Ÿ“„๐ŸŽ“VU๐Ÿ›๏ธVU
How many traditional parameter passing calling conventions (C calling convention and Pascal calling convention) are primarily recognized in assembly programming?
  1. A.1
  2. B.2
  3. C.3
  4. D.4
Q162
โ“ MCQ๐Ÿ“˜ CS401๐Ÿ“‘ Lec 5๐Ÿท๏ธ Far Subroutine Return (RETF Instruction)Easy๐Ÿ”โญ๐Ÿ’ก๐Ÿ“„๐ŸŽ“VU๐Ÿ›๏ธVU
When executing a 'RETF' (Return Far) instruction, into which register is the 16-bit target offset popped first from the stack?
๐Ÿ’ป assembly Snippet
retf
  1. A.BP
  2. B.IP
  3. C.SP
  4. D.SI
Q163
โ“ MCQ๐Ÿ“˜ CS401๐Ÿ“‘ Lec 5๐Ÿท๏ธ RET Instruction with Immediate Parameter and Stack CleanupHard๐Ÿ”โญ๐Ÿ’ก๐Ÿ“„๐ŸŽ“VU๐Ÿ›๏ธVU
After the execution of the near instruction 'RET 2', by how many bytes is the Stack Pointer (SP) incremented in total?
๐Ÿ’ป assembly Snippet
ret 2
  1. A.SP is incremented by 2
  2. B.SP is incremented by 4
  3. C.SP is decremented by 2
  4. D.SP is decremented by 4
Q164
โ“ MCQ๐Ÿ“˜ CS401๐Ÿ“‘ Lec 5๐Ÿท๏ธ PUSH Instruction and Stack Pointer DecrementEasy๐Ÿ”โญ๐Ÿ’ก๐Ÿ“„๐ŸŽ“VU๐Ÿ›๏ธVU
In 8088 architecture, whenever an element is pushed onto the system stack using a PUSH instruction, how is the Stack Pointer (SP) modified?
๐Ÿ’ป assembly Snippet
push ax
  1. A.SP is decremented by 1
  2. B.SP is decremented by 2
  3. C.SP is decremented by 3
  4. D.SP is decremented by 4
Q165
โ“ MCQ๐Ÿ“˜ CS401๐Ÿ“‘ Lec 5๐Ÿท๏ธ 8088 Stack Element Data SizeEasy๐Ÿ”โญ๐Ÿ’ก๐Ÿ“„๐ŸŽ“VU๐Ÿ›๏ธVU
In 8088 real mode architecture, the system stack operates strictly on elements of what data size?
๐Ÿ’ป assembly Snippet
push ax
pop bx
  1. A.Word-sized elements
  2. B.Byte-sized elements
  3. C.Doubleword-sized elements
  4. D.Nibble-sized elements
Q166
โ“ MCQ๐Ÿ“˜ CS401๐Ÿ“‘ Lec 5๐Ÿท๏ธ Traditional Calling ConventionsMedium๐Ÿ”โญ๐Ÿ’ก๐Ÿ“„๐ŸŽ“VU๐Ÿ›๏ธVU
How many prevalent traditional parameter passing calling conventions (C calling convention and Pascal calling convention) exist in assembly programming?
  1. A.1
  2. B.2
  3. C.3
  4. D.4
Q167
โ“ MCQ๐Ÿ“˜ CS401๐Ÿ“‘ Lec 5๐Ÿท๏ธ RET Instruction Subroutine FlowEasy๐Ÿ”โญ๐Ÿ’ก๐Ÿ“„๐ŸŽ“VU๐Ÿ›๏ธVU
When a subroutine finishes execution, which instruction retrieves the saved return address from the stack and transfers control back to the caller?
๐Ÿ’ป assembly Snippet
ret
  1. A.RET instruction
  2. B.CALL instruction
  3. C.POP instruction
  4. D.Jump instruction
Q168
โ“ MCQ๐Ÿ“˜ CS401๐Ÿ“‘ Lec 5๐Ÿท๏ธ Stack Pointer (SP) and Stack InstructionsEasy๐Ÿ”โญ๐Ÿ’ก๐Ÿ“„๐ŸŽ“VU๐Ÿ›๏ธVU
The Stack Pointer (SP) is a memory pointer register that is manipulated implicitly by a specific set of stack-related __________.
๐Ÿ’ป assembly Snippet
push ax
pop bx
  1. A.Instructions (e.g., PUSH, POP, CALL, RET)
  2. B.Pointers
  3. C.Indexes
  4. D.Variables
Q169
โ“ MCQ๐Ÿ“˜ CS401๐Ÿ“‘ Lec 5๐Ÿท๏ธ Base Pointer (BP) and Stack Frame AccessEasy๐Ÿ”โญ๐Ÿ’ก๐Ÿ“„๐ŸŽ“VU๐Ÿ›๏ธVU
Besides the Stack Pointer (SP), which base register functions as a frame memory pointer to access parameters and local variables inside the stack segment?
๐Ÿ’ป assembly Snippet
mov bp, sp
mov ax, [bp + 4]
  1. A.SP
  2. B.BP
  3. C.PB
  4. D.AC
Q170
๐Ÿ“ Short Q๐Ÿ“˜ CS401๐Ÿ“‘ Lec 5๐Ÿท๏ธ RET Instruction Parameter and Stack CleanupEasy๐Ÿ”โญ๐Ÿ’ก๐Ÿ“„๐ŸŽ“VU๐Ÿ›๏ธVU
How many optional immediate parameter arguments can the RET (Return from Subroutine) instruction accept for stack cleanup?
๐Ÿ’ป assembly Snippet
ret 4