Blown stack ?

Puro Markku markku.puro at insta.fi
Fri Oct 5 15:06:51 UTC 2001


Hi,

On ev386ex BSP(~i386ex) I ran into problems that looks like
stack overrun.  Anyhow I 'manage to fix' those by modifying 
stack minimum size (original value was 1024) in
.../rtems-ss-20010816/c/src/exec/score/cpu/i386/rtems/score/cpu.h
( thats not the best place to do it but... ;)
--8<--------------------------------------------------------------
/*
 *  Minimum size of a thread's stack.
 */
#define CPU_STACK_MINIMUM_SIZE           (4*1024)
--8<--------------------------------------------------------------

Where can I define new value for (CPU_)STACK_MINIMUM_SIZE ?
Has anyone findout similar problems in startup ?
(pc386 works with default values. maybe its not a stack problem at all ? )


  -Mp

examples-4.5.0:
termios with default stack=1024
--8<--------------------------------------------------------------
Initialized console on port COM2 9600-8-N-1

*** TEST OF TERMIOS INPUT CAPABILITIES ***

You----------------------------------------------------------
Exception 13 caught at PC 33E4 by thread 134283265
----------------------------------------------------------
Processor execution context at time of the fault was  :
----------------------------------------------------------
 EAX = 1F       EBX = 1F        ECX = FD930     EDX = 3212
 ESI = FB4B8    EDI = 361C      EBP = FCCC8     ESP = FCC8C
----------------------------------------------------------
Error code pushed by processor itself (if not 0) = C1C0
----------------------------------------------------------
 ************ FAULTY THREAD WILL BE DELETED **************
--8<--------------------------------------------------------------

after defining STACK_CHECKER_ON in 
.../rtems-ss-20010816/c/src/lib/libbsp/i386/ev386ex/include/bsp.h
and CPU_STACK_MINIMUM_SIZE (2*1024) termios runs OK 
but monitor generate BLOWN STACK.
--8<--------------------------------------------------------------
Initialized console on port COM2 9600-8-N-1

*** MONITOR TASK TEST ***

Monitor ready, press enter to login.

BLOWN STACK!!! Offending task(0xfdb0c): id=0x08010007; name=0x524d4f4e
  stack covers range 0x000f0d7c - 0x000f157b (2048 bytes)
--8<--------------------------------------------------------------

after defining CPU_STACK_MINIMUM_SIZE (4*1024) 'monitor' runs OK


------------------------------------------------------------------------
Markku Puro           markku.puro at insta.fi          Sarankulmankatu 20
                      tel.   +358 3  2659 769       FIN-33900 Tampere
INSTRUMENTOINTI OY    mobile +358 40 7092 769       http://www.insta.fi
C3i Systems           fax    +358 3  2659 501



More information about the users mailing list