source: rtems/c/src/lib/libmisc/cpuuse/README @ f7fa7d7
Last change on this file since f7fa7d7 was fc7bc51, checked in by Joel Sherrill <joel.sherrill@…>, on Apr 9, 1997 at 8:18:54 PM

new files.

  • Property mode set to 100644
File size: 1.5 KB
2#  README,v 1.3 1995/12/19 20:13:47 joel Exp
5This directory contains a stack bounds checker.  It provides two
6primary features:
8   + check for stack overflow at each context switch
9   + provides an educated guess at each task's stack usage
11The stack overflow check at context switch works by looking for
12a 16 byte pattern at the logical end of the stack to be corrupted.
13The "guesser" assumes that the entire stack was prefilled with a known
14pattern and assumes that the pattern is still in place if the memory
15has not been used as a stack.
17Both of these can be fooled by pushing large holes onto the stack
18and not writing to them... or (much more unlikely) writing the
19magic patterns into memory.
21This code has not been extensively tested.  It is provided as a tool
22for RTEMS users to catch the most common mistake in multitasking
23systems ... too little stack space.  Suggestions and comments are appreciated.
271.  Stack usage information is questionable on CPUs which push
28    large holes on stack.
302.  The stack checker has a tendency to generate a fault when
31    trying to print the helpful diagnostic message.  If it comes
32    out, congratulations. If not, then the variable Stack_check_Blown_task
33    contains a pointer to the TCB of the offending task.  This
34    is usually enough to go on.
381.  Determine how/if gcc will generate stack probe calls and support that.
402.  Get accurate stack usage numbers on i960.. it pushes very large
41    holes on the stack.
Note: See TracBrowser for help on using the repository browser.