Skip to content
Commit fbd9dd45 authored by Martin Åberg's avatar Martin Åberg Committed by Henrik Brix Andersen
Browse files

SPARC: Add support for single-vector trapping (SVT)



This adds support for the single-vector trapping (SVT) model, defined by
SPARC-V8 Embedded (V8E) Architecture Specification. SVT is available in
most LEON processors.

With single-vector trapping enabled, all traps are vectored through a
single trap vector (TBR.A) rather than one 16-byte entry for each trap
type. This improves memory utilization because the full 4 KiB trap table
is not needed.

This implementation uses a two-level of lookup table to find the handler
for the trap type (0..255).
- Execution time is constant.
- Condition flags are preserved.
- The implementation footprint is 60 bytes .text and 284 bytes .rodata.
  For comparison, a non-SVT table is always 4096 .text.

Signed-off-by: default avatarMartin Åberg <martin.aberg@gaisler.com>
parent dd5874b9
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment