I have a thread, which does a function call,
Thread 1()
{
while(1)
{
msg = msgreceive();
condn= msg->condn;
switch(condn)
{
case 0:
//do sonmething
break;
case 1:
printf("case_1");
function2()
break;
}
}
}
function 2()
{
printf("fn2_Start");
//Do something
function 3();
printf("fn2_end");
}
fucntion3()
{
printf("fn3_Start");
//Do something
printf("fn3_end");
}
Normally i get the printf traces this way,
case_1
fn2_Start
fn3_Start
fn3_end
fn2_end
case_1
fn2_Start
fn3_Start
fn3_end
fn2_end
....
....
...
But some times in long run, i get the traces this way
case_1
fn2_tart
fn2_start
fn2 start
case 1
case 1
This is with embedded RTOS device environment.(MQX) Language - C Is there anyway we can suspect why the sytem can behave this way.This happens when the system is heavily loaded running with about ~93% of memory usage.