Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
JPS6041767B2 - Instruction execution method - Google Patents
[go: Go Back, main page]

JPS6041767B2 - Instruction execution method - Google Patents

Instruction execution method

Info

Publication number
JPS6041767B2
JPS6041767B2 JP7281378A JP7281378A JPS6041767B2 JP S6041767 B2 JPS6041767 B2 JP S6041767B2 JP 7281378 A JP7281378 A JP 7281378A JP 7281378 A JP7281378 A JP 7281378A JP S6041767 B2 JPS6041767 B2 JP S6041767B2
Authority
JP
Japan
Prior art keywords
instruction
bus
cpu
specific
signal
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.)
Expired
Application number
JP7281378A
Other languages
Japanese (ja)
Other versions
JPS54163641A (en
Inventor
和夫 足立
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.)
Panasonic Holdings Corp
Original Assignee
Matsushita Electric Industrial Co 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 Matsushita Electric Industrial Co Ltd filed Critical Matsushita Electric Industrial Co Ltd
Priority to JP7281378A priority Critical patent/JPS6041767B2/en
Publication of JPS54163641A publication Critical patent/JPS54163641A/en
Publication of JPS6041767B2 publication Critical patent/JPS6041767B2/en
Expired legal-status Critical Current

Links

Landscapes

  • Executing Machine-Instructions (AREA)

Description

【発明の詳細な説明】 本発明はマイクロプロセサシステムの命令実行方式に
関するものである。
DETAILED DESCRIPTION OF THE INVENTION The present invention relates to an instruction execution method for a microprocessor system.

一般に、マイクロプロセサシステムの開発においては
、LSI技術の向上により、メモリ、cpuなどハード
ウェアの集積化、低価格化が進み、開発費に占めるメン
テナンスを含めたソフトウェア費用の割合が増大してい
る。
Generally, in the development of microprocessor systems, improvements in LSI technology have led to greater integration and lower prices of hardware such as memory and CPUs, and the proportion of software costs including maintenance in development costs has increased.

このような背景から、プログラム構成の簡略化、あるい
は、限られたC凹機能、メモリ容量でより高度の機能を
持たせる必要がある。この場合、プロセサの構成、命令
実行方式などは、メーカのプロセス設計時に決まつてし
まつており、ユーザ側て変更することはほとんど不可能
てあつた。第1図は従来方式のブロック図であり、Cp
ulはアドレスバス7を介してプログラムメモリ2と接
続し、プログラムメモリ2の信号はインストラクション
バス8を介してcpulに接続される。9はI/0ポー
トである。
Against this background, it is necessary to simplify the program configuration or provide more advanced functions with limited C-shaped functions and memory capacity. In this case, the configuration of the processor, the instruction execution method, etc. have been determined at the time of process design by the manufacturer, and it is almost impossible for the user to change them. Figure 1 is a block diagram of the conventional method, and Cp
ul is connected to the program memory 2 via an address bus 7, and the signals of the program memory 2 are connected to cpul via an instruction bus 8. 9 is an I/0 port.

ここではメモリ2から出力されたインストラクション(
iNST)がそのままインストラクションバス8を通し
てCpulに取り込まれ、その命令が実行されている。
本発明はかかる不都合をなくし、ユーザ側で命令実行
方式に追加機能を付加し、プログラムの簡略化、見やす
さを改善しつつ、プログラム容量の減少をはかることを
目的としている。
Here, the instructions output from memory 2 (
iNST) is directly taken into Cpul through the instruction bus 8, and its instructions are executed.
The present invention aims to eliminate such inconveniences, add additional functions to the instruction execution method on the user side, simplify the program, improve visibility, and reduce the program capacity.

本発明の一実施例である第2図とともに説明する。 This will be explained with reference to FIG. 2, which is an embodiment of the present invention.

なお、ここでは、特定命令としてLAi命令(アキュム
レータに、命令のオペランド部で示された直接数値をロ
ードする)を想定し、その命令フォーマットを第4図に
示す。第2図において1はcp男 2はプログラムメモ
リ、3はインストラクション切替部であり、cpulで
実行すべき命令をプログラムメモリの内容とするか、命
令レジスタ6の内容とするかを選択する。4はインスト
ラクションバス8の上位4ビット (命令コード)12
を保持するラッチ回路で、cpuからのセットパルス1
6でセットされる。
It is assumed here that the specific instruction is an LAi instruction (loads the accumulator with a direct numerical value indicated in the operand section of the instruction), and the format of the instruction is shown in FIG. In FIG. 2, 1 is a cp man, 2 is a program memory, and 3 is an instruction switching unit, which selects whether the contents of the program memory or the contents of the instruction register 6 are to be used as instructions to be executed by the cpul. 4 is the upper 4 bits of instruction bus 8 (instruction code) 12
A latch circuit that holds the set pulse 1 from the CPU.
It is set at 6.

5はインストラクション切替信号を作るD−フリップフ
ロップ、6はNOP命令(ノーオペレーシヨン)をセッ
トしておく命令セットレジスタ、7はアドレスバス、8
はインストラクションバス、9はI/0ポート、10は
インバータ、11はANDゲート、12はインストラク
ションバス8の上位4ビット (命令コード)、13は
cpulの1命令に1パルス出力されるcpu同期クロ
ック、14は特定命令(LAi命令)検出信号であり、
LAi命令コード(4)110)がラッチ回路4にセッ
トされた時に、ゲート10,11により0Nとなり、D
−フリップフロップ5のD入力とクリア入力に接続され
ている。
5 is a D-flip-flop that generates an instruction switching signal; 6 is an instruction set register that sets a NOP instruction (no operation); 7 is an address bus; 8
is an instruction bus, 9 is an I/0 port, 10 is an inverter, 11 is an AND gate, 12 is the upper 4 bits of instruction bus 8 (instruction code), 13 is a CPU synchronization clock that outputs one pulse for each CPU instruction, 14 is a specific instruction (LAi instruction) detection signal;
When the LAi instruction code (4) 110) is set in the latch circuit 4, the gates 10 and 11 turn 0N, and the D
- connected to the D input and clear input of flip-flop 5;

15はCpuクロック13と特定命令検出信号14によ
り作られるインストラクシヨン切替信号で、その様子は
、第3図のタイミングチャートで示す。
Reference numeral 15 denotes an instruction switching signal generated by the CPU clock 13 and the specific instruction detection signal 14, the state of which is shown in the timing chart of FIG.

16はインストラクシヨンバスに正しいインストラクシ
ヨンが出力されている時に、インストラクシヨンバスの
上位4ビット(命令コード)をラッチ回路4にセットさ
せるためのラッチセット信号である。
Reference numeral 16 is a latch set signal for causing the latch circuit 4 to set the upper 4 bits (instruction code) of the instruction bus when a correct instruction is being output to the instruction bus.

以下に本発明の動作を第2図および第3図に従つて説明
する。
The operation of the present invention will be explained below with reference to FIGS. 2 and 3.

通常のCpuのRLlN状態では、前記したように、メ
モリ2から出力されたインストラクシヨン(INST)
が、そのままインストラクシヨンバス8を通して、Cp
ulに取り込まれ、その命令が実行されている。ここで
、第3図aのようなLAi命令が2つ連続してあるよう
なプログラムを実行する場合、まず1NST1(LAi
/1)が、インストラクシヨンバス8に出力され、ラッ
チセット信号16により、ラッチ回路4にLAi命令コ
ード(イ)110)がセットされると、特定命令検知と
判断し、信号14は間Nとなる。但し、この時は、まだ
信号15は闇FFのままなのでインストラクシヨン切替
部3により、プログラムメモリの内容が選択され、IN
STlは実行される。次に、INST2(LAi/4)
がインストラクシヨンバスに出力され、ラッチセット信
号16により、ラッチ回路4にLAi命令コード(イ)
110)がセットされると、特定命令検知と判断し、信
号14は、さらに閘N状態を保つ。しかし、この時は切
替信号15がCpuクロック131(第3図b)で、既
に0Nとなつているので、インストラクシヨン切替部3
により、命令セットレジスタの内容(NOP命令)が選
択され、それがCpuに取り込まれ、INST2は実行
されない。次に、INST3(ADD)が、インストラ
クシヨンバスに出力され、ラッチセット信号16により
、ラッチ回路4にADD命令コードがセットされると、
特定命令不検知と判断し、信号14は0FFとなり、D
−フリップフロップはクリアされ、切替信号15は、0
FFとなり、インストラクシヨン切替部3によりプログ
ラムメモリの内容が選択され、CpuへはINST3が
取込まれ実行される。なお、ジャンプ命令などにより、
プログラムの他のルーチンから、直接1NST2に実行
が移つてきた場合は、第3図CのようにINST2(L
Ai/4)の命令コード(イ)110)がラッチ回路4
にセットされると、特定検出信号14が0Nとなり、(
この時はまだ、切替信号15は0FF状態なのでINS
T2は実行される。
In the normal CPU RLIN state, as mentioned above, the instruction (INST) output from memory 2
However, through instruction bus 8, Cp
ul and the instruction is being executed. Here, when executing a program with two consecutive LAi instructions as shown in Figure 3a, first 1NST1 (LAi
/1) is output to the instruction bus 8, and when the LAi instruction code (a) 110) is set in the latch circuit 4 by the latch set signal 16, it is determined that a specific command has been detected, and the signal 14 is becomes. However, at this time, the signal 15 is still in the dark FF state, so the instruction switching unit 3 selects the contents of the program memory, and the IN
STl is executed. Next, INST2 (LAi/4)
is output to the instruction bus, and the latch circuit 4 receives the LAi instruction code (A) by the latch set signal 16.
110) is set, it is determined that a specific command has been detected, and the signal 14 further maintains the locked N state. However, at this time, the switching signal 15 is the CPU clock 131 (FIG. 3b) and is already 0N, so the instruction switching section 3
As a result, the contents of the instruction set register (NOP instruction) are selected and taken into the CPU, and INST2 is not executed. Next, INST3 (ADD) is output to the instruction bus, and when the latch set signal 16 sets the ADD instruction code in the latch circuit 4,
It is determined that a specific command is not detected, signal 14 becomes 0FF, and D
- the flip-flop is cleared and the switching signal 15 is 0
The instruction switching unit 3 selects the contents of the program memory, and INST3 is loaded into the CPU and executed. In addition, due to jump commands etc.
If execution moves directly to 1NST2 from another routine in the program, INST2 (L
Ai/4) instruction code (a) 110) is latch circuit 4
When set to , the specific detection signal 14 becomes 0N, and (
At this time, the switching signal 15 is still in the 0FF state, so the INS
T2 is executed.

)次のCpuクロック132で切替信号15が、0Nと
なるが、次のINST3(ADD)の命令コードがラッ
チ回路4にセットされると、特定命令検出信号14が0
FFとなり、同時にD−フリップフロップ5がクリアさ
れ、切替信号15が再び0FFとなるため、Cpuの命
令取込時は、切替部3はプログラムメモリ側に切り替つ
ているため、INST3(ADD)が取り込まれ、実行
される。なお命令コードは、ラッチセット信号16の0
N期間にセットされ、またCpuは、ラッチセット信号
16の立ち下がりで命令を取り込む。以上述べたように
、本発明により既製のプロセサの機能に制限されること
なく、各々のアプリケーションに応じて、特定命令を決
めることにより、システムの機能アップを図ることが可
能である。
) The switching signal 15 becomes 0N at the next CPU clock 132, but when the next instruction code of INST3 (ADD) is set in the latch circuit 4, the specific instruction detection signal 14 becomes 0N.
At the same time, the D-flip-flop 5 is cleared and the switching signal 15 becomes 0FF again, so when the CPU instruction is fetched, the switching unit 3 is switched to the program memory side, so INST3 (ADD) is fetched. and executed. Note that the instruction code is 0 of the latch set signal 16.
It is set for the N period, and the CPU takes in the command at the falling edge of the latch set signal 16. As described above, according to the present invention, it is possible to improve the functionality of the system by determining specific instructions according to each application without being limited to the functionality of an off-the-shelf processor.

具体的に云えば、上述のようにLAj命令を特定命令に
指定することにより、第5図の例に示したようにプログ
ラム容量が、半減し、また見やすいプログラム構成とな
る。これにより、全体のプログラム容量の削減が、図れ
るとともに、また同一容量で、より多くの処理が行なえ
る。さらにデ・バッグ、仕様変更も含めたソフトウェア
開発の効率化が実現できる。
Specifically, by specifying the LAj instruction as a specific instruction as described above, the program capacity is halved and the program structure becomes easier to read, as shown in the example of FIG. As a result, the overall program capacity can be reduced, and more processing can be performed with the same capacity. Furthermore, software development, including debugging and specification changes, can be made more efficient.

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

第1図はマイクロプロセサシステムの従来例を示すブロ
ック図、第2図は本発明の一実施例を示・すブロック図
、第3図はタイミングチャート、第4図はLAi命令の
命令フォーマット、第5図はプログラムを示す。 1・・・・・・CpUl2・・・・・・プログラムメモ
リ、3・・・インストラクシヨン切替部、4・・・・・
命令コードの)ラッチ回路、5・・・・・・D−フリッ
プフロップ、6・・・・・・命令セットレジスタ、7・
・・・・アドレスバス、8・・・・インストラクシヨン
バス、9・・・・I/0ボート、10・・・・・・イン
バータ、11・・・・・・.ANDゲート、12・・・
・・・インストラクシヨンバスの上位4ビツト (命令
コード)、13・・・・・・CpUクロック、14・・
・・・・特定命令検出信号、15・・・・・・インスト
ラクシヨン切替信号、16・・・・・ラッチ回路へのセ
ット信号。
Fig. 1 is a block diagram showing a conventional example of a microprocessor system, Fig. 2 is a block diagram showing an embodiment of the present invention, Fig. 3 is a timing chart, and Fig. 4 shows the instruction format of the LAi instruction. Figure 5 shows the program. 1...CpUl2...Program memory, 3...Instruction switching unit, 4...
(instruction code) latch circuit, 5...D-flip-flop, 6...instruction set register, 7.
... Address bus, 8 ... Instruction bus, 9 ... I/0 boat, 10 ... Inverter, 11 ...... AND gate, 12...
... Upper 4 bits of instruction bus (instruction code), 13...CpU clock, 14...
... Specific instruction detection signal, 15 ... Instruction switching signal, 16 ... Set signal to latch circuit.

Claims (1)

【特許請求の範囲】[Claims] 1 cpuと別個に外部にプログラムメモリを有し、前
記cpuとメモリの間を、アドレスバスとインストラク
ションバスで接続したマイクロプロセサシステムにおい
て、インストラクションバス上の命令コードをラッチす
るラッチ回路と、前記命令コードが特定命令コードかど
うかを判定する判定回路と、前記判定信号とcpuクロ
ックにより特定命令をインストラクションバス上で禁止
する禁止信号を作る回路を具備し、前記特定命令が連続
する場合、最初の特定命令だけ実行し、以下に連続する
同一命令は無効とする命令実行方式。
1. In a microprocessor system having an external program memory separate from a CPU, and in which the CPU and memory are connected by an address bus and an instruction bus, a latch circuit that latches an instruction code on an instruction bus, and the instruction code is a specific instruction code; and a circuit that generates a prohibition signal for prohibiting a specific instruction on an instruction bus based on the determination signal and a CPU clock, and when the specific instructions are consecutive, the first specific instruction An instruction execution method that executes only one instruction, and disables subsequent identical instructions.
JP7281378A 1978-06-15 1978-06-15 Instruction execution method Expired JPS6041767B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP7281378A JPS6041767B2 (en) 1978-06-15 1978-06-15 Instruction execution method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP7281378A JPS6041767B2 (en) 1978-06-15 1978-06-15 Instruction execution method

Publications (2)

Publication Number Publication Date
JPS54163641A JPS54163641A (en) 1979-12-26
JPS6041767B2 true JPS6041767B2 (en) 1985-09-18

Family

ID=13500214

Family Applications (1)

Application Number Title Priority Date Filing Date
JP7281378A Expired JPS6041767B2 (en) 1978-06-15 1978-06-15 Instruction execution method

Country Status (1)

Country Link
JP (1) JPS6041767B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS56153447A (en) * 1980-04-30 1981-11-27 Nec Corp Microprogram control device
JPS6032207B2 (en) * 1980-08-14 1985-07-26 株式会社東芝 Branch control circuit

Also Published As

Publication number Publication date
JPS54163641A (en) 1979-12-26

Similar Documents

Publication Publication Date Title
US4979102A (en) Microprocessor operable under direct connection to coprocessor
EP0313097B1 (en) Microcomputer system including master processor and slave processor
US4961161A (en) Arithmetic processor performing mask and trap operations for exceptions
US6205414B1 (en) Methodology for emulation of multi-threaded processes in a single-threaded operating system
US5163143A (en) Enhanced locked bus cycle control in a cache memory computer system
JPS61204758A (en) Co-processor control method
JPS6041767B2 (en) Instruction execution method
US4991130A (en) Normalization control system for floating point arithmetic operation
EP0417587B1 (en) Data processor having function of checking undefined addressing prescribed for each of instructions of variable length
JP2754594B2 (en) Single chip microcomputer
KR930008044B1 (en) Bus Matching Circuit in Multiprocessor System
JP2721611B2 (en) Programmable controller
JP2968060B2 (en) Microprocessor
JP2559929B2 (en) Programmable controller
JP3425888B2 (en) Power saving circuit
JPS63153634A (en) Data processor
SU1156071A1 (en) Microprogram control device
JP2806700B2 (en) Multi-processing system
JPH04162150A (en) Watchdog timer control circuit
JPH05242008A (en) Data processor
JPH04127244A (en) Microcomputer
JPH071500B2 (en) Single chip microcomputer
JPS6175436A (en) Microprogram controller
JPH0690733B2 (en) Microcomputer
JPH05189014A (en) Programmable controller