66
32000D–04/2011
AVR32
8.3
Entry points for events
Several different event handler entry points exists. For AVR32A, the reset routine is placed at
address 0x8000_0000. This places the reset address in the flash memory area. For AVR32B,
the reset routine entry address is always fixed to 0xA000_0000. This address resides in
unmapped, uncached space in order to ensure well-defined resets.
TLB miss exceptions and scall have a dedicated space relative to EVBA where their event han-
dler can be placed. This speeds up execution by removing the need for a jump instruction placed
at the program address jumped to by the event hardware. All other exceptions have a dedicated
event routine entry point located relative to EVBA. The handler routine address identifies the
exception source directly.
All external interrupt requests have entry points located at an offset relative to EVBA. This
autovector offset is specified by an external Interrupt Controller. The programmer must make
sure that none of the autovector offsets interfere with the placement of other code. The reach of
the autovector offset is IMPLEMENTATION DEFINED.
Special considerations should be made when loading EVBA with a pointer. Due to security con-
siderations, the event handlers should be located in the privileged address space, or in a
privileged memory protection region. In a system with MPU, the event routines could be placed
in a cacheable protection region. In a segmented AVR32B system, some segments of the virtual
memory space may be better suited than others for holding event handlers. This is due to differ-
ences in translateability and cacheability between segments. A cacheable, non-translated
segment may offer the best performance for event handlers, as this will eliminate any TLB
misses and speed up instruction fetch. The user may also consider to lock the event handlers in
the instruction cache.
If several events occur on the same instruction, they are handled in a prioritized way. The priority
ordering is presented in
Table 8-1. If events occur on several instructions at different locations in
the pipeline, the events on the oldest instruction are always handled before any events on any
younger instruction, even if the younger instruction has events of higher priority than the oldest
instruction. An instruction B is younger than an instruction A if it was sent down the pipeline later
than A.