发明名称 METHOD AND SYSTEM FOR PROVIDING STACK MEMORY MANAGEMENT IN REAL-TIME OPERATING SYSTEMS
摘要 A method and system for providing memory management in a Real-Time Operating System (RTOS) based system are provided. The method includes creating a plurality of tasks with a two level stack scheme comprising a first level stack and a second level stack, scheduling a first task for execution by moving a stack pointer from the first level stack to the second level stack, determining whether the first task is pre-empted, allocating the second level stack to the first task in a second state if the first task is not pre-empted, changing an active task for execution, determining whether the first task relinquishes control from the second state and is waiting for a resource, moving the stack pointer back from the second level stack to the first level stack if the first task relinquishes itself and providing the second level stack for use by a second task.
申请公布号 US2017090981(A1) 申请公布日期 2017.03.30
申请号 US201615374603 申请日期 2016.12.09
申请人 SAMSUNG ELECTRONICS CO., LTD. 发明人 VRIND TUSHAR;SOMU KANDASWAMY BALAJI;UDAVA RAJU SIDDAPPA;INDUKURI VENKATA RAJU
分类号 G06F9/48;G06F9/50;G06F9/46 主分类号 G06F9/48
代理机构 代理人
主权项 1. A method of providing memory management in a real-time operating system (RTOS) based system, the method comprising: creating, by a task generator, a plurality of tasks with a two level stack scheme including a first level stack and a second level stack; scheduling, by a task scheduler, a first task in a first state for execution by transferring task contents associated with the first task from the first level stack to the second level stack; determining whether the first task is pre-empted; allocating the second level stack to the first task in a second state, if the first task is not pre-empted; changing, by the task scheduler, an active task for execution; determining whether the first task relinquishes control from the second state and is awaiting a resource; scanning the second level stack, if the first task relinquishes control from the second state and is awaiting the resource; determining whether a register is present in a range of stack addresses of the second level stack; determining whether usage of the second level stack is less than a size of the first level stack, if there are no registers present in the range of the stack addresses of the second level stack; and transferring the task contents from the second level stack to the first level stack, if the usage of the second level stack is less than the size of the first level stack.
地址 GYEONGGI-DO KR