多线程数据回传服务器软件的设计与实现  被引量:2

A Design and Implementation of Multi-thread Data-transporting Server

在线阅读下载全文

作  者:王晋兴[1] 朱敏[1] 

机构地区:[1]中国科学院声学研究所

出  处:《微计算机信息》2007年第25期295-297,共3页Control & Automation

基  金:国家863计划十五重大专项资助项目(2002AA401000)

摘  要:多线程的工作方式具有并发执行任务、提高系统工作量的特点,但线程间异步独立的运行会引起资源竞争的问题,因此对多个线程要进行正确有效的同步,以保证整个系统稳定高效的运行。本文研究了基于Linux操作系统的多线程、多任务工作方式,分析了互斥量和条件变量这两种典型的同步机制,并对它们的性能进行比较;根据比较结果,选取条件变量的同步机制,设计和实现了多线程数据传输服务器软件,并运用扩展的线程同步操作状态图对该方案进行了详细的描述。应用该设计方案,即使在线程间发生竞争的情况下,服务器软件的整体数据的传输工作也可正确高效的完成。Multi-thread,Multi-task working mode can effectively improve a system's throughput, However, this concurrency mode also brings problems such as resource racing and contentions. To solve those problems, synchronization between threads is essential. In this paper synchronizing models and their performance under Linux operating system are studied. As a result, Conditional Variable Synchronization is adopted to design a multi-thread Data-transporting Server Software. An extended Live Sequence Chart is proposed to describe more complicate and specific synchronizing process of the server. Through the implementation of this design, even the racing conditions may occur, the server software could efficiently accomplish its data-transporting task.

关 键 词:多线程 同步机制 线程同步操作状态图 

分 类 号:TP311[自动化与计算机技术—计算机软件与理论]

 

参考文献:

正在载入数据...

 

二级参考文献:

正在载入数据...

 

耦合文献:

正在载入数据...

 

引证文献:

正在载入数据...

 

二级引证文献:

正在载入数据...

 

同被引文献:

正在载入数据...

 

相关期刊文献:

正在载入数据...

相关的主题
相关的作者对象
相关的机构对象