Conventionally, a Real-time Operating System (RTOS) is built without knowing which specific applications will be executed upon it. The RTOS is built for the general case, rather than to meet the specific requirements of an application. This paper proposes a generic module-based reflective framework to implement an RTOS that allows applications to dynamically adapt the policies within the RTOS to better meet application-specific requirements.
The specific approach taken is to augment a conventional micro-kernel with a module-based reflective mechanism that allows applications to dynamically change the behaviour of themselves, and the policies of the underlying RTOS. Reflection is used to allow applications and system modules to access key OS data structures to obtain information pertaining to the current system performance and resource management policies (eg. scheduling). An application is then able to modify or introduce new policies into the RTOS to satisfy its demands. Evaluation of our approach shows a considerable performance gain.