SYNTAX ANALYSIS
ROLE OF THE PARSER
Question
[CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
|
|
On the number of strings/life reacts
|
|
Code segment to be defined after data segment
|
|
On unconditional rump
|
|
None of these
|
Detailed explanation-1: -In a single pass assembler, most of the forward references can be avoided by putting the restrictiona)On the number of strings/life reactsb)Code segment to be defined after data segmentc)On unconditional rumpd)None of the mentionedCorrect answer is option ‘B’.
Detailed explanation-2: -The solution for forward references problem is having an assembler of two pass. It creates a number of passes that is necessary to process the definition of symbols.
Detailed explanation-3: -As explained, one-pass assembler cannot resolve forward references of data symbols. It requires all data symbols to be defined prior to being used.
Detailed explanation-4: -Disadvantages of one pass assembler: The Forward reference problem exists in the one-pass assembler. In this problem operands are utilized before the declaration, thus assembler has no information about the operand address that is to be present in the final executable code.