This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Program Counter, Stack Pointer and Link Register Status During an Interrupt Service in ARM based Processors

what happens when interrupt comes to program counter stck pointer and link register in ARM based Processor Architeture ?

Parents
  • Which processor?

    For Armv7-A and earlier, assuming the exception is taken:

    • The PC will be set to the appropriate exception vector
    • SPSR_<mode> will be set to the CPSR value immediately before the exception
    • CPSR will be update with the correct mode and instruction set.
    • LR_<mode> will be set to the exception return address
    • SP will now select SP_<mode>
    Where <mode> is the exception mode.  So for an interrupt, it would be SPSR_irq, LR_irp and SP_irq.
Reply
  • Which processor?

    For Armv7-A and earlier, assuming the exception is taken:

    • The PC will be set to the appropriate exception vector
    • SPSR_<mode> will be set to the CPSR value immediately before the exception
    • CPSR will be update with the correct mode and instruction set.
    • LR_<mode> will be set to the exception return address
    • SP will now select SP_<mode>
    Where <mode> is the exception mode.  So for an interrupt, it would be SPSR_irq, LR_irp and SP_irq.
Children