Texas Instruments TMS320 User Manual page 95

Dsp/bios v5.40
Hide thumbs Also See for TMS320:
Table of Contents

Advertisement

interrupt occurs. This can be useful for determining the system stack size
needed by an application. To determine the maximum depth of the stack,
follow these steps (see Figure 3-7):
1) In your .tcf file, set the monitor field for the HWI object to Stack Pointer.
You should also change the operation field to STS_add(–*addr).
These changes give you the minimum value of the stack pointer in the
maximum field of the STS object. This is the top of the stack, since the
stack grows downward in memory.
2) Link your program and use the nmti program, which is described in
Chapter 2, Utility Programs in the TMS320 DSP/BIOS API Reference
Guide for your platform, to find the address of the end of the system
stack. Or, you can find the address in Code Composer by using a
Memory window or the map file to find the address referenced by the
GBL_stackend symbol. (This symbol references the top of the stack.)
3) Run your program and view the STS object that monitors the stack
pointer for this HWI function in the Statistics Data tool.
4) Subtract the minimum value of the stack pointer (maximum field in the
STS object) from the end of the system stack to find the maximum depth
of the stack.
ROV displays stack information for all targets. (See Section 3.3, Runtime
Object Viewer (ROV))
Implicit DSP/BIOS Instrumentation
Instrumentation
3-33

Advertisement

Table of Contents
loading

Table of Contents