当前位置:网站首页>Use gdb to debug multi-process programs, debug parent and child processes at the same time
Use gdb to debug multi-process programs, debug parent and child processes at the same time
2022-08-09 11:15:00 【XV_】
Reference:
[1] GDBdebugging multi-process programs
[2] Debugging programswith multiple processes
According to these two reference links, it is completely possible to use gdb to debug the parent process and the child process at the same time.
Next, I will explain the pits that may be encountered
- There is a bug in gdb8.1 version. After setting
set detach-fork-on off
, after executingfork
, switch to subprocess, and encountercannotAdd breakpoints
and other issues - gdb9.2 version also has bugs. When the process is switched, problems such as
fork.c file missing
will be encountered, but it does not affect, use then
command multiple timesJust skip it.
Therefore, at present, the author uses Ubuntu 20.10, gdb 10.2 to have no bugs, and can normally debug multiple processes at the same time.
边栏推荐
- linux mysql操作的相关命令
- For versions corresponding to tensorflow and numpy, report FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecate
- fork creates multiple child processes
- verbose np.matmul/np.dot/np.multiply/tf.matmul/tf.multiply/*
- 学长告诉我,大厂MySQL都是通过SSH连接的
- MDK添加注释模板
- 信号量SIGCHLD的使用,如何让父进程得知子进程执行结束,如何让父进程区分多个子进程的结束
- Antdv+Asp.net WebApi开发学生信息管理系统(一)
- 日期工具类
- Qt读写.ini配置文件
猜你喜欢
随机推荐
Official explanation, detailed explanation and example of torch.cat() function
ThreadLocal及其内存泄露分析
MATLAB中如何把cftool拟合的函数输出到命令行(解决如何导出拟合后的曲线数据)
PTA 指定位置输出字符串(c)
matlab fcnchk 函数用法
STM32使用静态队列保存数据
CAN总线发送数据
使用.NET简单实现一个Redis的高性能克隆版(四、五)
vite的原理,手写vite
全网最简单解决OneNote中英字体不统一
图片查看器viewer
自从我使用HiFlow场景连接器后,在也不用担心成为“落汤鸡”了
x86异常处理与中断机制(2)中断向量表
Create a table in a MySQL database through Doc
CentOS6.5 32bit安装Oracle-11gR2步骤说明
For versions corresponding to tensorflow and numpy, report FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecate
activemq 消息持久化
PTA习题 阶梯电价(C)
faster-rcnn learn
PTA习题 分类统计字符个数(C)