过程同步、数据同步。

In computer sciencesynchronization refers to one of two distinct but related concepts: synchronization of processes, and synchronization of dataProcess synchronization refers to the idea that multiple processes are to join up or handshake at a certain point, in order to reach an agreement or commit to a certain sequence of action. Data synchronization refers to the idea of keeping multiple copies of a dataset in coherence with one another, or to maintain data integrity. Process synchronization primitives are commonly used to implement data synchronization.

The need for synchronization does not arise merely in multi-processor systems but for any kind of concurrent processes; even in single processor systems. Mentioned below are some of the main needs for synchronization:

Forks and Joins: When a job arrives at a fork point, it is split into N sub-jobs which are then serviced by n tasks. After being serviced, each sub-job waits until all other sub-jobs are done processing. Then, they are joined again and leave the system. Thus, in parallel programming, we require synchronization as all the parallel processes wait for several other processes to occur.

Producer-Consumer: In a producer-consumer relationship, the consumer process is dependent on the producer process till the necessary data has been produced.

Exclusive use resources: When multiple processes are dependent on a resource and they need to access it at the same time the operating system needs to ensure that only one processor accesses it at a given point in time.This reduces concurrency.

Classic problems of synchronization[edit]

The following are some classic problems of synchronization:

These problems are used to test nearly every newly proposed synchronization scheme or primitive.

Synchronization in Linux[edit]

Linux provides:

Enabling and disabling of kernel preemption replaced spinlocks on uniprocessor systems. Prior to kernel version 2.6, Linux disabled interrupt to implement short critical sections. Since version 2.6 and later, Linux is fully preemptive.

Synchronization in Solaris[edit]

Solaris provides:

https://en.wikipedia.org/wiki/Synchronization_(computer_science)

最新文章

  1. 《C与指针》第十四章练习
  2. 爬虫5 html下载器 html_downloader.py
  3. LightOJ1298 One Theorem, One Year(DP + 欧拉函数性质)
  4. QT中QWS的含义 (转至 宋金时的专栏
  5. Postgres 9.4 feature highlight: REPLICA IDENTITY and logical replication
  6. 安装和配置JDK,并给出安装、配置JDK的步骤。
  7. JAVA必背面试题和项目面试通关要点
  8. (C#) What is the difference between "const" and "static readonly" ?
  9. 【剑指offer】面试题25:二叉树中和为某一值的路径
  10. SQL Server中的临时表和表变量
  11. poj 3273 Monthly Expense (二分搜索,最小化最大值)
  12. php薪资
  13. Pythagorean Triples
  14. bash脚本基础
  15. Redis环境搭建(MacOS)
  16. 2、jQuery的Ajax简单示例
  17. java项目部署常用linux命令
  18. 直接添加viewController中的view时的注意事项
  19. c#连接Redis Redis的安装与配置
  20. Python3中urllib使用介绍

热门文章

  1. 利用PBFunc在Powerbuilder中进行图片格式转换
  2. 杭电 2817 A sequence of numbers【快速幂取模】
  3. The German Collegiate Programming Contest 2017
  4. Day73-CMDB(资产管理采集)的三种实现方式
  5. jq——属性和方法
  6. thinkPHP利用ajax异步上传图片并显示、删除
  7. 决策树(Decision Trees)
  8. 论文阅读笔记“Attention-based Audio-Visual Fusion for Rubust Automatic Speech recognition”
  9. 论wpf的设备无关性 - 简书
  10. 旋转VR相机不头晕:一个反直觉的发现