多線(xiàn)程------外文翻譯.doc
約6頁(yè)DOC格式手機(jī)打開(kāi)展開(kāi)
多線(xiàn)程------外文翻譯,1.multithreaded overviewin computer programming, a basic concept of multiple tasks at the same time try to control. many of the programs are required to design ...
內(nèi)容介紹
此文檔由會(huì)員 wanli1988go 發(fā)布
1. Multithreaded overview
In computer programming, a basic concept of multiple tasks at the same time try to control. Many of the programs are required to design program can stop the job in hand, to deal with other problems, again to return to main process. Through various ways to achieve this objective. In the beginning, the master machine low-level languages of programmers to write some "interrupt service routines", the main process is suspended by the interruption of the hardware level to realize. Although this is a useful method, but make up the transplant program is hard, which caused the other kind of costly problems. Interrupt for those very strong missions real-time is very necessary. But for many other problems, only request will be divided into
independent operation of the procedure of pieces, make the process can more quickly respond to user request.
1.多線(xiàn)程概述
在計(jì)算機(jī)編程中,一個(gè)基本的概念就是同時(shí)對(duì)多個(gè)任務(wù)加以控制。許多程序設(shè)計(jì)問(wèn)題都要求程序能夠停下手頭的工作,改為處理其他一些問(wèn)題,再返回主進(jìn)程??梢酝ㄟ^(guò)多種途徑達(dá)到這個(gè)目的。最開(kāi)始的時(shí)候,那些掌握機(jī)器低級(jí)語(yǔ)言的程序員編寫(xiě)一些“中斷服務(wù)例程”,主進(jìn)程的暫停是通過(guò)硬件級(jí)的中斷實(shí)現(xiàn)的。盡管這是一種有用的方法,但編出的程序很難移植,由此造成了另一類(lèi)的代價(jià)高昂?jiǎn)栴}。中斷對(duì)那些實(shí)時(shí)性很強(qiáng)的任務(wù)來(lái)說(shuō)是很有必要的。但對(duì)于其他許多問(wèn)題,只要求將問(wèn)題劃分進(jìn)入獨(dú)立運(yùn)行的程序片斷中,使整個(gè)程序能更迅速地響應(yīng)用戶(hù)的請(qǐng)求。
最開(kāi)始,線(xiàn)程只是用于分配單個(gè)處理器的處理時(shí)間的一種工具。但假如操作系統(tǒng)本身支持多個(gè)處理器,那么每個(gè)線(xiàn)程都可分配給一個(gè)不同的處理器,真正進(jìn)入“并行運(yùn)算”狀態(tài)。從程序設(shè)計(jì)語(yǔ)言的 角度看,多線(xiàn)程操作最有價(jià)值的特性之一就是程序員不必關(guān)心到底使用了多少個(gè)處理器。程序在邏輯意義上被分割為數(shù)個(gè)線(xiàn)程;假如機(jī)器本身安裝了多個(gè)處理器,那么程序會(huì)運(yùn)行得更快,毋需作出
In computer programming, a basic concept of multiple tasks at the same time try to control. Many of the programs are required to design program can stop the job in hand, to deal with other problems, again to return to main process. Through various ways to achieve this objective. In the beginning, the master machine low-level languages of programmers to write some "interrupt service routines", the main process is suspended by the interruption of the hardware level to realize. Although this is a useful method, but make up the transplant program is hard, which caused the other kind of costly problems. Interrupt for those very strong missions real-time is very necessary. But for many other problems, only request will be divided into
independent operation of the procedure of pieces, make the process can more quickly respond to user request.
1.多線(xiàn)程概述
在計(jì)算機(jī)編程中,一個(gè)基本的概念就是同時(shí)對(duì)多個(gè)任務(wù)加以控制。許多程序設(shè)計(jì)問(wèn)題都要求程序能夠停下手頭的工作,改為處理其他一些問(wèn)題,再返回主進(jìn)程??梢酝ㄟ^(guò)多種途徑達(dá)到這個(gè)目的。最開(kāi)始的時(shí)候,那些掌握機(jī)器低級(jí)語(yǔ)言的程序員編寫(xiě)一些“中斷服務(wù)例程”,主進(jìn)程的暫停是通過(guò)硬件級(jí)的中斷實(shí)現(xiàn)的。盡管這是一種有用的方法,但編出的程序很難移植,由此造成了另一類(lèi)的代價(jià)高昂?jiǎn)栴}。中斷對(duì)那些實(shí)時(shí)性很強(qiáng)的任務(wù)來(lái)說(shuō)是很有必要的。但對(duì)于其他許多問(wèn)題,只要求將問(wèn)題劃分進(jìn)入獨(dú)立運(yùn)行的程序片斷中,使整個(gè)程序能更迅速地響應(yīng)用戶(hù)的請(qǐng)求。
最開(kāi)始,線(xiàn)程只是用于分配單個(gè)處理器的處理時(shí)間的一種工具。但假如操作系統(tǒng)本身支持多個(gè)處理器,那么每個(gè)線(xiàn)程都可分配給一個(gè)不同的處理器,真正進(jìn)入“并行運(yùn)算”狀態(tài)。從程序設(shè)計(jì)語(yǔ)言的 角度看,多線(xiàn)程操作最有價(jià)值的特性之一就是程序員不必關(guān)心到底使用了多少個(gè)處理器。程序在邏輯意義上被分割為數(shù)個(gè)線(xiàn)程;假如機(jī)器本身安裝了多個(gè)處理器,那么程序會(huì)運(yùn)行得更快,毋需作出