Linux.ChinaUnix.net
ChinaUnix | Linux首页 | 新闻 | 博客 | 文章 | 专栏 | 新手 | 方案 | 图书 | 下载 | 人才 | 手册 | wiki | 搜索     
Linux论坛
  会员: 密码: 免费注册 | 忘记密码 | 会员登录 | 搜索 | 帮助 


奥运快报: 
奥运热点:
 

弱问一个关于GDB的问题
首页 » CU论坛 » Linux » 汇总贴列表 » CPU与编译器 »  
[打印] [订阅] [收藏] [推荐给朋友] [本帖文本页]
prolj (非常女生)
法王
专业水帖


CU奥运火炬传递手2008
UID:293231
注册:2005-7-19
最后登录: 2008-09-06
帖子:12469
精华:3

可用积分:10264 (大富大贵)
信誉积分:560
专家积分:1241 (本版:40)
空间积分:0
推广积分:0

来自:乡下
状态:...保密...

[资料] [站内短信] [Blog]


顶部
11楼 发表于 2008-7-4 21:44 
这个要实现一个还真牛X了,拜一拜LZ这个神人。我这两年和debug无缘了。



您对本贴的看法:鲜花[0] 臭蛋[0]

__________________________________

别没事瞎搞意识强奸,大家都不是8岁小孩了,你又不是赵本山,想给别人洗脑啊?先回家对着镜子把自己洗成白痴去!
把自己塑造成神搞个人崇拜啊?你不就是会装13吗?对不起,俺是农民,就认实实在在看得见的,你那虚幻的太高深,俺不懂。
我是进来拜神的,顺便带点水,很多牛在天上飞,很多仙在空中飘,遮住了阳光,导致小菜无法进行光合作用,再没有水就没法活了。
空间积分可以换礼品了! | 有奖跟帖:服务器节能,奖50-100元图书 | 致电800-858-2903,了解DELL如何为你量身订制笔记本 | 送2G U盘
beepbug
精灵




UID:359594
注册:2006-1-6
最后登录: 2008-08-16
帖子:231
精华:0

可用积分:252 (白手起家)
信誉积分:100
专家积分:0 (本版:0)
空间积分:0
推广积分:0

状态:...离线...

[资料] [站内短信] [Blog]


顶部
12楼 发表于 2008-7-7 19:50 
你的进程总是只能占一个核。把几个进程分配给几个核,形成并行,是操作系统和多核CPU的事。你的调试器没法介入之中。



您对本贴的看法:鲜花[0] 臭蛋[0]

__________________________________

我的BLOG:http://blog.csdn.net/beepbug/
空间积分可以换礼品了! | 有奖跟帖:服务器节能,奖50-100元图书 | 致电800-858-2903,了解DELL如何为你量身订制笔记本 | 送2G U盘
prolj (非常女生)
法王
专业水帖


CU奥运火炬传递手2008
UID:293231
注册:2005-7-19
最后登录: 2008-09-06
帖子:12469
精华:3

可用积分:10264 (大富大贵)
信誉积分:560
专家积分:1241 (本版:40)
空间积分:0
推广积分:0

来自:乡下
状态:...保密...

[资料] [站内短信] [Blog]


顶部
13楼 发表于 2008-7-19 08:40 
Towards multiprocess GDB

Stan Shebs       
CodeSourcery has a project to add "multiprocess" capability to GDB, and with ...
       
4:40 (3小时前)
Stan Shebs正在载入...       
4:40 (3小时前)
Stan Shebs
发送至 gdb
       
显示详细信息 4:40 (3小时前)
       
       
回复
       
       
CodeSourcery has a project to add "multiprocess" capability to GDB,
and with this message I'd like to kick off some discussion of what
that means and how to make it happen.

To put it simply, the goal of the project is to make this command work
in some useful way:

gdb prog1 prog2 pid2 prog3 prog4

As the command suggests, we're talking about multiple programs or
executables being controlled by a single GDB, in contrast to a single
program with multiple processes or forks, a la Michael's machinery for
Linux forks. So although we often use the term "multiprocess", it's
perhaps more precise to call it "multiprogram" or "multiexec" GDB.

The first thing is to figure out is how this should all work for the GDB
user. The command above seems like a pretty obvious extension;
programmers debugging client/server pairs have long wanted to be able
to do just that, and we've always had to tell them they have to start
up two GDBs and juggle. Since both core files and process ids are
distinguishable from executable names, we can allow intermixing of all
these on the command line, so that multiple core file and pid
arguments apply to the preceding executables.

Once the debugger is started, but before any of the programs have run,
it seems obvious to have a notion of "current program", so that commands
like "list main" and "break main" will work as usual. The user should
have a way to list the programs ("info programs") and a way to set the
current one. It might also make sense to have a menu option a la C++,
so that "list client_only_fn" works irrespective of the current program,
while "list main" might ask the user which main() is wanted. Another
possibility is to introduce a "program apply <names>|all <cmd>" on the
analogy of the existing thread apply command.

Notice that we don't really want to use the term "process" for any of
this so far, because nothing is running yet and there are no
processes/inferiors; this part is all about the symbol side.

Commands like "file" should get an alternate form or behavior that
adds rather than replaces. Conversely, the user will also want a way
to take programs out of the debugging session. This is not quite the
same as detaching, because the user may want, say, the server to
continue doing its serving thing, but also to have the list etc
commands only work on the client code, no longer be ambiguous.

When it's time to run, the user will want the ability to run anywhere
from one to all of the programs, each with its own argument list. It
should be possible to do this with a single command, so that the user
isn't scrambling to put in all the run commands quickly enough.

Once programs are running, execution control should work in a fashion
generally analogous to what we have for threads now. When something is
stopped, it needs to report program, process, and thread; step and
continue will need a way to specify the program or process being
stepped or continued. User-friendliness suggests that program name
should be accepted as a synonym for process id if there is only one
process for the executable.

Data display will need to have some way to identify the process from
which the data is being taken. It may be useful to have a "process
apply" for print commands, so that the output includes the value of
the expression in each process, especially useful for values that are
expected to be the same in each.

Implementationwise, we will need to replace the single exec target
with a list of execs, and modify symbol machinery to support a
many-many relationship between programs and symbol tables. Although
my inclination is to create a new symbol table for each process'
image of each shared library, that may be excessively expensive.

In addition to thoughts on desired user interface, I would welcome
suggestions on how to add this feature incrementally; the abovementioned
bits are a lot to add all at once!

Stan



您对本贴的看法:鲜花[0] 臭蛋[0]

__________________________________

别没事瞎搞意识强奸,大家都不是8岁小孩了,你又不是赵本山,想给别人洗脑啊?先回家对着镜子把自己洗成白痴去!
把自己塑造成神搞个人崇拜啊?你不就是会装13吗?对不起,俺是农民,就认实实在在看得见的,你那虚幻的太高深,俺不懂。
我是进来拜神的,顺便带点水,很多牛在天上飞,很多仙在空中飘,遮住了阳光,导致小菜无法进行光合作用,再没有水就没法活了。
空间积分可以换礼品了! | 有奖跟帖:服务器节能,奖50-100元图书 | 致电800-858-2903,了解DELL如何为你量身订制笔记本 | 送2G U盘
zx_wing   帅哥 (骑着猪的青蛙)
大天使
学徒



UID:499746
注册:2006-12-4
最后登录: 2008-09-06
帖子:1940
精华:3

可用积分:1624 (家境小康)
信誉积分:100
专家积分:11 (本版:0)
空间积分:0
推广积分:0

来自:成都
状态:...保密...

[资料] [站内短信] [Blog]


顶部
14楼 发表于 2008-7-19 12:18 


QUOTE:
原帖由 cjaizss 于 2008-7-4 21:37 发表
SMP我就不说了,我说说非对称式的.
两个CPU硬核,两个不同的地址空间,接的是不同的RAM.
这个你很容易理解.
两个CPU硬核,相同的地址空间,接的是相同的RAM.
那么它们只是可以在访问相同的存储,然后其实还是各干 ...

版主对NUMA的理解是错误的。
NUMA也只有一个统一的物理地址空间



您对本贴的看法:鲜花[0] 臭蛋[0]

__________________________________


C调 ---- C语言
都是最喜欢的
空间积分可以换礼品了! | 有奖跟帖:服务器节能,奖50-100元图书 | 致电800-858-2903,了解DELL如何为你量身订制笔记本 | 送2G U盘
zx_wing   帅哥 (骑着猪的青蛙)
大天使
学徒



UID:499746
注册:2006-12-4
最后登录: 2008-09-06
帖子:1940
精华:3

可用积分:1624 (家境小康)
信誉积分:100
专家积分:11 (本版:0)
空间积分:0
推广积分:0

来自:成都
状态:...保密...

[资料] [站内短信] [Blog]


顶部
15楼 发表于 2008-7-19 12:29 
此外我想不出多核的调试和单核的有什么不同



您对本贴的看法:鲜花[0] 臭蛋[0]

__________________________________


C调 ---- C语言
都是最喜欢的
空间积分可以换礼品了! | 有奖跟帖:服务器节能,奖50-100元图书 | 致电800-858-2903,了解DELL如何为你量身订制笔记本 | 送2G U盘
版主 cjaizss   帅哥
版主-精灵使



UID:272747
注册:2005-5-26
最后登录: 2008-09-06
帖子:4748
精华:1

可用积分:1721 (家境小康)
信誉积分:100
专家积分:35 (本版:20)
空间积分:1
推广积分:0

状态:...保密...

[资料] [站内短信] [Blog]


顶部
16楼 发表于 2008-7-19 13:06 


QUOTE:
原帖由 zx_wing 于 2008-7-19 12:18 发表

版主对NUMA的理解是错误的。
NUMA也只有一个统一的物理地址空间

我在这里描述是有错误,有误导,我指的并非SMP/AMP,而是多处理器的嵌入式系统设计



您对本贴的看法:鲜花[0] 臭蛋[0]

__________________________________

二十几年来最大的遗憾,并不是少赚了的钱,也不是少交了友,而是永远没有机会为最钟爱的数学真正做点什么,或许这会是这一生的遗憾
做个合格的电子工程师,其实很难

空间积分可以换礼品了! | 有奖跟帖:服务器节能,奖50-100元图书 | 致电800-858-2903,了解DELL如何为你量身订制笔记本 | 送2G U盘
zx_wing   帅哥 (骑着猪的青蛙)
大天使
学徒



UID:499746
注册:2006-12-4
最后登录: 2008-09-06
帖子:1940
精华:3

可用积分:1624 (家境小康)
信誉积分:100
专家积分:11 (本版:0)
空间积分:0
推广积分:0

来自:成都
状态:...保密...

[资料] [站内短信] [Blog]


顶部
17楼 发表于 2008-7-19 13:14 


QUOTE:
原帖由 cjaizss 于 2008-7-19 13:06 发表

我在这里描述是有错误,有误导,我指的并非SMP/AMP,而是多处理器的嵌入式系统设计

哦,那就不懂了。
我以为你说的是另一样东西



您对本贴的看法:鲜花[0] 臭蛋[0]

__________________________________


C调 ---- C语言
都是最喜欢的
空间积分可以换礼品了! | 有奖跟帖:服务器节能,奖50-100元图书 | 致电800-858-2903,了解DELL如何为你量身订制笔记本 | 送2G U盘

首页 » CU论坛 » Linux » 汇总贴列表 » CPU与编译器 »

 


Copyright © 2001-2008 ChinaUnix.net All Rights Reserved     联系我们:

感谢所有关心和支持过ChinaUnix的朋友们    转载本站内容请注明原作者名及出处

京ICP证041476号


清除 Cookies - Linux时代 - Archiver - WAP - TOP

Processed in 0.038608 second(s), 5 queries , Gzip enabled