EasyManua.ls Logo

COBHAM GRMON3 - GRMON Thread Options; GRMON Thread Commands

COBHAM GRMON3
239 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
GRMON3-UM
June 2019, Version 3.1.0
32 www.cobham.com/gaisler
using load or manually by using the symbols command. GRMON will traverse the thread structures located in
the target's memory when the thread command is issued or when GDB requests thread information. Bare-metal
threads are used by default if no OS threads can be found. In addition the startup switch -bmthreads can be
used to force bare-metal threads.
The target's thread structures are never changed, and they are only accessed when the thread command is executed.
Starting GRMON with the -nothreads switch disables the thread support in GRMON and the GDB server.
During debugging sessions it can help the developer a lot to view all threads, their stack traces and their states to
understand what is happening in the system.
3.8.1. GRMON thread options
The following command-line options are available for selecting how GRMON3 will handle threads.
-nothreads
Disable thread support.
-bmthreads
Force bare-metal thread support
-rtems version
Set RTEMS version for thread support, where the required argument version is one of the following:
rtems-5.0
rtems-4.12
rtems-4.11
rtems-4.10
rtems-4.8
rtems-4.6
3.8.2. GRMON thread commands
thread info lists all threads currently available in the operating system. The currently running thread is marked
with an asterisk.
grmon> thread info
Name | Type | Id | Prio | Ticks | Entry point | PC | State
-------------------------------------------------------------------------------------------------
Int. | internal | 0x09010001 | 255 | 138 | _CPU_Thread_Idle_body | 0x4002f760 | READY
-------------------------------------------------------------------------------------------------
UI1 | classic | 0x0a010001 | 120 | 290 | Init | 0x4002f760 | READY
-------------------------------------------------------------------------------------------------
ntwk | classic | 0x0a010002 | 100 | 11 | rtems_bsdnet_schedneti | 0x4002f760 | READY
-------------------------------------------------------------------------------------------------
DCrx | classic | 0x0a010003 | 100 | 2 | rtems_bsdnet_schedneti | 0x4002f760 | Wevnt
-------------------------------------------------------------------------------------------------
DCtx | classic | 0x0a010004 | 100 | 4 | rtems_bsdnet_schedneti | 0x4002f760 | Wevnt
-------------------------------------------------------------------------------------------------
FTPa | classic | 0x0a010005 | 10 | 1 | split_command | 0x4002f760 | Wevnt
-------------------------------------------------------------------------------------------------
FTPD | classic | 0x0a010006 | 10 | 1 | split_command | 0x4002f760 | Wevnt
-------------------------------------------------------------------------------------------------
* HTPD | classic | 0x0a010007 | 40 | 79 | rtems_initialize_webse | 0x40001b60 | READY
-------------------------------------------------------------------------------------------------
thread bt ?id? lists the stack backtrace. bt lists the backtrace of the currently executing thread as usual.
grmon> thread bt 0x0a010003
%pc
#0 0x4002f760 _Thread_Dispatch + 0x11c
#1 0x40013ed8 rtems_event_receive + 0x88
#2 0x40027824 rtems_bsdnet_event_receive + 0x18
#3 0x4000b664 websFooter + 0x484
#4 0x40027708 rtems_bsdnet_schednetisr + 0x158
A backtrace of the current thread (equivalent to the bt command):
grmon> thread bt 0x0a010007
%pc %sp
#0 0x40001b60 0x43fea130 console_outbyte_polled + 0x34

Table of Contents