Need help to explain the test result

Leon Pollak leonp at plris.com
Sun Jan 10 16:25:59 UTC 2010


On Sunday January 10 2010, Joel Sherrill wrote:
> On 01/10/2010 09:17 AM, Leon Pollak wrote:
> > Hello, all.
> >
> > I am trying to do the task switch logger.
> > For this I installed the user extension and the function "TASK SWITCH
> > Extension", which logs (into cyclic buffer) the
> > current_task->Object.name.
> >
> > Everything seems to work, but I have 2 questions:
> >
> > 1. Sometimes I see the name 0x10e150 to appear. Under debugger, I see
> > this name when an external interrupt occurs and task switch is called
> > from the ISR handler. Strange, as I thought that IRQ has no "task"
> > context. OK, but what is this name? I did:
> > (gdb) p/x current_task->Object
> > p/x current_task->Object
> > $59 = {Node = {next = 0x54f410, previous = 0x54f40c}, id = 0x9010001,
> > name = 0x10e150}
> 
> Some object types have string names.  This is the id of the idle
> thread.  I am betting *(char *) 0x10e150 is "IDLE".
Yes, you were right. But why in this way?
Object name always was an integer, not a pointer!?


> > 2. For now, I designated the above as "*IRQ" name and continued. Then, I
> > received something that I can not understand:
> > *IRQ    MRT2    V2HD    FCr1    FCr1    V2HD    FCr1    FCr1    V2HD   
> > FCr1 V2HD    FCr1
> >
> > How can it be that FCr1 is repeated? There was a context switch to
> > itself!?
> Signal? Or a reevaluation?  Hard to say.
Please, Joel, what do you mean?
What is "signal"?
Why reevaluation (whatever is it) may switch context to itself? If so, isn't 
it a wasting of the CPU?

-- 
Leon



More information about the users mailing list