Global

group Global_CILstack

CILstack globals.

lorem

Macros

group Macros_CILstack_h

Variables

group Variables_CILstack_h

API’s

group Apis_CILstack_h

Getters

group Getters_CILstack_h

Setters

group Setters_CILstack_h

Functions

__NAKED void CILstack_setStackPointer (AddressType address)

Set stack pointer DEMO CODE.

The implementation contains load multiple registers instruction to restore the standard context registers. After this point the process stack pointer is set to the value stored in the R0 register as it has argument 1 role in the procedure call standard thus it holds the address argument value. Then the thread mode bit is set inside the control register and instruction barrier is implemented afterwards. After this point the branch and exchange instruction is called based on the value of the R14 register.

Parameters

AddressType[in] address

Returns

none

General

group General_CILstack_h

Functions

StackPointerType CILstack_stackInit(AddressType stackLowAddress, AddressType stackHighAddress, AddressType handlerAddress)

Task stack initialization.

The implementation contains stack initialization by placing the context type at the stackHighAddress - context type size and initializing all standard context registers loaded from the stack. Then is the stack pointer address represented by the lowest address of the context type structure returned from the function.

Parameters
  • stackLowAddress[in]

  • stackHighAddress[in]

  • handlerAddress

Returns

StackPointerType