« Close

Datasheets and User Guides

Software & Driver

 

5.10 - gdb breaks with "signal SIG40, Real-time event 40."

LJM uses gRPC, which internally uses SIG40 to wake up threads. By default, gdb breaks when the process receives a signal. This causes gdb to output something like the following:

Thread 7 "eNames" received signal SIG40, Real-time event 40.
[Switching to Thread 0x7fffef7fe700 (LWP 90205)]
0x00007ffff7364627 in __GI_epoll_pwait (epfd=17, events=0x7fffef7fd600, maxevents=100, timeout=10000, set=0x7fffef7fe650)
    at ../sysdeps/unix/sysv/linux/epoll_pwait.c:42
42    ../sysdeps/unix/sysv/linux/epoll_pwait.c: No such file or directory.
(gdb)

This looks problematic, but it's actually fine. More info on gdb and signals can be found in section 5.4 Signals of the gdb documentation.

Solution: Suppress gdb's default break behavior for SIG40

To circumvent this, you can use the gdb command:

handle SIG40 noprint nostop

(Related gRPC issue: SIG36 while debugging with gdb #7906.)

Solution: Disable LJM_RPC_ENABLE

To disable LJM's use of gRPC, see How do I disable gRPC?