Why not use JALR to return from the interrupt handler?

What will be an ideal response?

We check for interrupts at the end of each instruction execution. Therefore, between enable interrupts and JALR $k0, we may get a new interrupt that will trash $k0 . JALR only saves to the return address register; if there are multiple interrupts then our $ra register will be overwritten and we'll lose our link.

Computer Science & Information Technology

You might also like to view...

Thumbnails are an alternative to ________ in the Navigation Pane

A) AutoText B) subdocuments C) headings D) pages

Computer Science & Information Technology

Given the following code: template < class ItemType> ArrayStack::ArrayStack() : top(-1) { } What method is this?

a. the default destructor b. the virtual destructor c. the default constructor d. the copy constructor

Computer Science & Information Technology