2011-07-22 12 views
1

私はpthread_setconcurrency()のmanページを読んで、それが「並行処理レベル」によって何を意味するのか見当がつかないました。それは単に曖昧な用語です。同時実行レベルがスケジューリングポリシーに&プロセスの優先順位を変更する変更しますか?それは他の何かをしますか? manual page on Linuxからスレッドの同時実行レベルを変更するん何を?

答えて

3

NOTES 
     The default concurrency level is 0. 

     Concurrency levels are only meaningful for M:N threading implementations, where at any moment a subset of a process's set of user-level threads 
     may be bound to a smaller number of kernel-scheduling entities. Setting the concurrency level allows the application to give the system a hint as 
     to the number of kernel-scheduling entities that should be provided for efficient execution of the application. 

     Both LinuxThreads and NPTL are 1:1 threading implementations, so setting the concurrency level has no meaning. In other words, on Linux these 
     functions merely exist for compatibility with other systems, and they have no effect on the execution of a program. 
+0

私が何を「M:N」は考えてきたないので、それは便利ではありません正直に言うと、「1:1」、「結合」と「カーネルスケジューリングの実体」ですが。しかし、あなたがそれらを述べたので、私はそれらを見上げます。 – wmjdgla

+0

私はあなたに答えを書くことを望んでいました。しかし、最初にいくつかの記事を読むことは本当に良いです。スレッドモデルを理解すると、「並行性レベル」という概念を簡単に獲得できます。http://en.wikipedia.org/wiki/Thread_(computer_science)#Models – minjang

関連する問題