RTUEE / EC / EEEYr 2024 · Sem 52024

Q1Microprocessor

Question

2 marks

Q.1. List of benefits of subroutine.

Answer

Subroutines offer benefits of code reusability, reduced program size and memory usage, easier debugging/maintenance, and modular program structuring.

The benefits of using subroutines in assembly language programming include: code reusability (a commonly needed sequence of instructions is written once and called from multiple points in the main program, rather than being repeated); reduced program memory size (avoiding duplicated code for repeated operations); easier debugging and maintenance (isolated, well-defined blocks of functionality are easier to test and modify independently); and improved program modularity and readability (breaking a complex task into logically separate subroutines makes the overall program structure easier to understand and manage).

Back to Paper