Home » Computer Organization and Architecture » Computer organization and architecture miscellaneous » Question

Computer organization and architecture miscellaneous

Computer Organization and Architecture

  1. Consider the C struct, defined below :
    struct data {
    int marks [100];
    char grade;
    int cnumber; };
    struct, data student;
    The base address of student is available in register Rl. The field student grade can be accessed efficiently using
    1. Post-increment addressing mode, (Rl)+
    2. Pre-decrement addressing mode, – (Rl)
    3. Register direct addressing mode, Rl
    4. Index addressing mode. X(R1), where X is an offset represented in 2’s complement 16- bit representation.
Correct Option: D

Since direct access is possible with only index addressing mode. So, option (d) is correct.



Your comments will be displayed only after manual approval.