共 1,395 篇文章
共 6,621 篇文章及评论
- Association for Computing Machinery TechNews (ACM)
- Go Parallel! (Dr. Dobbs)
- HPCwire (Tabor Communications, Inc.)
- insideHPC (John West)
- Joe Duffy's Weblog (Microsoft)
- Microsoft Parallel Programming Development Center (Microsoft Germany)
- MultiCoreInfo.com
- scalability.org (Scalable Informatics)
- Software Dev Blog (Intel Germany)
- Soft Talk Blog (Intel United Kingdom)
- The Moth (Microsoft)
Archives
帖子来自 woods2001 
多线程编程-线程的创建和终止
作者: woods2001 (2 篇文章) 日期: 九月 22, 2011 在 1:33 下午
评论 (1)
1.引言: Linux系统下的多线程遵循POSIX线程接口,称为pthread。编写Linux下的多线程程序,需要使用头文件pthread.h,连接时需要使用库libpthread.a。顺便说一下,Linux下pthread的实现是通过系统调用clone()来实现的。clone()是Linux所特有的系统调用,它的使用方式类似fork,关于clone()的详细情况,有兴趣的读者可以去查看有关文档说明。 pthread_t在头文件/usr/include/bits/pthreadtypes.h中定义: typedef unsigned long int pthread_t; 它是一个线程的标识符。 2.函数说明: (1)函数原型: #include int pthread_create(pthread_t *restrict tidp,const pthread_attr_t *restrict ...
分类: 博客征文专栏, 并行计算
多线程编程 - 线程的创建和终止
作者: woods2001 (2 篇文章) 日期: 七月 4, 2011 在 11:03 上午
评论 (0)
1.引言: Linux系统下的多线程遵循POSIX线程接口,称为pthread。编写Linux下的多线程程序,需要使用头文件pthread.h,连接时需要使用库libpthread.a。顺便说一下,Linux下pthread的实现是通过系统调用clone()来实现的。clone()是Linux所特有的系统调用,它的使用方式类似fork,关于clone()的详细情况,有兴趣的读者可以去查看有关文档说明。 pthread_t在头文件/usr/include/bits/pthreadtypes.h中定义: typedef unsigned long int pthread_t; 它是一个线程的标识符。 2.函数说明: (1)函数原型: #include int pthread_create(pthread_t *restrict tidp,const pthread_attr_t *restrict ...
