Loading...
Searching...
No Matches
context_switch_frame Struct Reference

Stores the registers and PC for a context switch. More...

Detailed Description

Stores the registers and PC for a context switch.

This also defines context_switch_frame offsets for assembly language. The structure is sized to maintain 16 byte stack alignment per the ABI. https://github.com/riscv/riscv-elf-psabi-doc

Definition at line 40 of file context_frame.h.

#include <context_frame.h>

Data Fields

uint32_t s0
 s0 register
 
uint32_t s1
 s1 register
 
uint32_t s2
 s2 register
 
uint32_t s3
 s3 register
 
uint32_t s4
 s4 register
 
uint32_t s5
 s5 register
 
uint32_t s6
 s6 register
 
uint32_t s7
 s7 register
 
uint32_t s8
 s8 register
 
uint32_t s9
 s9 register
 
uint32_t s10
 s10 register
 
uint32_t s11
 s11 register
 
uint32_t ra
 ra register
 
uint32_t t0
 t0 register
 
uint32_t t1
 t1 register
 
uint32_t t2
 t2 register
 
uint32_t t3
 t3 register
 
uint32_t t4
 t4 register
 
uint32_t t5
 t5 register
 
uint32_t t6
 t6 register
 
uint32_t a0
 a0 register
 
uint32_t a1
 a1 register
 
uint32_t a2
 a2 register
 
uint32_t a3
 a3 register
 
uint32_t a4
 a4 register
 
uint32_t a5
 a5 register
 
uint32_t a6
 a6 register
 
uint32_t a7
 a7 register
 
uint32_t pc
 program counter
 
uint32_t pad [3]
 padding to maintain 16 byte alignment
 

Field Documentation

◆ a0

uint32_t context_switch_frame::a0

a0 register

Definition at line 63 of file context_frame.h.

◆ a1

uint32_t context_switch_frame::a1

a1 register

Definition at line 64 of file context_frame.h.

◆ a2

uint32_t context_switch_frame::a2

a2 register

Definition at line 65 of file context_frame.h.

◆ a3

uint32_t context_switch_frame::a3

a3 register

Definition at line 66 of file context_frame.h.

◆ a4

uint32_t context_switch_frame::a4

a4 register

Definition at line 67 of file context_frame.h.

◆ a5

uint32_t context_switch_frame::a5

a5 register

Definition at line 68 of file context_frame.h.

◆ a6

uint32_t context_switch_frame::a6

a6 register

Definition at line 69 of file context_frame.h.

◆ a7

uint32_t context_switch_frame::a7

a7 register

Definition at line 70 of file context_frame.h.

◆ pad

uint32_t context_switch_frame::pad[3]

padding to maintain 16 byte alignment

Definition at line 73 of file context_frame.h.

◆ pc

uint32_t context_switch_frame::pc

program counter

Definition at line 72 of file context_frame.h.

◆ ra

uint32_t context_switch_frame::ra

ra register

Definition at line 55 of file context_frame.h.

◆ s0

uint32_t context_switch_frame::s0

s0 register

Definition at line 42 of file context_frame.h.

◆ s1

uint32_t context_switch_frame::s1

s1 register

Definition at line 43 of file context_frame.h.

◆ s10

uint32_t context_switch_frame::s10

s10 register

Definition at line 52 of file context_frame.h.

◆ s11

uint32_t context_switch_frame::s11

s11 register

Definition at line 53 of file context_frame.h.

◆ s2

uint32_t context_switch_frame::s2

s2 register

Definition at line 44 of file context_frame.h.

◆ s3

uint32_t context_switch_frame::s3

s3 register

Definition at line 45 of file context_frame.h.

◆ s4

uint32_t context_switch_frame::s4

s4 register

Definition at line 46 of file context_frame.h.

◆ s5

uint32_t context_switch_frame::s5

s5 register

Definition at line 47 of file context_frame.h.

◆ s6

uint32_t context_switch_frame::s6

s6 register

Definition at line 48 of file context_frame.h.

◆ s7

uint32_t context_switch_frame::s7

s7 register

Definition at line 49 of file context_frame.h.

◆ s8

uint32_t context_switch_frame::s8

s8 register

Definition at line 50 of file context_frame.h.

◆ s9

uint32_t context_switch_frame::s9

s9 register

Definition at line 51 of file context_frame.h.

◆ t0

uint32_t context_switch_frame::t0

t0 register

Definition at line 56 of file context_frame.h.

◆ t1

uint32_t context_switch_frame::t1

t1 register

Definition at line 57 of file context_frame.h.

◆ t2

uint32_t context_switch_frame::t2

t2 register

Definition at line 58 of file context_frame.h.

◆ t3

uint32_t context_switch_frame::t3

t3 register

Definition at line 59 of file context_frame.h.

◆ t4

uint32_t context_switch_frame::t4

t4 register

Definition at line 60 of file context_frame.h.

◆ t5

uint32_t context_switch_frame::t5

t5 register

Definition at line 61 of file context_frame.h.

◆ t6

uint32_t context_switch_frame::t6

t6 register

Definition at line 62 of file context_frame.h.


The documentation for this struct was generated from the following file: