Someone will have to find the bug in gcc-3.2.1->gcc-3.2.3 causingticker to crash for pc386
eric.valette at free.fr
Thu Apr 3 16:18:39 UTC 2003
Joel Sherrill wrote:
> Valette Eric wrote:
>>Valette Eric wrote:
>>>Putting printk and using bochs, I can say the init thread is running
>>>doing the task create, the task start but the newly created ticker
>>>threads are not even started... The crash seems to occur in the middle
>>>of the context switch. Just to be sure that it is not due to an irq, I
>>>added a asm volatile ("sti") in the init thread and it continue its
>>>execution up to the task delete itself...
>>OK. I've done my debugging part. I know what is wrong even if I still do
>>not know why. When the ticker thread are created, 3 minimal context are
>>created with _Thread_Handler as the entry point. When doing task delete,
>>the first context is used (correct address, correct esp, ebp) when
>>calling _Context_Switch but unfortunately, EIP is already corrupted.
>>Note that I added a lot of printk wihtout making the problem disappear
>>so it means, is surely not a wrong pointer thing...
>>Now, the game is to find what part of the code corrupts it...
> Thanks for the Bochs screen dump Eric. I wonder if someone is blowing
> a stack. I noticed something that might help but don't know where it
> would have happened. Notice the PC is 0x3216. That is very similar to
> the flags register. Here are the initial values:
> #define CPU_EFLAGS_INTERRUPTS_ON 0x00003202
> #define CPU_EFLAGS_INTERRUPTS_OFF 0x00003002
I found the bug :-) The libc task init extension was causing the problem
because of code I would not even comment...
/ ` Eric Valette
/-- __ o _. 6 rue Paul Le Flem
(___, / (_(_(__ 35740 Pace
Tel: +33 (0)2 99 85 26 76 Fax: +33 (0)2 99 85 26 76
E-mail: eric.valette at free.fr
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
More information about the users