![Texas Instruments TMS320C6 Series Скачать руководство пользователя страница 263](http://html.mh-extra.com/html/texas-instruments/tms320c6-series/tms320c6-series_user-manual_1094537263.webp)
Using Expression Analysis in the Debugger
12-5
Basic Information About C Expressions
This expression format is useful for examining the automatic variables of a
function that is not currently being executed. Unless the variable is static,
however, the function must be somewhere in the current call stack. Note
that if you want to see local variables from the currently executing function,
you need not use this form; you can simply specify the variable name (just
as in your C source).
File-scoped variables (such as statics or functions) can be referenced with
the following expression form:
filename.function name
or
filename.variable name
This expression format is useful for accessing a file-scoped static variable
(or function) that may share its name with variables in other files.
Note that in this expression,
filename does not include the file extension;
the debugger searches the object symbol table for any source filename
that matches the input name, disregarding any extension. Thus, if the vari-
able
ABC is in file source.c, you can specify it as source.ABC.
Note that these expression forms can be combined into an expression of
the form:
filename.function name.variable name
-
Any integral or void expression can be treated as a pointer and used with
the indirection operator (
*
). Here are several examples of valid use of a
pointer in an expression:
*123
*AR5
*(AR2 + 123)
*(I*J)
By default, the values are treated as integers (that is, these expressions
point to integer values).
-
Any expression can be typecast to a pointer to a specific type (overriding
the default of pointing to an integer, as described above).
Hint: You can use casting with the WA and DISP commands to display
data in a desired format.
For example, the expression:
*(float *)10
treats 10 as a pointer to a floating-point value at location 10 in memory. In
this case, the debugger fetches the contents of memory location 10 and
treats the contents as a floating-point value. If you use this expression as a
parameter for the DISP command, the debugger displays memory con-
tents as an array of floating-point values within the DISP window, begin-
ning with memory location 10 as array member [0].
Содержание TMS320C6 Series
Страница 10: ...x ...
Страница 20: ...xx ...
Страница 118: ...4 20 ...
Страница 144: ...6 16 ...
Страница 164: ...7 20 ...
Страница 170: ...8 6 ...
Страница 284: ...B 18 ...
Страница 290: ...C 6 ...