2.3.30. CONTEXT

Displays the current context.





Displays all contexts (roots).


The CONTEXT command displays the current context. If you are using the GUI, then the context is displayed in the Output view. The context includes the current root, module, procedure, and line. The context must be in a module with high-level debug information for the line number to be displayed.

If the context is at the PC, then the text At the PC: is displayed.

If you have changed scope to a location other than that pointed to by the PC, then the text Scoped to: is displayed.

CONTEXT runs asynchronously unless it is run in a macro.


The following example shows how to use CONTEXT using the dhrystone application:

> context
At the PC: (0x00008000): ENTRY\__main
Source view: DHRY_1\main Line 78

This demonstrates the case where the PC and the current source view do not correspond. In this case, the editor is displaying the beginning of the function main() at line 78, while the pc is at location 0x8000 in the __main(), the routine that calls main().

The following example sets a breakpoint in main() and runs to that breakpoint:

> bi \DHRY_1\#98:0
> go
Stopped at 0x000084D0 due to SW Instruction Breakpoint
Stopped at 0x000084D0: DHRY_1\main Line 98
> con
At the PC: (0x000084D0): DHRY_1\main Line 98

Because the PC and the source view are synchronized, the form of the message changes.

Finally, the /F form, of CONTEXT displays the Root: specification shown in the following example:

At the PC: (0x000084D0): DHRY_1_1\DHRY_1_C\main Line 98
Root: @dhrystone\\ [SCOPE]

See also

Copyright © 2002-2011 ARM. All rights reserved.ARM DUI 0175N