<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Japnanese vietnamese blog &#187; 日本語から英語にかけて</title>
	<atom:link href="http://vija.wordpress.com/category/%e6%97%a5%e6%9c%ac%e8%aa%9e%e3%81%8b%e3%82%89%e8%8b%b1%e8%aa%9e%e3%81%ab%e3%81%8b%e3%81%91%e3%81%a6/feed/" rel="self" type="application/rss+xml" />
	<link>http://vija.wordpress.com</link>
	<description>Just another WordPress.com weblog</description>
	<lastBuildDate>Fri, 16 May 2008 15:20:44 +0000</lastBuildDate>
	<generator>http://wordpress.com/</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<cloud domain='vija.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://www.gravatar.com/blavatar/a7178ae64b8aad106b886004e42589b8?s=96&#038;d=http://s.wordpress.com/i/buttonw-com.png</url>
		<title>Japnanese vietnamese blog &#187; 日本語から英語にかけて</title>
		<link>http://vija.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://vija.wordpress.com/osd.xml" title="Japnanese vietnamese blog" />
		<item>
		<title>Linux&#8217;process</title>
		<link>http://vija.wordpress.com/2008/05/11/linuxprocess/</link>
		<comments>http://vija.wordpress.com/2008/05/11/linuxprocess/#comments</comments>
		<pubDate>Sun, 11 May 2008 16:47:01 +0000</pubDate>
		<dc:creator>hoangthangdt2</dc:creator>
				<category><![CDATA[日本語から英語にかけて]]></category>

		<guid isPermaLink="false">http://vija.wordpress.com/?p=4</guid>
		<description><![CDATA[



3.1. プロセル、ライトウエートプロセス、スレッド

Processという用語はいくらかの異なった意味をよく使われる。本ブックで、プロセスは実行におけるプログラムのインスタンスです。
The term &#8220;process&#8221; is often used with several different meanings. In this book, a process is an instance of a program in execution.
プロセスは人間のように：あれかが発生され、長く有意義な生活まはは短く有意義な生活があり、１以上の子供を発生し、最小的に死んでしまいます。小さい違いはプロセスの中でSexがない、各プロセスは父親または母親がいる。
Processes are like human beings: they are generated, they have  a more or less significant life, they optionally generate one or more child  processes, and eventually they die. A small [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=vija.wordpress.com&blog=3694360&post=4&subd=vija&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><table border="0" cellspacing="0" cellpadding="0" width="100%">
<tbody>
<tr>
<td valign="top"><a name="understandlk-CHP-3-SECT-1"></a></p>
<h3 class="docSection1Title">3.1. プロセル、ライトウエートプロセス、スレッド</h3>
<p><a name="IDX-CHP-3-0635"></a><a name="IDX-CHP-3-0636"></a><a name="IDX-CHP-3-0637"></a><a name="IDX-CHP-3-0638"></a><a name="IDX-CHP-3-0639"></a></p>
<p class="docText">Processという用語はいくらかの異なった意味をよく使われる。本ブックで、プロセスは実行におけるプログラムのインスタンスです。</p>
<p class="docText">The term &#8220;process&#8221; is often used with <span style="font-family:Trebuchet MS;">several different meanings</span>. In this book, a <span class="docEmphasis">process</span> is an instance of a program in execution.</p>
<p class="docText">プロセスは人間のように：あれかが発生され、長く有意義な生活まはは短く有意義な生活があり、１以上の子供を発生し、最小的に死んでしまいます。小さい違いはプロセスの中でSexがない、各プロセスは父親または母親がいる。</p>
<p class="docText">Processes are like human beings: they are generated, they have  a more or less significant life, they optionally generate one or more child  processes, and eventually they die. A small difference is that sex is not really  common among processes each process has just one parent.</p>
<p class="docText">カーネルの観点から、プロセスの目的はシステム資源（CPUタイム、メモリ、。。）が割り当てられるエンティティとして機能することです。</p>
<p class="docText">From the kernel&#8217;s point of view, the purpose of a process is to  act as an entity to which system resources (CPU time, memory, etc.) are  allocated.</p>
<p class="docText">プロセスが生成されるときそれは親とほとんど同じです。親のアドレススペス空き間の複写を受け入れ、親と同じコードで実行、プロセスを生成するシステムコールに続く次の命令に創める。だけれども、親子ほプログラムコード（Text)を含むページが共用できますが、それかには別々にコピーされたデータ（スタックとヒープ）があり、このデータは子に親が見えないメモリ位置へ変更されます。</p>
<p class="docText">When a process is created, it is almost identical to its  parent. It receives a (logical) copy of the parent&#8217;s address space and executes  the same code as the parent, beginning at the next instruction following the  process creation system call. Although the parent and child may share the pages  containing the program code (text), they have separate copies of the data (stack  and heap), so that changes by the child to a memory location are invisible to  the parent。</p>
<p class="docText">初期のUnixカーネルはこの簡単なモデルを使用しますが、近代のUnixシステムは使用ません。<strong>それかがマルチスレッドアプリケーションをサポート、ユーザプログラムが　アプリケーションデータ構造の大半を共有する　多くの相対的に独立している実行があります</strong>。そのようなシステムで一つのプロセルはいくらかのユーザスレッド（または簡単なスレッド）を含み、各スレッドは一つの実行流動のプレセルを代表します。現在、ほとんどのマルチスレッドアプリケーションがpThreadライブラリと呼ばれているセットのライブラリ機能を使って書かれている。</p>
<p class="docText">While earlier Unix kernels employed this simple model, modern  Unix systems do not. They support <span class="docEmphasis">multithreaded  applications</span><a name="IDX-CHP-3-0640"></a> <span style="font-family:メイリオ;">user programs  having many relatively independent execution flows sharing a large portion of  the application data structures.</span> In such systems, a process is composed  of several <span class="docEmphasis">user threads</span><a name="IDX-CHP-3-0641"></a> (or simply <span class="docEmphasis">threads</span>),  each of which represents an execution flow of the process. Nowadays, most  multithreaded applications are written using standard sets of library functions  called <span class="docEmphasis">pthread (POSIX thread) libraries</span><a name="IDX-CHP-3-0642"></a> .</p>
<p class="docText">提供したの年嵩なバージョンのLinuxカーネルはマルチスレッドをサポートしません。カーネルの観点から、マルチスレッドアプリケーションは普通のプロセルみたいです。マルチプル実行流動のマルチスレッドアプリケーションがいつも手段のPOSIX-Complicant　pthread　ライブラリに全くユーザモード上で生成され、ハンドルされ、スケジュールされます。</p>
<p class="docText"><span style="font-family:Trebuchet MS;">Older</span> versions of the Linux  kernel offered no support for multithreaded applications. From the kernel point  of view, a multithreaded application was just a normal process. The multiple  execution flows of a multithreaded application were created, handled, and  scheduled entirely in User Mode, usually by means of a POSIX-compliant <span class="docEmphasis">pthread</span> library.</p>
<p class="docText">しかし、実装のマルチスレッドアプリケーションのようにあまり満足しません。インスタンスにとって、一つのチェスプログラムは二つのスレッドを使うのを仮定：それかの一つがグラフィックチェス盤を制御し、移植のヒューマンフレーやーを持ち、移植のコンピューターを表示、その間　他のスレッドがじっくり次の移植のゲームを考えています。一番目のスレッドがヒューマン移植を持っているうち、二番目のスレッドが走り続くすべきである、そのように考えるタイムのヒューマンプレーヤーが利用されます。ところが、チェスプログラムはシングヅプロセルだけだったら、一番目のスレッドはユーザ行動を待つために簡単にブロッキングシステムコールを発行できません；別の方法で二番目のスレッドが妨げられます。その代わりに残っているプロセルが走られる可能を確実するために一番目のスレッドが複雑にする非ブロッキング技術を使用しなければなりません。</p>
<p class="docText">However, such an implementation of multithreaded applications  is not very satisfactory. For instance, suppose a chess program uses two  threads: one of them controls the graphical chessboard, waiting for the moves of  the human player and showing the moves of the computer, while the other thread  ponders the next move of the game. While the first thread waits for the human  move, the second thread should run continuously, thus exploiting the thinking  time of the human player. However, if the chess program is just a single  process, the first thread cannot simply issue a blocking system call waiting for  a user action; otherwise, the second thread is blocked as well. Instead, the  first thread must employ sophisticated nonblocking techniques to ensure that the  process runnable.</p>
<p class="docText">もっとよくマルチスレッドアプリケーションをサポートするためにLinuxはライトウエートプロセスを使用します。基本的に、二つのライトウエートプロセスの中でいくらのリソースを共有するかもしれない、たぶんアドレススペース、開いているフィルなど。それかの一つが共有したリソースを改変する時はいつも、片方がすぐに変化をみます。もちろん、共有したリソースへアクセスするとき二つのプロセスの中はシンクロナイズしなければなりません。</p>
<p class="docText">Linux uses <span class="docEmphasis">lightweight  processes</span><a name="IDX-CHP-3-0643"></a> <a name="IDX-CHP-3-0644"></a>to offer  better support for multithreaded applications. Basically, two lightweight  processes may share some resources, like the address space, the open files, and  so on. Whenever one of them modifies a shared resource, the other immediately  sees the change. Of course, the two processes must synchronize themselves when  accessing the shared resource.</p>
<p class="docText">マルチスレッドアプリケーションを実装するために分かりやすい方法はライトウエートプロセスが各スレッドに仲間することである。この方法でスレッドは同じアドレススペースや、同じセットの開いているファイルなどを共有することで、同じセットのアプリケーションデータ構造にアクセスできます。同時に各スレッドがカーネルに独立してスケジュールさせられて、一つは残っているものが走る可能の間、永眠できます。</p>
<p class="docText">A straightforward way to implement multithreaded applications  is to associate a lightweight process with each thread. In this way, the threads  can access the same set of application data structures by simply sharing the  same memory address space, the same set of open files, and so on; at the same  time, each thread can be scheduled independently by the kernel so that one may  sleep while another remains runnable.</p>
<p class="docText">POSIX-compliant　マルチスレッドアプリケーションはスレッドグルプをサポートするカーネルに一番良くハンドルされます。Linuxにおけてスレッドグルプは基本的に<span style="font-family:Courier New;color:#790029;">getpid( )</span>や<span style="font-family:Courier New;color:#790029;">kill( )やexit(  )などが</span>マルチスレッドを実装するセットのライトウエートプロセスのととです。本章、より遅くそれかを記述するつもりです。</p>
<p class="docText">POSIX-compliant multithreaded applications are best handled by  kernels that support &#8220;thread groups<a name="IDX-CHP-3-0645"></a> .&#8221; In Linux a  <span class="docEmphasis">thread group</span> is basically a set of lightweight  processes that implement a multithreaded application and act as a whole with  regards to some system calls such as <tt>getpid( )</tt><a name="IDX-CHP-3-0646"></a> , <tt>kill( )</tt><a name="IDX-CHP-3-0647"></a> , and  <tt>_exit( )</tt><a name="IDX-CHP-3-0648"></a> . We are going to describe them at  length later in this chapter.</p>
</td>
</tr>
</tbody>
</table>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/vija.wordpress.com/4/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/vija.wordpress.com/4/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/vija.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/vija.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/vija.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/vija.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/vija.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/vija.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/vija.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/vija.wordpress.com/4/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/vija.wordpress.com/4/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/vija.wordpress.com/4/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=vija.wordpress.com&blog=3694360&post=4&subd=vija&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://vija.wordpress.com/2008/05/11/linuxprocess/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/585a4a3058ceb11bda0b7571b3316d0e?s=96&#38;d=identicon" medium="image">
			<media:title type="html">hoangthangdt2</media:title>
		</media:content>
	</item>
		<item>
		<title>皆さんこんにちは!</title>
		<link>http://vija.wordpress.com/2008/05/10/hello-world/</link>
		<comments>http://vija.wordpress.com/2008/05/10/hello-world/#comments</comments>
		<pubDate>Sat, 10 May 2008 15:43:24 +0000</pubDate>
		<dc:creator>hoangthangdt2</dc:creator>
				<category><![CDATA[日本語から英語にかけて]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[本ブログは日本語の勉強のために設備するのでいつも日本語を使ってください。
勉強したい人は一緒に勉強しましょう！
       <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=vija.wordpress.com&blog=3694360&post=1&subd=vija&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>本ブログは日本語の勉強のために設備するのでいつも日本語を使ってください。</p>
<p>勉強したい人は一緒に勉強しましょう！</p>
<img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/vija.wordpress.com/1/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/vija.wordpress.com/1/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/vija.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/vija.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/vija.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/vija.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/vija.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/vija.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/vija.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/vija.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/vija.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/vija.wordpress.com/1/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=vija.wordpress.com&blog=3694360&post=1&subd=vija&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://vija.wordpress.com/2008/05/10/hello-world/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/585a4a3058ceb11bda0b7571b3316d0e?s=96&#38;d=identicon" medium="image">
			<media:title type="html">hoangthangdt2</media:title>
		</media:content>
	</item>
	</channel>
</rss>