JPS60118961A - Common area access control system of memory - Google Patents

Common area access control system of memory

Info

Publication number
JPS60118961A
JPS60118961A JP22604783A JP22604783A JPS60118961A JP S60118961 A JPS60118961 A JP S60118961A JP 22604783 A JP22604783 A JP 22604783A JP 22604783 A JP22604783 A JP 22604783A JP S60118961 A JPS60118961 A JP S60118961A
Authority
JP
Japan
Prior art keywords
access
read
semaphore
memory
common area
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP22604783A
Other languages
Japanese (ja)
Inventor
Sadanari Sugiura
杉浦 貞也
Toshihiro Sakai
酒井 利弘
Toshiharu Oshima
大島 俊春
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Fujitsu Ltd
Original Assignee
Fujitsu Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Fujitsu Ltd filed Critical Fujitsu Ltd
Priority to JP22604783A priority Critical patent/JPS60118961A/en
Publication of JPS60118961A publication Critical patent/JPS60118961A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/14Handling requests for interconnection or transfer
    • G06F13/16Handling requests for interconnection or transfer for access to memory bus

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)

Abstract

PURPOSE:To attain read and write of a semaphor with one access by transmitting a common area occupying signal until an access unit reading the semaphor performs rewrite. CONSTITUTION:The system is constitued that ECC check circuits 3-1-3-n are provided in access units 2-1-2-n so as to use an access mode of a read modify write. In accessing a split area CRk from an access unit 2-i for example, the unit 2-i sets the semaphor Sk to ''1'' by access mode = [read.modity.write] and stores the value of the semaphor Sk read in this case to the unit 2-i. Then the value of the stored semaphor Sk is checked and when the value is ''0'', the split area CRk is made accessible and when the value is ''1'', the area is made disable for accessing.

Description

【発明の詳細な説明】 〔発明の技術分野〕 本発明は、複数のアクセス・ユニットによるメモリの共
通領域のアクセスにおいて、アクセス許可/禁止を示す
セマフォのアクセス競合を回避するようにしたメモリの
共通領域アクセス制御方式%式% 〔従来技術と問題点〕 第1図はデータ処理システムの構成例を示す図である。
DETAILED DESCRIPTION OF THE INVENTION [Technical Field of the Invention] The present invention provides a memory common area that avoids access conflicts of semaphores indicating access permission/prohibition when a plurality of access units access a common memory area. Area Access Control Method % Formula % [Prior Art and Problems] FIG. 1 is a diagram showing an example of the configuration of a data processing system.

第1図において、1はメモリの共通領域、2−1ないし
2−ルはアクセス・ユニットを示す。
In FIG. 1, 1 indicates a common area of memory, and 2-1 and 2-rule indicate access units.

メモリの共通領域(Common Region ) 
1は、CR1ないしCRAに分割され、各々のアークセ
ス・ユニット2−1ないし2−ルは、独立に動作する。
Common region of memory
1 is divided into CR1 to CRA, and each arc access unit 2-1 to 2-R operates independently.

ここで、成るアクセス・ユニッl−2−i(1≦L≦r
L)がメモリの共通領域1の分割領域CRk(1≦に≦
l)をアクセスしていたとき、他のアクセス・ユニット
が同じく分割領域CR,をアクセスすると、分割領域C
Rkの内容は保証されなくなってしまう。そこで、分割
領域CR,ないしCRtのアクセス許可/禁止を示すセ
マ7 オ(Semaphore ) StないしStを
メモリの共通領域1にその分割に対応して設ける方法が
一般に知られている。この方法では、分割領域CR&を
アクセスするときは先にセマフォSkを読み出し、その
値により以下のように処理される。
Here, the access unit consisting of l-2-i (1≦L≦r
L) is the divided area CRk (1≦≦ of the memory common area 1)
l), when another access unit also accesses the divided area CR, the divided area C
The contents of Rk are no longer guaranteed. Therefore, a method is generally known in which semaphores St to St indicating permission/inhibition of access to the divided areas CR to CRt are provided in the common area 1 of the memory corresponding to the division. In this method, when accessing the divided region CR&, the semaphore Sk is first read out, and the following processing is performed based on its value.

■ セマフォSk=ゝ1′(分割領域CRkのアクセス
禁+、)−)の場合、他のプログラムを実行するか、セ
マフォSkが解除されるまで待つ。
(2) If semaphore Sk=1' (prohibited access to divided area CRk+,)-), execute another program or wait until semaphore Sk is released.

■ セマフォ5k==゛0′(分割領域CRkのアクセ
ス許可)の場合、セマフォ5k−11′にして、他のア
クセス中ユニットからのアクセスを禁止し、分割領域C
R,のアクセスを開始する。そして、分割領域CRkの
アクセスを完了すると再びセマフォsk=ゝ0′とする
■ If semaphore 5k==゛0' (access permission for divided area CRk), set semaphore 5k-11' to prohibit access from other accessing units, and
Start accessing R. Then, when the access to the divided area CRk is completed, the semaphore sk is set to 0' again.

このような方法による従来のセマフォ読み出し及び書き
換えは、以下のように行われる。
Conventional semaphore reading and rewriting using such a method is performed as follows.

■ アクセスしたい分割領域CR&に対応するセマフオ
Skを読み出す。
■ Read the semaphore Sk corresponding to the divided area CR& that you want to access.

■ セマフォsk= ’o’を確認する。■ Check semaphore sk = 'o'.

■ セマフォSkに11′を會き込む。■ Insert 11' into semaphore Sk.

これを、例えば2つのアクセス争ユニット2−iと2−
ノが同時に分割領域CRkをアクセスしようとする場合
について示したのが第2図である。このような場合、第
2図から明らか々ように、2つのアクセス中ユニッ)2
−iと2−1が同じ分割領域CRkを同時にアクセスし
てしま−うことになる。
For example, two access contention units 2-i and 2-
FIG. 2 shows a case in which both parties attempt to access divided region CRk at the same time. In such a case, as is clear from Fig. 2, the two accessing units)
-i and 2-1 will access the same divided area CRk at the same time.

そこで、先にセマフォSkを読み出したアクセス・ユニ
ット2−iは、セマフォSkの書き込みを行うまで共通
領域占有信号(lock信号)を出す必要がある。共通
領域占有信号は、成るアクセス・ユニットが共通領域を
アクセスしている間、他のアクセス・ユニットからのそ
の共通領域へのアクセスを抑える信号である。そのため
、従来は、制御回路が複雑になるなどの問題があった。
Therefore, the access unit 2-i that read the semaphore Sk first needs to issue a common area occupation signal (lock signal) until it writes the semaphore Sk. The common area occupancy signal is a signal that suppresses access to the common area from other access units while the access unit is accessing the common area. Therefore, conventionally, there have been problems such as a complicated control circuit.

〔発明の目的〕[Purpose of the invention]

本発明は、上記の考察に基づくものであって、セマフォ
の読み出しから書き換えまでを1回のアクセスで行い、
他のアクセス・ユニットからのアクセスを禁止する必要
のないメモリの共通領域アクセス制御方式を提供するこ
とを目的とするものである。
The present invention is based on the above considerations, and includes reading and rewriting a semaphore in one access.
It is an object of the present invention to provide a memory common area access control method that does not require prohibiting access from other access units.

〔発明の構成〕[Structure of the invention]

そのために本発明のメモリの共通領域アクセス制御方式
は、共通領域を分割し分割に対応してアクセス許可/禁
止を示すセマフォ・ヒ゛ットを有するメモリと該メモリ
をアクセスする複数のアクセス・ユニットとを備えたデ
ータ処理システムにおいて、上記複数のアクセスやユニ
ットのそれぞれは、上記共通領域をアクセスする際、1
回のアクセスによりセマフォ・ビットを読み込み且つア
クセス禁IJ−に書き換える処理を行うとともに読み込
んだセマフォ・ビットの内容を保持し、しかる後、保持
したセマフォ・ビットの内容がアクセス許可の状態を示
しているかアクセス禁止の伏線を示しているかを調べる
処理を行うように構成されたことを特徴とするものであ
る。
To this end, the memory common area access control system of the present invention divides a common area and includes a memory having semaphore bits indicating access permission/prohibition corresponding to the division, and a plurality of access units that access the memory. In the data processing system, each of the plurality of accesses and units accesses the common area,
With each access, the semaphore bits are read and rewritten to access-prohibited IJ-, and the contents of the read semaphore bits are retained, and after that, whether the contents of the retained semaphore bits indicate the access permission status. This feature is characterized in that it is configured to perform processing to check whether there is a foreshadowing of access prohibition.

〔発明の実施例〕[Embodiments of the invention]

以下、本発明の実施例を図面を参照しつつ説明する。 Embodiments of the present invention will be described below with reference to the drawings.

第3図は本発明の1実施例構収を示す図、第4図はアク
セス−ユニット内の構成を示すブロック図である。図に
おいて、1と2−1ないし2−ルは第1図に対応するも
のを示し、3−1ないし3− nはECC(Error
 Checking and Correctfon 
)回路、4はメモリ、5は読み出しデータ・レジスタ、
6はエラー訂正回路、7はセマフォ・ビット・レジスタ
、8はパリティ作成回路、9はアライナを示す。
FIG. 3 is a diagram showing the configuration of one embodiment of the present invention, and FIG. 4 is a block diagram showing the internal configuration of the access unit. In the figure, 1 and 2-1 to 2-n indicate those corresponding to FIG. 1, and 3-1 to 3-n indicate ECC (Error
Checking and correct phone
) circuit, 4 is memory, 5 is read data register,
6 is an error correction circuit, 7 is a semaphore bit register, 8 is a parity generation circuit, and 9 is an aligner.

本発明は、第3図に示すように、各アクセス・ユニット
2−1カいし2−nにECC回路3−1ないし3− n
に設け、リード・モディファイ・ライトのアクセス・モ
ードを使えるようにする。例えばアクセス・ユニツ)2
−iが分割領域1&をアクセスする場合、アクセス・ユ
ニツl−2−iは、まず分割領域CRkをアクセスする
のに先立ってセマフォSkヲアクセス・モード=1リー
ド・モディファイ・ライト″によって′1″にセットす
る。このとき、読み出したセマフォShの値をアクセス
・ユニット2−2内に保持しておく。そして、この保持
したセマフォSkの値を調べ、セマフォSk の1直7
5二加″である場合には分割領域CRkをアクセス可と
し、セマフォShの値が11“である場合には分割領域
CRkをアクセス不可とする。なお、アクセス・ユニッ
)2−iは、分割領域CRAのアクセスが終了した場合
にはセマフォSkに10“を書き込み、分割領域CRk
を他のアクセス中ユニットに解放する。
As shown in FIG. 3, the present invention provides ECC circuits 3-1 to 3-n for each access unit 2-1 to 2-n.
, so that read/modify/write access modes can be used. For example, Access Units)2
When -i accesses divided area 1&, access unit l-2-i first accesses divided area CRk by writing semaphore Skwo access mode = 1 read modify write'' to '1''. Set to . At this time, the read value of semaphore Sh is held in the access unit 2-2. Then, check the value of this retained semaphore Sk, and check the value of semaphore Sk.
If the value of the semaphore Sh is 11'', the divided area CRk is made accessible, and if the value of the semaphore Sh is 11'', the divided area CRk is made inaccessible. Note that when the access unit) 2-i finishes accessing the divided area CRA, it writes 10" to the semaphore Sk, and writes 10" to the divided area CRk.
to other accessing units.

アクセス・ユニット内の構成を示したのが第4図である
。第4図において、読み出しデータ・レジスタ5はメモ
リ4からの読み出しデータをラッチするものであり、エ
ラー訂正回路6は読み出しデータのエラー訂正を行うも
のであり、パリティ作成回路8はデータ訂正に必要なパ
リティを作成するものでちる。アライナ9は、アクセス
・モード−1ライト“により書き込みデータのみを選択
し、アクセス争モード=1リード・モディファイ慟ライ
ト“により読み出しデータと書き込みデータを選択する
ものである。例えば、読み出しデータが16+2パリテ
イとすると、書き込みデータは、16+2パリテイの場
合と8+1パリテイの場合とがある。
FIG. 4 shows the configuration inside the access unit. In FIG. 4, the read data register 5 latches the read data from the memory 4, the error correction circuit 6 corrects errors in the read data, and the parity creation circuit 8 performs the necessary correction for the data. It's something that creates parity. The aligner 9 selects only write data in the access mode=1 write, and selects read data and write data in the access contest mode=1 read/modify/write. For example, if the read data has a parity of 16+2, the write data may have a parity of 16+2 or a parity of 8+1.

ライト時(2BWrite時)、アライナ9の出力は書
き込みデータが16ピツトとなる。リード拳モディファ
イ・ライト時(IBWrite時)、アライナ9の出力
は読み出しデータと書き込みデータがそれぞれ8ビツト
、全体で16ビツトとなる。なお、メモリ書き込み時は
データ・パリティは必要としない。以上の読み出しデー
タ・レジスタ5、エラー訂正回路6、パリティ作成回路
8とアライナ9によりECC回路を構成する。セマフォ
・ビット・レジスタ7は、読み出しデータ僧レジスタ5
、エラー訂正回路6を通して読み出したデータのセマフ
ォ会ビットをラッチするものである。セマフォ・ビット
が、アクセス・モード=1リード・モディファイ争ライ
ト“によシセマフi・ビット・レジスタ7にラッチされ
ると、その後このラッチした内容をみてメモリ4の共通
領域のアクセスが可能か否かを調べる。
At the time of writing (during 2BWrite), the output of the aligner 9 is written data of 16 pits. At the time of read fist modify write (IBWrite), the output of the aligner 9 is 8 bits each for read data and write data, and 16 bits in total. Note that data parity is not required when writing to memory. The read data register 5, error correction circuit 6, parity creation circuit 8, and aligner 9 constitute an ECC circuit. Semaphore bit register 7 is read data register 5
, latches the semaphore bit of data read out through the error correction circuit 6. When the semaphore bit is latched into the semaphore bit register 7 by access mode = 1 read/modify content write, the latched contents are then checked to determine whether access to the common area of memory 4 is possible. Find out.

〔発明の効果〕〔Effect of the invention〕

以上の説明から明らかなように、本発明によれば、リー
ド・モディファイ・ライトにより、セマフォの読み出し
から書き換えまでを1回のアクセスで行うので、従来の
方式のように、セマフォを読み出したアクセス・ユニッ
トが書き換えを行うまで共通領域占有信号を出して他の
アクセス・ユニットからのアクセスを禁止するという必
要がなくなる。従って、制御回路が簡単に々る。
As is clear from the above description, according to the present invention, reading and rewriting the semaphore are performed in one access by read-modify-write. There is no need to issue a common area occupation signal to prohibit access from other access units until a unit performs rewriting. Therefore, the control circuit can be easily constructed.

【図面の簡単な説明】[Brief explanation of drawings]

第1図はデータ処理システムの構成例を示す図、第2図
は2つのアクセス・ユニットが同時に共通領域をアクセ
スしようとする場合の例を説明する図、第3図は本発明
の1実施例構成を示す図、第4図はアクセス・ユニット
内の構成を示すブロック図である。 1・・・メモリの共通領域、2−1ないし2−n・・・
アクセス・ユニット、3−1ないし3−n・・・ECC
回路、4・・・メモリ、5・・・読み出しデータ・レジ
スタ、6・・・エラー訂正回路、7・・・セマフォΦビ
ットーレジスタ、8・・・パリティ作成回路、9・・・
アライナ。 特許出願人 富士通株式会社 状、m→ 盲 谷 四 部
FIG. 1 is a diagram showing an example of the configuration of a data processing system, FIG. 2 is a diagram explaining an example in which two access units attempt to access a common area at the same time, and FIG. 3 is an example of an embodiment of the present invention. FIG. 4 is a block diagram showing the structure inside the access unit. 1... Common area of memory, 2-1 to 2-n...
Access unit, 3-1 to 3-n...ECC
Circuit, 4... Memory, 5... Read data register, 6... Error correction circuit, 7... Semaphore Φ bit register, 8... Parity creation circuit, 9...
aligner. Patent applicant: Fujitsu Ltd., m → Shibuya Shibu

Claims (1)

【特許請求の範囲】[Claims] 共通領域を分割し分割に対応してアクセス許可/禁止を
示すセマフォ拳ビットを有するメモリと該メモリをアク
セスする複数のアクセス・ユニットとを備えたデータ処
理システムにおいて、上記複数のアクセス・ユニットの
それぞれは、上記共通領域をアクセスする際、1回のア
クセスによりセマフォ参ビットを読み込み且つアクセス
禁止に書き換える処理を行うとともに読み込んだセマフ
ォ・ビットの内容を保持し、しかる後、保持したセマフ
ォ・ビットの内容がアクセス許可の状態を示しているか
アクセス禁止の状態を示しているかを調べる処理を行う
ように構成されたことを特徴とするメモリの共通領域ア
クセス制御方式。
In a data processing system comprising a memory having a semaphore bit that divides a common area and indicates access permission/prohibition corresponding to the division, and a plurality of access units that access the memory, each of the plurality of access units When accessing the above common area, the semaphore bit is read and rewritten to prohibit access in one access, and the content of the read semaphore bit is retained, and after that, the content of the retained semaphore bit is 1. A memory common area access control method, characterized in that the method is configured to perform processing to check whether the access is permitted or the access is prohibited.
JP22604783A 1983-11-30 1983-11-30 Common area access control system of memory Pending JPS60118961A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP22604783A JPS60118961A (en) 1983-11-30 1983-11-30 Common area access control system of memory

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP22604783A JPS60118961A (en) 1983-11-30 1983-11-30 Common area access control system of memory

Publications (1)

Publication Number Publication Date
JPS60118961A true JPS60118961A (en) 1985-06-26

Family

ID=16838950

Family Applications (1)

Application Number Title Priority Date Filing Date
JP22604783A Pending JPS60118961A (en) 1983-11-30 1983-11-30 Common area access control system of memory

Country Status (1)

Country Link
JP (1) JPS60118961A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2006047570A1 (en) * 2004-10-22 2006-05-04 Qualcomm Incorporated Method and apparatus for performing an atomic semaphore operation

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS5336441A (en) * 1976-09-17 1978-04-04 Hitachi Ltd Test and setting system
JPS54100628A (en) * 1978-01-25 1979-08-08 Nippon Telegr & Teleph Corp <Ntt> Memory-contention control system
JPS5566042A (en) * 1978-11-13 1980-05-19 Hitachi Ltd Memory control circuit

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS5336441A (en) * 1976-09-17 1978-04-04 Hitachi Ltd Test and setting system
JPS54100628A (en) * 1978-01-25 1979-08-08 Nippon Telegr & Teleph Corp <Ntt> Memory-contention control system
JPS5566042A (en) * 1978-11-13 1980-05-19 Hitachi Ltd Memory control circuit

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2006047570A1 (en) * 2004-10-22 2006-05-04 Qualcomm Incorporated Method and apparatus for performing an atomic semaphore operation
JP2008518329A (en) * 2004-10-22 2008-05-29 クゥアルコム・インコーポレイテッド Method and apparatus for performing atomic semaphore operations
JP2011048834A (en) * 2004-10-22 2011-03-10 Qualcomm Inc Method and apparatus for performing atomic semaphore operation

Similar Documents

Publication Publication Date Title
JPH05324572A (en) Atomic-access-controlled register device
JPS60118961A (en) Common area access control system of memory
WO2016106933A1 (en) Sub-area-based method and device for protecting information of mcu chip
JPH0447349A (en) Data storage device
JP2611491B2 (en) Microprocessor
JPH0486943A (en) Exclusive control system for shared memory
JPS61288243A (en) Processing system for compare and swap instruction
JPH086905A (en) Access arbitration circuit for multi-port ram
JPS6238743B2 (en)
JPH03276346A (en) Memory card
JPS6246358A (en) Error processing system
JPH0266668A (en) Data tracing method for multi-processor bus
JPS59225469A (en) Common memory exclusive control system
JPS59123063A (en) Access system of shared resource of multi-processor system
JPH0259495B2 (en)
JPH0253161A (en) Memory access system
JPS60132263A (en) Storage controlling system
JPS59121455A (en) Prefixing system
JPS6057604B2 (en) Register selection control method
JPH0554005A (en) Multiprocessor system
JPH047762A (en) Memory access method
JPH0388056A (en) System bus lock signal generating circuit
JPS635460A (en) Parallel computer
JPH0696006A (en) Dma controller
JPH04238558A (en) Deadlock preventing circuit for two-port memory