#include <femtoos_types.h>
Data Fields | |
Tuint08 | r31 |
Tuint08 | r30 |
Tuint08 | uiRegisterUse |
Taddress | pcStackOffset |
Taddress | pcStackLevel |
These are the variables which are kept while a task is running. In fact, it is a way to communicate information from portRestoreContext to portSaveContext. Also it is used to save some registers temporarily during port(Save/Restore)Context. We have two versions depending on the direction of stack growth. Note that, since some of these variables must be retained until the OS has restarted, some buffer variables are needed. These keep a save distance between the variables needed and the building OS stack. Also, if we have no checking switched on, we can use a shorter version of the TtaskSave. The number of buffer variables is 4 at a minimum (2 addresses, namely a call to privInitOs() and a possible subsequent call to tcbCurrent(). It is assumed that those functions do not push more variables on the stack. This must be checked. In case we have no checking, only one address is pushed so we need only 2 buffer variables (one address). Please note the the order of the variables is of the utmost importance, do not change it unless you know what you are doing (and believe me, you don't yet). Just to get you going, mark these facts:
Note: make sure that any change in this structure is reflected in the defTaskSaveSize constant!
Definition at line 162 of file femtoos_types.h.
Tuint08 TtaskSave::r31 |
Definition at line 163 of file femtoos_types.h.
Referenced by portBeginISR(), portReturnISR(), portSaveContext(), and portYieldISR().
Tuint08 TtaskSave::r30 |
Tuint08 TtaskSave::uiRegisterUse |
Definition at line 165 of file femtoos_types.h.
Referenced by portRestoreContext(), portSaveContext(), and privInitOs().
Taddress TtaskSave::pcStackOffset |
Taddress TtaskSave::pcStackLevel |