C plus plus Concurrency in Action

来源:互联网 发布:淘宝上怎么搜电棍 编辑:程序博客网 时间:2024/05/16 17:28

 these are exciting times for C plus plus users.Eleven years afters the origial C plus plus
standard was published in 1998,the C plus plus standards committee is giving the language and its supporting library a major overhaul.The new C plus plus standard (referred to as C++0x) is due to be published in 2010 and will bring with it a whole swathe of changes that
will make working with C plus plus easier and more productive.
   One of the most significant new features in the C plus plus 0x standard is the support of multi-threaded programs.For the first time,the C plus plus standard will acknowledge the existence of multi-threaded applications in the language, and provide components in the library for writting multi-threaded applications.This will make it possible to write multi-threaded c plus plus programs without relying on platform-specific
extensions,and thus allow us to write portable multi-threaded code with guaranteed behaviour. It also comes at time when programmers are increasingly looking to concurrency in general,and multi-threaded programming in particular in order to improve application performance.
   This book is about writing programs in C++ using multile threads for concurrency,and the C plus plus language features and library facilities that make that possible. I'll start by explaining what I mean by concurrency and multi-threading,and why you would want to use it in your applications.After a quick detour into why you might not want to use it in your application,I'll give an overview of the concurrency support in C plus plus,and round off this chapter with a simple example of C plus plus concurrency in action.Readers experienced with developing multi-threaded applications may wish to skip the early sections.In subsequent chapters we'll cover more extensive examples,and look at the library facilites in more depth.The book will finish with an in-depth reference to all the standard C plus plus library facilities for multi-threading and concurrency.
  So,what do I mean by concurrency and multi-threading ?What is Conncurrency? At the simplest and most basic level,conncurrency ia about two or more separate activities happening at the same time. We encounter concurrency as a natural part of life:we can walk and talk at the same time or perform different actions with each hand,and of course we each go about our lives independently of each other -- yo can watch football whilst I go swimming,and so on.

原创粉丝点击