I have read a short doc on interrupts and PMIC, but it didn't answer many of my questions. I am programming ATxMega 32e5 and I would like to know how exactly do interrupts behave. Let's say I have two interrupts enabled INT1 and INT2, both have the same priority (eg. medium priority - 0b10). Let's say INT1 fires and I enter ISR for INT1. While in INT1's ISR, INT2 fires and is queued to be executed. However at the end of INT1 I disable INT2 by setting the priority of INT2 to 0. What happens when I leave INT1? Is INT2 executed anyway (is there some kind of caching inside the MCU?) or not? If there is some kind of caching, how can I really disable INT2, or is that not possible?