JPS6224338A - Memory access system - Google Patents

Memory access system

Info

Publication number
JPS6224338A
JPS6224338A JP16348185A JP16348185A JPS6224338A JP S6224338 A JPS6224338 A JP S6224338A JP 16348185 A JP16348185 A JP 16348185A JP 16348185 A JP16348185 A JP 16348185A JP S6224338 A JPS6224338 A JP S6224338A
Authority
JP
Japan
Prior art keywords
data
register
memory
read
address
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
JP16348185A
Other languages
Japanese (ja)
Inventor
Kiyotaka Fujimura
藤村 清孝
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 JP16348185A priority Critical patent/JPS6224338A/en
Publication of JPS6224338A publication Critical patent/JPS6224338A/en
Pending legal-status Critical Current

Links

Abstract

PURPOSE:To obtain the data on the bus width at a high speed by storing the data on the continuous addresses into a data register in the form of an array by reading continuously the continuous addresses of a memory, therefore reading those continuous addresses in plural times. CONSTITUTION:The contents of addresses 0-3 are read out of a memory 1 and used. In such a case, a microprocessor sets the address 0 to be read out first to an address register 2. Then the lower bits of the register 2 are decode by a decoder 4 by a reading indication and only the output 0 is turned on out of those decoding outputs 0-3. Thus a gate 60 is opened to a part D0 of the 4-bit area obtained by dividing a data register 3 of the 16-bits width. Then the read data is written to the part D0 with control of a write gate 30. When a reading indication is given again, the read data is written to a part D1 in the same way. These actions are repeated for storage of data on the addresses 0-3 into parts D0-D3 of the register 3. In such a way, data obtained for each bus and the microprocessor can use immediately these data.

Description

【発明の詳細な説明】 [概 要] マイクロプロセッサのバス幅と異なるビット幅のメモリ
を読み出し、マイクロプロセッサのバス単位に処理を行
う場合、メモリ・アドレスの下位ビットをデコードし、
その値によって、読出しデータを格納すべきデータ・レ
ジスタ内の位置を選択制御できるようにし、連続するア
ドレスの複数回の読出しによって、バス幅のデータを高
速に得ることができるようにしたものである。
[Detailed Description of the Invention] [Summary] When reading memory with a bit width different from the microprocessor bus width and performing processing in microprocessor bus units, the lower bits of the memory address are decoded,
The value allows selection and control of the location in the data register where read data is to be stored, making it possible to obtain bus-width data at high speed by reading consecutive addresses multiple times. .

[産業上の利用分野] 本発明は、マイクロプロセッサによりメモリ素子を読み
出す場合のメモリ・アクセス方式に係わリ、さらに特定
すれば、マイクロプロセッサのバスのビット数と異なる
ビット数の構成を持つメモリ素子を読み出し、使用する
場合の、メモリ・アクセス方式に関するものである。
[Industrial Field of Application] The present invention relates to a memory access method when reading a memory element by a microprocessor, and more specifically, to a memory having a bit number configuration different from the bit number of a microprocessor bus. It relates to memory access methods for reading and using devices.

[従来の技術〕 最近、マイクロプロセッサを使用して機能回路を構成す
ることが多くなっているが、そのような場合に、マイク
ロプロセッサのバスのビット数と、ROM (読出し専
用メモリ)のビット数構成の異なることがしばしばある
[Prior Art] Recently, microprocessors have been increasingly used to construct functional circuits, and in such cases, the number of bits of the microprocessor's bus and the number of bits of ROM (read-only memory) are important. They often have different configurations.

マイクロプロセッサによって、バスのビット数と異なる
ビット数の構成を持つメモリ素子を読み出して、マイク
ロプロセッサのバス単位にデータ処理を行う場合、従来
の技術では、メモリ素子から読み出したデータを、マイ
クロプロセッサ内の演算用レジス逮にロードし、演算用
レジスタのレジスタ・シフト機能を用いて、バス単位に
データを編集した後使用することが必要であった。
When a microprocessor reads out a memory element with a bit number configuration different from the number of bits of the bus and performs data processing on a microprocessor bus basis, conventional technology uses the data read from the memory element to be stored within the microprocessor. It was necessary to load the data into the arithmetic register of the bus, use the register shift function of the arithmetic register, and edit the data for each bus before use.

第4図は、従来例を説明する図であって、マイクロプロ
セッサのバス幅が16ビツト、メモリのビット数が4ビ
ツトである場合の処理例を示す。
FIG. 4 is a diagram illustrating a conventional example, and shows an example of processing when the microprocessor bus width is 16 bits and the memory bit number is 4 bits.

■メモリから第1のアドレスで読み出したデータAをマ
イクロプロセッサ内の演算用レジスタにロードし、 ■演算用レジスタ内データを12ビツトシフトして、他
のレジスタに待避させ、 ■第1のアドレスに+1したアドレスでメモリ読み出し
たデータBを、演算用レジスタにロードし、 ■演算用レジスタ内のデータを8ビツトシフトさせ、 ■待避させた■のデータとの論理和をとって、待避させ
、 ■さらに+1したアドレスで読み出したデータCを、演
算用レジスタにロードし、 ■演算用レジスタ内のデータを4ビツトシフトさせ、 ■待避させた■のデータとの論理和をとって、再び待避
させ、 ■さらに+1させたアドレスで読み出したデータDを、
演算用レジスタにロードし、 [相]待避させた■のデータと論理和をとる。
■Load data A read from the memory at the first address into the calculation register in the microprocessor, ■Shift the data in the calculation register by 12 bits and save it to another register, ■Add 1 to the first address. Load the data B read from the memory at the specified address into the arithmetic register, ■ shift the data in the arithmetic register by 8 bits, ■ logical OR with the saved data in ■ and save it, ■ further +1 Load the data C read at the specified address into the arithmetic register, (1) shift the data in the arithmetic register by 4 bits, (2) perform a logical OR with the saved data (2), and save it again, (2) further +1. The data D read at the specified address is
Load it into the operation register and perform a logical OR with the data of [phase] saved ■.

[発明が解決しようとする問題点] 上記、従来の技術によれば、データの編集処理をマイク
ロプログラム制御で行うため、処理が煩雑であり、且つ
時間がかかるという問題点があった。
[Problems to be Solved by the Invention] According to the above-mentioned conventional technology, the data editing process is performed under microprogram control, so there is a problem that the process is complicated and takes time.

本発明は、このような問題点を解消し、高速読出し処理
のできる、新規なメモリ・アクセス方式を提供しようと
するものである。
The present invention aims to solve these problems and provide a new memory access method capable of high-speed read processing.

c問題点を解決するための手段] 第1図は本発明のメモリ・アクセス方式の原理ブロック
図を示す。
Measures for Solving Problem c] FIG. 1 shows a block diagram of the principle of the memory access method of the present invention.

第1図において、1は読み出すべきメモリであり、2は
メモリlにアクセスするアドレスを格納するアドレス・
レジスタである。
In FIG. 1, 1 is the memory to be read, and 2 is the address that stores the address to access memory l.
It is a register.

3はマイクロプロセッサのバスに接続されているデータ
・レジスタである。       4はアドレス・レジ
スタ2の下位ビットの一部をデコードするデコーダであ
り、そのデコード出力はデータ・レジスタ3ぺのデータ
のセントを制御するのに使用される。
3 is a data register connected to the microprocessor bus. A decoder 4 decodes a part of the lower bits of the address register 2, and its decode output is used to control the data cent of the data register 3.

マイクロプロセッサによって、メモリ1内に記憶してい
るデータを読み出す場合には、マイクロプロセッサはま
ず読み出すアドレスをアドレス・レジスタ2にセットす
る。
When the microprocessor reads data stored in the memory 1, the microprocessor first sets the address to be read in the address register 2.

次いで、マイクロプロセッサは、メモリ1を読み出し、
°データ・レジスタ3ヘセツトする指示を出す。
The microprocessor then reads memory 1,
° Issue an instruction to set data register 3.

アドレス・レジスタ2ヘセツトされたアドレスの下位数
ビットは、デコーダ4に入れられ、デコードされる。
The lower several bits of the address set in address register 2 are input to decoder 4 and decoded.

5はデ、コーダ4のデコード出力によって、メモリlの
読出し出力が、データ・レジスタ3のどの部分にセット
されるかを選択するデータ選択回路である。
Reference numeral 5 denotes a data selection circuit which selects in which part of the data register 3 the readout output of the memory 1 is set based on the decoded output of the decoder 4.

6はメモリ1の読出し出力の、データ・レジスタ3への
書込みを制御するり凸ツク制御回路である。
Reference numeral 6 denotes a convex control circuit for controlling writing of the read output of the memory 1 into the data register 3.

これにより、メモリ1の読出し指示が出されたとき、読
出しデータ出力が、データ・レジスタ3の選択された一
部にセットれる。
Thereby, when a read instruction for the memory 1 is issued, the read data output is set to a selected part of the data register 3.

上記の動作を、アドレス・レジスタの内容を+1しなが
ら複数回行うと、データ・レジスタ3には、メモリlの
連続した番地のデータが揃うことになる。
If the above operation is performed multiple times while incrementing the contents of the address register by 1, the data register 3 will contain data at consecutive addresses in the memory l.

[作用] マイクロプロセッサのバスのビット幅と異なるビット数
のメモリからデータを読み出して、マイクロプロセッサ
のバス単位にデータ処理を行う場合、データはメモリl
の連続した番地に格納しておき、読み出すときは、上記
に説明したように、連続した番地から順次読み出してデ
ータ・レジスタ3の所定の位置に格納する。
[Operation] When data is read from a memory whose bit width is different from the bit width of the microprocessor bus and data processing is performed for each microprocessor bus, the data is stored in the memory l.
The data are stored in consecutive addresses, and when read out, the data are read out sequentially from consecutive addresses and stored in a predetermined position in the data register 3, as described above.

マイクロプロセッサのバスのビット幅をN1.゛メモリ
のビット数をMとすると、NとMの比、N/M=に回の
連続した番地の読出しが必要であり、データ・レジスタ
3内の格納位置の選択のためには、2x=K、で決るX
ビットが必要である。即ち、アドレスの下位Xビットを
もって、格納位置を選択制御する。
The bit width of the microprocessor bus is N1.゛If the number of bits in the memory is M, it is necessary to read consecutive addresses in the ratio of N and M, N/M=, and to select the storage location in the data register 3, 2x= K, determined by X
bit is required. That is, the storage location is selected and controlled using the lower X bits of the address.

第1図に示すような比較的簡単な回路を備えることによ
って、従来のように、マイクロプロセッサの演算用レジ
スタのシフト機能を用い、マイクロプログラム制御によ
り行うのに比べ、簡単、且つ高速にデータを読み出すこ
とができる。
By providing a relatively simple circuit as shown in Figure 1, it is possible to easily and quickly process data compared to conventional microprogram control using the shift function of a microprocessor's arithmetic register. Can be read.

第1図では、データ・レジスタ3の入力として、メモリ
lの出力とは別に、他からのデータを示しているが、こ
れはマイクロプロセッサのデータ幅と同一のデータ幅を
有する他の回路からのデータであり、この場合は、デー
タ・レジスタ3に同時にセットされる。
In Fig. 1, data from another circuit is shown as an input to the data register 3 in addition to the output of the memory l, but this data is input from another circuit having the same data width as that of the microprocessor. data, which in this case is set in data register 3 at the same time.

[実施例] 以下第2図および第3図に示す実施例により、本発明を
さらに具体的に説明する。
[Example] The present invention will be described in more detail below with reference to Examples shown in FIGS. 2 and 3.

第2図は、本発明の実施例のブロック図であって、16
ビツトのデータ幅を有するマイクロプロセッサが、4ビ
ツトのデータ幅のROMの内容を読み出し、16ビツト
のデータとして使用する例を示す。
FIG. 2 is a block diagram of an embodiment of the present invention, with 16
An example will be shown in which a microprocessor with a data width of 4 bits reads the contents of a ROM with a data width of 4 bits and uses it as 16 bit data.

第3図は、データ・レジスタの格納位置選択を説明する
図である。
FIG. 3 is a diagram illustrating selection of a storage location of a data register.

第2図において、第1図と同一の符号は同一の対象物を
示している。
In FIG. 2, the same reference numerals as in FIG. 1 indicate the same objects.

以下に、第2図および第3図を参照して、本実施例の動
作を説明する。
The operation of this embodiment will be described below with reference to FIGS. 2 and 3.

■マイクロプロセッサによって、メモリ1の、0番地か
ら3番地の内容を読み出して使用したい場合には、マイ
クロプロセッサは、最初に読み出したい番地″0”をア
ドレス・レジスタ2にセントする。
(2) When the microprocessor wants to read and use the contents of addresses 0 to 3 of memory 1, the microprocessor first writes the address "0" to be read into address register 2.

■マイクロプロセッサから読出しの指示を行うと、アド
レス・レジスタ2の下位2ビツトはデコーダ4によって
デコードされ、そのデコード出力0.1.2.3のうち
、0のみが「オン」となる、これによって、16ビツト
幅のデータ・レジスタ3を4つに分割した各4ビツト6
J[域のうちのDo部分へのデータのゲート50が開き
、クロックのゲート60が開き、書込みゲート30を制
御して、読出しデータはDo部分に書き込まれる。
■When a read instruction is issued from the microprocessor, the lower two bits of address register 2 are decoded by decoder 4, and of the decoded outputs 0.1.2.3, only 0 becomes "on". , the 16-bit wide data register 3 is divided into four parts each with 4 bits 6
The data gate 50 to the Do portion of the J[ area is opened, the clock gate 60 is opened, controlling the write gate 30, and the read data is written to the Do portion.

■アドレス・レジスタ2には、ROM ?IN域アクセ
ス後のアドレス・インクリメント機能21が備えられ、
アドレスは+1されて、アドレス・レジスタは1番地を
示す。
■Address register 2 contains ROM? Equipped with an address increment function 21 after accessing the IN area,
The address is incremented by +1 and the address register indicates address 1.

■再び読出し指示を行うと、デコーダ出力のうちlのみ
が「オン」となり、データ・レジスタ3のD1部分への
データのゲート51およびクロックのゲート61が開き
、書込みゲート31を制御して、読出しデータは、D1
部分に書き込まれる。
■When a read instruction is issued again, only l of the decoder outputs is turned on, and the data gate 51 and clock gate 61 to the D1 portion of the data register 3 are opened, and the write gate 31 is controlled to read out the data. The data is D1
written in the section.

このとき、既に格納されているDO部分のデータはその
ままである。
At this time, the data in the DO portion that has already been stored remains unchanged.

■上記の処理を繰り返し、3番地までの読出しを行うと
、0番地〜3番地のデータが読み出され、それぞれ、デ
ータ・レジスタ3のDo、 D +、 D2゜D3部分
に格納される。
(2) When the above processing is repeated and reading is performed up to address 3, the data at addresses 0 to 3 are read out and stored in the Do, D+, D2 and D3 portions of the data register 3, respectively.

■他からの、16ビツトのデータに対しては・データ・
ゲート50.51.52.53は総て開き、1つのクロ
ックによって、データ・レジスタ3のDOlDl、D2
.D3部分に同時に格納される。
■For 16-bit data from other sources, data
The gates 50, 51, 52, 53 are all open and one clock allows the data register 3 DOLDl, D2
.. They are simultaneously stored in the D3 portion.

以上の動作を行うことにより、連続した番地に記憶され
ているバス単位のデータが、データ・レジスタ3に格納
され、ただちにマイクロプロセッサにおいて使用するこ
とができる。
By performing the above operations, the data stored in consecutive addresses in units of buses is stored in the data register 3, and can be immediately used by the microprocessor.

[発明の効果] 以上説明のように本発明によれば、比較的簡単なハード
ウェアの追加により、マイクロプロセッサのレジスタ・
シフト機能を使用してマイクロプログラムによって編集
処理する従来方式に比べ、きわめて簡単に、且つ高速に
データを得ることができ、その実用上の効果は大なるも
のがある。
[Effects of the Invention] As explained above, according to the present invention, registers and registers of a microprocessor can be improved by adding relatively simple hardware.
Compared to the conventional method of editing using a microprogram using a shift function, data can be obtained extremely easily and at high speed, and its practical effects are great.

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

第1図は本発明の原理ブロック図、 第2図は本発明の実施例のブロック図、第3図はデータ
・レジスタの格納位置選択を説明する図、 第4図は従来例を説明する図である。 図面において、 lはメモリ、      2はアドレス・レジスタ、3
はデータ・レジスタ、4はデコーダ、5はデータ選択回
路、 6はクロック制御回路、21はアドレス・インク
リメンタ、 30〜33は書込みゲート、 50〜53はデータ・ゲート、 60〜63はANDゲート、 DO,D+、D2.D3はデータ・レジスタの部分をそ
れぞれ示す。 蕃3図 革4吋
FIG. 1 is a block diagram of the principle of the present invention, FIG. 2 is a block diagram of an embodiment of the present invention, FIG. 3 is a diagram illustrating selection of a storage position of a data register, and FIG. 4 is a diagram illustrating a conventional example. It is. In the drawing, l is memory, 2 is address register, 3
is a data register, 4 is a decoder, 5 is a data selection circuit, 6 is a clock control circuit, 21 is an address incrementer, 30 to 33 are write gates, 50 to 53 are data gates, 60 to 63 are AND gates, DO, D+, D2. D3 each indicates a data register portion. 3 bucks leather 4 inches

Claims (1)

【特許請求の範囲】 プロセッサのバスのビット数と異なるビット数の構成を
持つメモリ(1)の読出しにおいて、プロセッサのバス
のビット数と同一のビット数を持ち、前記メモリ(1)
からの読出しデータを格納するデータ・レジスタ(3)
と、 アドレス・レジスタ(2)に保持されたアドレスの下位
ビットの一部をデコードするデコーダ(4)と、 前記デコーダ(4)のデコード出力によって、前記メモ
リ(1)読出しデータの、前記データ・レジスタ(3)
への格納位置を選択するデータ選択回路(5)と、 前記デコーダ(4)のデコード出力によって、前記メモ
リ(1)読出しデータの、前記データ・レジスタ(3)
への格納を制御するクロック制御回路(6)とを備え、 前記メモリ(1)の連続したアドレスの読出しにより、
前記データ・レジスタ(3)に、前記連続したアドレス
の読出しデータを並べて格納するよう構成したことを特
徴とするメモリ・アクセス方式。
[Scope of Claims] When reading a memory (1) having a configuration of a bit number different from the bit number of a bus of a processor, the memory (1) has a configuration of a bit number that is the same as the number of bits of a bus of a processor;
Data register (3) that stores read data from
a decoder (4) that decodes a part of the lower bits of the address held in the address register (2); and a decode output of the decoder (4) to read out the data from the memory (1). Register (3)
a data selection circuit (5) that selects a storage location in the data register (3) of the read data in the memory (1) by the decoded output of the decoder (4);
a clock control circuit (6) for controlling storage in the memory (1); and by reading consecutive addresses of the memory (1),
A memory access method characterized in that the data register (3) is configured to store read data of the consecutive addresses side by side.
JP16348185A 1985-07-24 1985-07-24 Memory access system Pending JPS6224338A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP16348185A JPS6224338A (en) 1985-07-24 1985-07-24 Memory access system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP16348185A JPS6224338A (en) 1985-07-24 1985-07-24 Memory access system

Publications (1)

Publication Number Publication Date
JPS6224338A true JPS6224338A (en) 1987-02-02

Family

ID=15774692

Family Applications (1)

Application Number Title Priority Date Filing Date
JP16348185A Pending JPS6224338A (en) 1985-07-24 1985-07-24 Memory access system

Country Status (1)

Country Link
JP (1) JPS6224338A (en)

Similar Documents

Publication Publication Date Title
JPH0248931B2 (en)
JPH0346850B2 (en)
US4812970A (en) Microprogram control system
JPS6041769B2 (en) Addressing method
JPH08212075A (en) Information processor
US5001629A (en) Central processing unit with improved stack register operation
US5151993A (en) Data processor performing operation on data having length shorter than one-word length
JPS6224338A (en) Memory access system
JPH02126321A (en) Decoder for instruction code
JPS6223891B2 (en)
JPS6112579B2 (en)
JPS6320631A (en) Register selecting system
JP2819753B2 (en) Pipeline microprocessor
JPH01263819A (en) Integrated circuit
JPS61161560A (en) Memory device
JPH0546389A (en) Parallel processor
JPH0259495B2 (en)
JPH03113659A (en) Cache memory testing method
JPS60209837A (en) Microprogram controller
JPS6057604B2 (en) Register selection control method
JPH0232434A (en) Memory access device
JPS6158043A (en) Register address converter circuit
JPH0460259B2 (en)
JPS63317857A (en) Memory access circuit
JPS6091474A (en) Exclusive control system for plural processors