Redian新闻
>
如何确保多线程程序在 multicore server 上 用所有的 core
avatar
如何确保多线程程序在 multicore server 上 用所有的 core# Hardware - 计算机硬件
e*e
1
我家快4岁,周末去电影院看Yogi Bear,他说看不懂。
avatar
r*o
2
【 以下文字转载自 SanFrancisco 讨论区 】
发信人: coolbb (kubaobao), 信区: SanFrancisco
标 题: 绝对笑喷!暴强盒饭大叔狂喷“蛋蛋”让张艺谋崩溃了!(zz)
发信站: BBS 未名空间站 (Wed Mar 17 14:06:21 2010, 美东)
avatar
l*9
3
如何确保多线程程序在 multicore server 上确实使用了 所有的 core
to do computing in parallel physically (not logically)
I have a multicore server, which has 24 CPU, each CPU has 6 cores.
It is Intel xzeon X5650 2.67GHz
cpu cores : 6 (support 6 threads)
cpu MHz : 1596.000
totally, I have 24 * 6 = 144 cores.
I designed a multithreaded C++ program with boost/thread.
How to make sure that my program is run by all 144 cores ?
Any help is really appreciated.
thanks
avatar
m*k
4
正常

【在 e******e 的大作中提到】
: 我家快4岁,周末去电影院看Yogi Bear,他说看不懂。
avatar
t*t
5
you may set processor affinity, which makes each thread a preferred core.
however it is not guaranteed. i don't think you can guarantee it anyway.
on linux the command is taskset.

【在 l******9 的大作中提到】
: 如何确保多线程程序在 multicore server 上确实使用了 所有的 core
: to do computing in parallel physically (not logically)
: I have a multicore server, which has 24 CPU, each CPU has 6 cores.
: It is Intel xzeon X5650 2.67GHz
: cpu cores : 6 (support 6 threads)
: cpu MHz : 1596.000
: totally, I have 24 * 6 = 144 cores.
: I designed a multithreaded C++ program with boost/thread.
: How to make sure that my program is run by all 144 cores ?
: Any help is really appreciated.

avatar
s*a
6
去影院看多半不适合这么小的孩子。现在很多电影虽然是卡通,但是还是按照成年人的
习惯来制作,尤其是语速,图像转换等等,说是给孩子看的,其实是给大孩子或成人看
的。比如Toy Story 3,明显的卡通版越狱。
其实4岁的孩子只能看懂电影里的一些东西,而且还可能要看好几遍。所以,最好就是
买个碟,在家反复看,这样,他们还有时间问些问题,有助理解。孩子对电影不像成人
,看一遍就完了,他们可不在乎多看几遍,喜欢的就是那些人物。
avatar
l*9
7
thanks for your reply.
My program needs to run many (about 10,000+) computing tasks.
Each task's run time is very very short (< 0.1 second or even less).
At each iteration, all these tasks are run in parallel. Some of them
need to exchange some data (it is very small) and then go on.
I want to keep all 144 cores as busy as possible so that my program
can be done as fast as possible.
So, I want to associate each task with a distinct thread and schedule
threads as many as possible. Also, try yo make the workload balance
among these cores.
How can I do that from the point of programming ?
Any help is really appreciated.
thanks

【在 t****t 的大作中提到】
: you may set processor affinity, which makes each thread a preferred core.
: however it is not guaranteed. i don't think you can guarantee it anyway.
: on linux the command is taskset.

avatar
c*e
8
啊,我昨天给我儿子放葫芦兄弟,当他看到葫芦娃和老爷爷被抓起来了,就大叫,看到
老爷爷逃跑成功,就鼓掌。我还以为他看懂了呢。我儿子21个月
avatar
O*d
9
OpenMP
avatar
l*t
10
or you may try MPICH2
相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。