Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

RTOS Task Local Variables

Status
Not open for further replies.

vijay s

Full Member level 3
Joined
Jun 14, 2008
Messages
159
Helped
27
Reputation
54
Reaction score
9
Trophy points
1,298
Location
Coimbatore, India
Activity points
2,152
Hi Folks

Need little Clarification in Task Local Variables.. i know each Task has its own Stack, used to store context during task switch. what about its local variables, will that be allocated in System Task or in its own stack.

if allocated in local stack, can you folks explain in detail how its managed by Task....
 

The variables of a task and its reentrant routines when interrupted are pushed on the global stack, thereby creating private data for task and its reentrant routines. Nonreentrant code must by synchronized by some method such as a semaphore.

BigDog
 

Each task that is created will consume memory and this usually has to be defined when the task is created. The task’s stack is used to store all of its local variables, function parameters, return addresses and a copy of the processor registers when the tasks is ‘swapped out’. Each task has the individual stack, on that the local variables are stored.
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top