多处理器编程的艺术
Preface
Acknowledgments
1 Introduction
1.1 Shared Objects and Synchronization
1.2 A Fable
1.2.1 Properties of Mutual Exclusion
1.2.2 The Moral
1.3 The Producer–Consumer Problem
1.4 The Readers–Writers Problem
1.5 The Harsh Realities of Parallel…
查看完整
Acknowledgments
1 Introduction
1.1 Shared Objects and Synchronization
1.2 A Fable
1.2.1 Properties of Mutual Exclusion
1.2.2 The Moral
1.3 The Producer–Consumer Problem
1.4 The Readers–Writers Problem
1.5 The Harsh Realities of Parallel…
查看完整
Maurice Herlihy,哈佛大学的数学学士和麻省理工学院的计算机科学博士,目前为美国布朗大学计算机科学系教授,曾工作于卡内基一梅隆大学和DEC剑桥实验室。他是美国ACM会士。2003年分布式计算D_jkstra奖获得者。
Nir Shavit,以色列希伯来大学的计算机科学博士,自1992年起执教于特拉维夫大学计算机科学系。他曾多年担任麻省理工学院的客座教授,自1999年以来担任Sun实验室的技术人员。
两位作者是2004年ACM/EATCS Godel奖的共同获得者,具有40多年一起从事并发程序设计教学的合作经验。
Nir Shavit,以色列希伯来大学的计算机科学博士,自1992年起执教于特拉维夫大学计算机科学系。他曾多年担任麻省理工学院的客座教授,自1999年以来担任Sun实验室的技术人员。
两位作者是2004年ACM/EATCS Godel奖的共同获得者,具有40多年一起从事并发程序设计教学的合作经验。
本书循序渐进地讲述共享存储器多线程编程的基础知识;详细解释当今多处理器硬件对并发程序设计的支持方式;全面考察主流的并发数据结构及其关键设计要素;从简单的锁机制到新的事务内存系统,独立、完整地阐述了同步技术。利用Java并发工具包编写的可完全执行的Java实例。附录提供了主要的硬件及采用其他程序设计语言和包(如#、C及C++的Pthreads库)进行编程的相关背景知识。
Preface
Acknowledgments
1 Introduction
1.1 Shared Objects and Synchronization
1.2 A Fable
1.2.1 Properties of Mutual Exclusion
1.2.2 The Moral
1.3 The Producer–Consumer Problem
1.4 The Readers–Writers Problem
1.5 The Harsh Realities of Parallelization
1.6 Parallel Programming
1.7 Chapter Notes
1.8 Exercises
Ⅰ PRINCIPLES
2 Mutual Exclusion
2.1 Time
2.2 Critical Sections
2.3 2-Thread Solutions
2.3.1 The LockOne Class
2.3.2 The LockTwo Class
2.3.3 The Peterson Lock
2.4 The Filter Lock
2.5 Fairness
2.6 Lamport’s Bakery Algorithm
2.7 Bounded Timestamps
2.8 Lower Bounds on the Number of Locations
2.9 Chapter Notes
2.10 Exercises
3 Concurrent Objects
3.1 Concurrency and Correctness
3.2 Sequential Objects
3.3 Quiescent Consistency
3.3.1 Remarks
3.4 Sequential Consistency
3.4.1 Remarks
3.5 Linearizability
3.5.1 Linearization Points
3.5.2 Remarks
3.6 Formal Definitions
3.6.1 Linearizability
3.6.2 Compositional Linearizability
3.6.3 The Nonblocking Property
3.7 Progress Conditions
3.7.1 Dependent Progress Conditions
3.8 The Java Memory Model
3.8.1 Locks and Synchronized Blocks
3.8.2 Volatile Fields
3.8.3 Final Fields
……
4 Foundations of Shared Memory
5 The Relative Power of Primitive Synchronization Operations
6 Universality of Consensus
Ⅱ PRACTICE 7 Spin Locks and Contention
8 Monitors and Blocking Synchronization
9 Linked Lists: The Role of Locking
10 Concurrent Queues and the ABA Problem
11 Concurrent Stacks and Elimination
12 Counting, Sorting, and Distributed Coordination
13 Concurrent Hashing and Natural Parallelism
14 Skiplists and Balanced Search
15 Priority Queues
16 Futures, Scheduling, andWork Distribution
17 Barriers
18 Transactional Memory
Ⅲ APPENDIXBibliography
Index
^ 收 起
Acknowledgments
1 Introduction
1.1 Shared Objects and Synchronization
1.2 A Fable
1.2.1 Properties of Mutual Exclusion
1.2.2 The Moral
1.3 The Producer–Consumer Problem
1.4 The Readers–Writers Problem
1.5 The Harsh Realities of Parallelization
1.6 Parallel Programming
1.7 Chapter Notes
1.8 Exercises
Ⅰ PRINCIPLES
2 Mutual Exclusion
2.1 Time
2.2 Critical Sections
2.3 2-Thread Solutions
2.3.1 The LockOne Class
2.3.2 The LockTwo Class
2.3.3 The Peterson Lock
2.4 The Filter Lock
2.5 Fairness
2.6 Lamport’s Bakery Algorithm
2.7 Bounded Timestamps
2.8 Lower Bounds on the Number of Locations
2.9 Chapter Notes
2.10 Exercises
3 Concurrent Objects
3.1 Concurrency and Correctness
3.2 Sequential Objects
3.3 Quiescent Consistency
3.3.1 Remarks
3.4 Sequential Consistency
3.4.1 Remarks
3.5 Linearizability
3.5.1 Linearization Points
3.5.2 Remarks
3.6 Formal Definitions
3.6.1 Linearizability
3.6.2 Compositional Linearizability
3.6.3 The Nonblocking Property
3.7 Progress Conditions
3.7.1 Dependent Progress Conditions
3.8 The Java Memory Model
3.8.1 Locks and Synchronized Blocks
3.8.2 Volatile Fields
3.8.3 Final Fields
……
4 Foundations of Shared Memory
5 The Relative Power of Primitive Synchronization Operations
6 Universality of Consensus
Ⅱ PRACTICE 7 Spin Locks and Contention
8 Monitors and Blocking Synchronization
9 Linked Lists: The Role of Locking
10 Concurrent Queues and the ABA Problem
11 Concurrent Stacks and Elimination
12 Counting, Sorting, and Distributed Coordination
13 Concurrent Hashing and Natural Parallelism
14 Skiplists and Balanced Search
15 Priority Queues
16 Futures, Scheduling, andWork Distribution
17 Barriers
18 Transactional Memory
Ⅲ APPENDIXBibliography
Index
^ 收 起
Maurice Herlihy,哈佛大学的数学学士和麻省理工学院的计算机科学博士,目前为美国布朗大学计算机科学系教授,曾工作于卡内基一梅隆大学和DEC剑桥实验室。他是美国ACM会士。2003年分布式计算D_jkstra奖获得者。
Nir Shavit,以色列希伯来大学的计算机科学博士,自1992年起执教于特拉维夫大学计算机科学系。他曾多年担任麻省理工学院的客座教授,自1999年以来担任Sun实验室的技术人员。
两位作者是2004年ACM/EATCS Godel奖的共同获得者,具有40多年一起从事并发程序设计教学的合作经验。
Nir Shavit,以色列希伯来大学的计算机科学博士,自1992年起执教于特拉维夫大学计算机科学系。他曾多年担任麻省理工学院的客座教授,自1999年以来担任Sun实验室的技术人员。
两位作者是2004年ACM/EATCS Godel奖的共同获得者,具有40多年一起从事并发程序设计教学的合作经验。
本书循序渐进地讲述共享存储器多线程编程的基础知识;详细解释当今多处理器硬件对并发程序设计的支持方式;全面考察主流的并发数据结构及其关键设计要素;从简单的锁机制到新的事务内存系统,独立、完整地阐述了同步技术。利用Java并发工具包编写的可完全执行的Java实例。附录提供了主要的硬件及采用其他程序设计语言和包(如#、C及C++的Pthreads库)进行编程的相关背景知识。
比价列表