#include "pm.h"
Defines | |
| #define | __FILE_ID__ 0x09 |
Functions | |
| PmReturn_t | interpret (const uint8_t returnOnNoThreads) |
| PmReturn_t | interp_reschedule (void) |
| PmReturn_t | interp_addThread (pPmFunc_t pfunc) |
| void | interp_setRescheduleFlag (uint8_t boolean) |
Variables | |
| PmReturn_t(* | std_nat_fxn_table [])(pPmFrame_t *) |
| PmReturn_t(* | usr_nat_fxn_table [])(pPmFrame_t *) |
VM interpreter operations.
| PmReturn_t interp_addThread | ( | pPmFunc_t | pfunc | ) |
Creates a thread object and adds it to the queue of threads to be executed while interpret() is running.
The given obj may be a function, module, or class. Creates a frame for the given function.
| pfunc | Ptr to function to be executed as a thread. |
| PmReturn_t interp_reschedule | ( | void | ) |
Selects a thread to run and changes the VM internal variables to let the switch-loop execute the chosen one in the next iteration. For the moment the algorithm is primitive and will change the thread each time it is called in a round-robin fashion.
| void interp_setRescheduleFlag | ( | uint8_t | boolean | ) |
Sets the reschedule flag.
| boolean | Reschedule on next occasion if boolean is true; clear the flag otherwise. |
| PmReturn_t interpret | ( | const uint8_t | returnOnNoThreads | ) |
Interprets the available threads. Does not return.
| returnOnNoThreads | Loop forever if 0, exit with status if no more threads left. |
1.5.9