JavaScript is not currently enabled, but is required for full CodeSonar manual search and browse functionality.
If you are viewing this file in your hub's Web GUI, enable JavaScript in your browser: you will also need it for GUI functionality.
If you opened this file directly from disk, your browser may be directly suppressing JavaScript functionality: certain browsers perform this suppression on local files (but not files delivered by web servers) for security reasons.
| CodeSonar® 9.2p0 | CONFIDENTIAL | CodeSecure Inc |
Symbols (ABS_LOCs) are abstract locations that statically represent the locations of variables and functions in a running program. Each symbol represents a collection of possible locations; for example, the symbol for a local variable of a recursive function represents all recursive instantiations of that variable. Symbols may be collected into symbol sets (ABS_LOC_SET).
Language Module Support: Internal representation for symbols is available for C/C++ and binary analyses only. For C# and Java analyses, plug-ins that rely on symbol properties and relationships will generally not produce useful information.
Symbols are categorized by symbol kind:
| Kind | Description |
|---|---|
| function | Functions. |
| heap | Variables that are generated for each occurrence of a memory allocator , either in a call or in an assignment to a function pointer. |
| intermediate | Expression temporaries, which are usually generated by normalization. |
| label | For the GNU extension Labels as Values. |
| param | Actual-in parameters, which have names of the form $param_i. Each function call has zero or more arguments. CodeSonar treats argument expressions at function calls as implicit stores into actual-in parameters that are, in turn, copied into the corresponding formal-in parameters. |
| result | Actual-out parameters. The return value of a function call is treated as an actual-out parameter into which the corresponding formal-out parameter of the function has been copied. An expression containing the call fetches the return value from that actual-out parameter |
| return | Formal-out parameters, including the return value of a non-void function. |
| string | The array of characters contained in a string constant. |
| subobj | For fields within struct variables, fields within class variables, base class components of inherited class variables. |
| user | User defined variables, which include formal-in parameters. |
| internal | Internal use: rarely observable and can typically be ignored. |
If a symbol represents a variable, it also has a variable kind.
| Global | A variable that is neither local to a file nor local to a function. |
|---|---|
| File static | A variable that is local to a file, but not local to a function. |
| Function static | A static variable that is local to a function. |
| Local | An automatic variable, i.e., a non-static variable that is local to a function, or a formal parameter. |
| Formal parameter |
Each function has zero or more parameters. These variables are
known as formal-in parameters to distinguish them from
arguments at call sites.
CodeSonar treats the return value of a non-void function as an anonymous formal-out parameter. |
| Actual parameter |
Each function call has zero or more arguments.
CodeSonar treats argument expressions at function calls
as implicit stores into actual-in parameters with names of the
form $param_i that are,
in turn, copied into the corresponding formal-in parameters.
Similarly, the return value of a function call is treated as an actual-out parameter into which the corresponding formal-out parameter of the function has been copied. An expression containing the call fetches the return value from that actual-out parameter. |
| Pointer variable | A variable that may contain the address of another variable, or the address of a function. |
| Function pointer | A variable that may contain the address of a function. |
| String variable | A separate string variable is generated for each string constant in the program. |
| Temporary variable | A generated variable introduced by the normalization of an assignment statement and other expression. |
| Heap variable | CodeSonar generates one or more explicit heap variables for each direct call to a memory allocator. The heap variable statically represents all blocks of storage that may be returned by the given call for a particular calling context. A calling context represents a sequence of calls, e.g., "main calls f (from call-site #1) which calls g (from call-site #2) which calls malloc". The name of the heap variable includes the name of the memory allocator being invoked and the calling context (printed backwards) in which it is invoked. |
| Structure or Union Field |
A named part of another variable.
Union fields are treated somewhat differently from structure fields: A union field u.a is almost always considered an alias for the variables u, u.b, u.c, etc. A finer distinction is often made for structure fields. |
| Port Variable | [CodeSonar for Binaries only] Represent the data sources and sinks associated with the in and out instructions that occur in an x86 program. |
By API implementation:
| Language | Symbol Functionality/Types Provided By | Types | |
|---|---|---|---|
| Symbol | Symbol Kind | ||
| C++ | class symbol | class symbol | class symbol_kind |
| Python | class symbol | class symbol | class class symbol_kind |
| C | Header cs_abs_loc.h | typedef cs_abs_loc | typedef cs_abs_loc_kind |
See also:
To report problems with this documentation, please visit https://support.codesecure.com/.