JPH04165532A - Method and device for controlling program sequence - Google Patents
Method and device for controlling program sequenceInfo
- Publication number
- JPH04165532A JPH04165532A JP2293413A JP29341390A JPH04165532A JP H04165532 A JPH04165532 A JP H04165532A JP 2293413 A JP2293413 A JP 2293413A JP 29341390 A JP29341390 A JP 29341390A JP H04165532 A JPH04165532 A JP H04165532A
- Authority
- JP
- Japan
- Prior art keywords
- point
- bug
- cpu
- program
- hook number
- 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
Links
- 238000000034 method Methods 0.000 title claims description 12
- 238000012795 verification Methods 0.000 claims description 8
- 238000012545 processing Methods 0.000 abstract description 15
- 230000000694 effects Effects 0.000 description 4
- 238000010586 diagram Methods 0.000 description 2
- 201000004384 Alopecia Diseases 0.000 description 1
- 241000238366 Cephalopoda Species 0.000 description 1
- 239000013256 coordination polymer Substances 0.000 description 1
- 230000007423 decrease Effects 0.000 description 1
- 230000003247 decreasing effect Effects 0.000 description 1
- 230000007547 defect Effects 0.000 description 1
- 239000006185 dispersion Substances 0.000 description 1
- 230000003676 hair loss Effects 0.000 description 1
- 238000007689 inspection Methods 0.000 description 1
- 238000011900 installation process Methods 0.000 description 1
- 230000009191 jumping Effects 0.000 description 1
- 238000012360 testing method Methods 0.000 description 1
Landscapes
- Debugging And Monitoring (AREA)
- Stored Programmes (AREA)
- Executing Machine-Instructions (AREA)
Abstract
Description
【発明の詳細な説明】
[産業上の利用分野コ
本発明は、マスクROM等に格納されたプログラムのバ
グを回避するためのプログラムンーケンス制御方法およ
び装置に関する。DETAILED DESCRIPTION OF THE INVENTION [Field of Industrial Application] The present invention relates to a program sequence control method and apparatus for avoiding bugs in programs stored in a mask ROM or the like.
[従来の技術]
プログラムを焼き付けたマスクROMをコンピュータ機
器に組込んで出荷した後、使用段階でそのプログラムに
予期しなかった欠陥(バグ)か見つかることかある。こ
のようなバグか見つかる度にマスクROMを改版するの
もコストかかかることから、第4図に示すように、マス
クROMに書き込むプログラムに予め複数のポイ:/ト
HO,H1、・・・・を所定の間隔をおいて設定し、使
用段階で検出されたバグb go、b g3.・・・・
に対しては、その手前のポイントHO,H3,・・・・
でRAMに格納しである差替用の部分プログラムPO“
、P3′にジャンプさせて、それらバグb g(1,b
g3.・・・・の実行を回避するようにしている。[Prior Art] After a mask ROM in which a program has been burned is installed in computer equipment and shipped, an unexpected defect (bug) may be found in the program during use. Since it is costly to revise the mask ROM every time such a bug is found, as shown in Figure 4, multiple points are added to the program written to the mask ROM in advance: HO, H1, . . . are set at predetermined intervals, and the bugs b go, b g3. detected during the use stage are set at predetermined intervals.・・・・・・
For, the points in front of it HO, H3,...
The partial program PO for replacement is stored in RAM in
, P3′, and those bugs b g(1, b
g3. I am trying to avoid the execution of...
これらの部分プログラムPO’、 P3’は、各々の
バグb go、b g3.・・・・か発見される度毎に
それをデバグして部分的に再作成したプログラムで、/
ステムの起動時にフロッピディスク等の記憶媒体よりR
AMにロードされる。These partial programs PO', P3' contain bugs b go, b g3 . Each time something was discovered, I debugged it and partially re-created the program, /
R from a storage medium such as a floppy disk when starting the system.
Loaded into AM.
このヨウにマスクROMのプログラムを実行している途
中でそのバグ部分をRAMのデハグした部分プログラム
に差し替えるため、従来は、次のような処理を行ってい
た。すなわち、使用段階でバグが見つかる度に、それを
デバグした部分プログラムを作成し、第5図に示すよう
なテーブルにそのバグの手前のポイントを識別するデー
タ(フックナンバ)hlとそのハゲに対応する部分プロ
グラムPi゛の(RAM上の)アドレスm1を逐次リス
トしておく。そして、第6図に示すように、CPUは当
該ROMプログラムに予め設定されている各ポイントH
+(例えば命令C)に達すると、そこでコール命令を実
行してバグ−チエツク会すブルーチンにジャンプし、そ
こで当該ポイントH1のフックナンバhlがバグ番テー
ブル(第5図)にリストされているとうかを調へる。こ
の検査のため、ポイントHiの直前の命令BでCPUレ
ノスタにポイントHiのフックナンバhiを8き込んで
おく。この検査の結果、フックナンバh1がバグやテー
ブルにリストされているときは、RAMの対応する差替
用の部分プログラムPi“にジャンプしてその部分プロ
グラムPi゛を実行した後i: ROM フログラムの
被差替部分P1の次のアドレス(命令K)に戻る。その
フックナンバh1かバグ・テーブルにリストされていな
いときは、差替用の部分プログラムにジャンプすること
なく、バグ・チエツク・サブルーチンの終了後にポイン
トH1の次のROMアドレス(命令D)にリター7する
。In order to replace the buggy part with a dehugged partial program in the RAM while the program in the mask ROM is being executed, conventionally, the following process has been performed. In other words, every time a bug is found during use, a partial program is created to debug it, and data (hook number) hl that identifies the point before the bug is written in a table like the one shown in Figure 5, along with the corresponding baldness. The addresses m1 (on RAM) of the partial program Pi' to be executed are sequentially listed. Then, as shown in FIG.
+ (for example, instruction C), it executes the call instruction and jumps to a bug-checking buroutine, where the hook number hl of the point H1 is listed in the bug number table (Figure 5). Check out the squid. For this inspection, the hook number hi of point Hi is written to the CPU reno star by instruction B immediately before point Hi. As a result of this check, if the hook number h1 is listed in the bug or table, jump to the corresponding replacement partial program Pi'' in RAM, execute that partial program Pi'', and then execute i: in the ROM program. Returns to the next address (instruction K) of the replaced part P1.If the hook number h1 is not listed in the bug table, execute the bug check subroutine without jumping to the replacement part program. After completion, return 7 to the next ROM address (instruction D) at point H1.
[発明か解決しようとする課題]
上記のように、従来のプログラム・/−ケノス制御方式
では、ROMプログラム内に予め設定した全てのポイン
)HO,Hl、・・・で常にバグ・チエ。[Problem to be Solved by the Invention] As described above, in the conventional program/kenos control system, bug checks are always performed at all points (HO, Hl, . . . ) set in advance in the ROM program.
り・サブルーチンにジャンプし、そこで当該ポイントの
フックナンバh1をバグ・テーブル(第5図)にリスト
されているフックナンバhO,h3.■の1つ1つと逐
次比較し、一致するものがあるがとうか調べ、その検査
結果にしたがって条件的にRAMの部分プログラムに差
し替えていた。jumps to the subroutine, where it sets the hook number h1 of the point in question to the hook numbers hO, h3 . I compared each one one by one to see if there was a match, and then conditionally replaced the partial program in RAM according to the test results.
しかしながら、バグの発生していないポイントH1,H
2,・・・・でもそのようなバグ・チエ、り働サブルー
チンを実行するのでは、cPUが付随的な処理(本来の
処理以外の処理)に多くの時間を費やす結果となり、処
理速度ないしスループットの低下を招いていた。特に、
ループ処理を多数回繰り返す場合においてそのループの
中にポイントが入っていると、ループが回る度にバグ−
チエ、り−サブルーチンを実行するため、処理速度か著
しく低下した。However, points H1 and H where no bug has occurred
2. However, if such a bug/check/work subroutine is executed, the CPU will spend a lot of time on incidental processing (processing other than the original processing), which will reduce the processing speed or throughput. was causing a decline in especially,
If a loop process is repeated many times and a point is inside the loop, a bug will occur each time the loop runs.
Processing speed decreased significantly due to execution of subroutines.
本発明は、かかる問題点に鑑みてなされたもので、RO
Mプログラムに予め設定した各ポイントでのバグ・チエ
ツクに要する時間を最小限にしてCPUの処理速度を向
上するようにしたプログラムシーケンス制御方法及び装
置を提供することを目的とする。The present invention was made in view of such problems, and the RO
It is an object of the present invention to provide a program sequence control method and apparatus that improves the processing speed of a CPU by minimizing the time required for bug checking at each preset point in an M program.
[課題を解決するための手段]
上記の目的を達成するため、本発明のプログラムシーケ
ンス制御方法は、各バグの手前に位置するポイントを識
別するデータを保持するレジスタ手段と、各ポイントで
CPUの発生するそのポイントを識別するデータとレジ
スタ手段に保持されているポイント識別データとを照合
する手段と、この照合手段の照合結果にしたかって選択
的にCPUに対して差替用の部分プログラムを実行させ
るための割込信号を発生する手段とを具備する構成とし
た。[Means for Solving the Problems] In order to achieve the above object, the program sequence control method of the present invention includes a register means for holding data identifying a point located before each bug, and a CPU control method at each point. A means for collating data identifying the generated point with point identification data held in the register means, and selectively executing a partial program for replacement on the CPU based on the collation result of the collation means. The configuration also includes means for generating an interrupt signal to cause an interruption.
また、本発明のプログラムシーケンス制御方法は、バグ
の手前に位置するポイントを識別するデータを予め第1
のレジスタ手段に保持しておき、各ポイントにてそのポ
イントを識別するデータをCPUに書込サイクルで発生
させて第2のレジスタ手段に書き込み、この第2のレジ
スタ手段に書き込まれたポイント識別データと第1のレ
ジスタ手段に保持されているポイント識別データとを照
合し、書込サイクルの直後に続出サイクルで照合の結果
をCPUに読み込ませ、照合一致の結果か得られたとき
はCPUに割込処理として差替用の部分プログラムを実
行させることとした。In addition, the program sequence control method of the present invention is characterized in that the data identifying the point located before the bug is first stored in advance.
The CPU generates data for identifying the point at each point in a write cycle and writes it to the second register means, and the point identification data written to the second register means is stored in the register means. and the point identification data held in the first register means, and the result of the verification is read into the CPU in successive cycles immediately after the write cycle, and when a matching result is obtained, the CPU is We decided to run a replacement partial program as part of the installation process.
[作用]
使用段階でバグが発見されたなら、そのバグの手前のポ
イントの識別データ(フックナンバ)かレジスタ手段に
書き込まれ保持される。また、このポイント識別データ
は、従来通り、バグ・テーブルにリストされる。[Operation] If a bug is discovered during use, the identification data (hook number) of the point before the bug is written to the register means and held. This point identification data is also conventionally listed in the bug table.
CPUは、ンステムプログラム(ROMプログラム)の
実行において、各ポイントに達すると、そのポイントの
識別データを出力する。照合手段は、このCPUからの
ポイント識別データをし7スタ手段に保持されているポ
イント識別データと照合する。当該ポイントがバグ・テ
ーブルにリストされているものならば、すなわち当該ポ
イントと次のポイントとの間にバグがあるならば、その
ポイント識別データはレジスタ手段に登録(保持)され
ているはすであるから、照合手段より照合一致の照合結
果か得られ、この場合はバグ・テーブルにしたかって差
替用の部分プログラムか実行される。また、当該ポイン
トがバグ・テーブルにリストされていなければ、すなわ
ち当該ポイントと次のポイントとの間にバグがないなら
ば、そのポイント識別データはレジスタ手段に登録(保
持)されてはいないので、閑合不一致の照合結果か得ら
れ、この場合は本プログラム内で次の命令に入る。When the CPU reaches each point in the execution of the system program (ROM program), it outputs identification data for that point. The collation means collates the point identification data from the CPU with the point identification data held in the 7 star means. If the point in question is listed in the bug table, that is, if there is a bug between the point in question and the next point, the point identification data is already registered (held) in the register means. Therefore, a matching result is obtained from the matching means, and in this case, a partial program for replacement is executed in order to use it as a bug table. Furthermore, if the point is not listed in the bug table, that is, if there is no bug between the point and the next point, the point identification data is not registered (held) in the register means. A match/mismatch matching result is obtained, in which case the next command is entered in this program.
本発明による照合は、当該ポイント識別データと各登録
ポイント識別データとの比較を並列的・同時的に行うこ
とによって、瞬時に実行される。Verification according to the present invention is instantaneously executed by comparing the point identification data with each registered point identification data in parallel and simultaneously.
従来のようなバグ・チエツク・サブルーチンをソフトウ
ェア的に実行するのと比べて、格段に短い時間で済む。Compared to executing a conventional bug check subroutine in software, it takes much less time.
したがって、本発明によれば、バグのないポイントでは
実質的に寄り道せずに本プログラムの実行を進めること
ができ、バグのあるポイントでは必要最小限の時間でR
AMの部分プログラムに差し替えることかできる。Therefore, according to the present invention, it is possible to proceed with the execution of the program at points where there are no bugs without making any detours, and at points where there are bugs, it is possible to proceed with the execution of the program in the minimum necessary time.
It is possible to replace it with a partial program of AM.
また、CPUの動作として、各ポイントにおけるポイン
ト識別データの出力を書込サイクルで第1のレジスタ手
段に古き込んで、照合手段に上記のような照合を行わせ
、次に読出サイクルを実行し、そのサイクル゛で照合手
段の照合結果を割込の形で読み取るようにすると、命令
キューのあるCPUでも条件的な割込処理に切り替わる
ことができる。Further, as an operation of the CPU, the output of point identification data at each point is stored in the first register means in a write cycle, the collation means is made to perform the above collation, and then a read cycle is executed. If the verification result of the verification means is read in the form of an interrupt in that cycle, even a CPU with an instruction queue can switch to conditional interrupt processing.
[実施例]
以下、第1図ないし第3図を参照して本発明の一実施例
を説明する。[Embodiment] An embodiment of the present invention will be described below with reference to FIGS. 1 to 3.
先ず、第2図に示すように、この実施例によるプログラ
ム・シーケンス制御装置18は、データ・バス12.読
出e書込制御線141割迷信号線16を介してシステム
のCPU (中央処理装置)10に接続される。First, as shown in FIG. 2, program sequence controller 18 according to this embodiment has data bus 12 . A read/write control line 141 is connected to a CPU (central processing unit) 10 of the system via a stray signal line 16.
第1図は制御装置10の内部構成を示す。CPU18(
図示せず)からのデータ・バス12は、レジスタ20の
入力端子に接続されるとともに、N個のフックナンバ畳
レジスタRG1.・・・・、RGNの入力端子に接続さ
れる。そして、レジスタ20の出力端子は比較回路CP
I、・・・・、CPNの一方の入力端子に接続され、フ
ックナンバ・レジスタRGl、・・・・、RGNの出力
端子は比較回路cpt、・・・・。FIG. 1 shows the internal configuration of the control device 10. As shown in FIG. CPU18 (
(not shown) is connected to the input terminals of registers 20, and N hook number registers RG1. . . . is connected to the input terminal of RGN. The output terminal of the register 20 is the comparator circuit CP.
I, . . . are connected to one input terminal of CPN, and the output terminals of the hook number registers RGl, .
CPNの他方の入力端子にそれぞれ接続され、比較器c
pt、・・・・、CPNの出力端子は割込要求出力回路
22の入力端子に接続される。are respectively connected to the other input terminals of the CPN, and the comparator c
The output terminals of pt, . . . , CPN are connected to the input terminal of the interrupt request output circuit 22.
制御線に関して、CPU18からの書込制御線L4bは
レジスタ20の書込制御端子WRに接続され、続出制御
線14aは割込要求出力回路22の出力制御端子σ1−
に接続される。また、フックナンバ・レジスタRGL・
・・・、RGNの書込側@端子WRにはアドレス0デコ
ーダからの書込制御線AL+、・・・・、ALnか接続
される。Regarding the control lines, the write control line L4b from the CPU 18 is connected to the write control terminal WR of the register 20, and the continuous control line 14a is connected to the output control terminal σ1- of the interrupt request output circuit 22.
connected to. In addition, hook number register RGL
. . , the write control lines AL+, . . . , ALn from the address 0 decoder are connected to the write side @ terminal WR of RGN.
本システムのROM (図示せず)に格納されているプ
ログラムには、従来と同様に、予め複数のポイントか所
定の間隔をおいて設定される。そして、使用段階でバグ
が見つかる度に、それをデバグした部分プログラムを作
成し、第5図に示すようなバグ・テーブルにそのバグの
手前のポイントを識別するデータ(フックナンバ)hI
とそのバグに対応する部分プログラムPi゛の(RAM
上の)アドレスmiを逐次リストしてお(。たたし、従
来と異なり、バグ・チエツク・サブルーチンを備えない
。代わりに、バグの手前のポイントのフックナンバhi
をバグの発見された順序で逐次フックナンバ・レジスタ
RGI、・・・・RGNに書き込んでおく。この書き込
みにおいて、CPU18は、アドレス・デコーダおよび
制御線ALiを介して目的のフックナンバ・レジスタR
Gjを選択的に書込可能とし、データ・バス12を介し
て該レジスタRGjにフックナンバhjをロードする。In the program stored in the ROM (not shown) of this system, a plurality of points are set in advance at predetermined intervals, as in the past. Each time a bug is found during use, a partial program is created to debug it, and data (hook number) hI that identifies the point before the bug is stored in a bug table as shown in Figure 5.
and (RAM
(above) addresses mi are sequentially listed (. However, unlike before, there is no bug check subroutine. Instead, the hook number hi of the point before the bug is
are sequentially written into the hook number registers RGI, . . . RGN in the order in which the bugs were discovered. In this write, the CPU 18 writes the target hook number register R via the address decoder and control line ALi.
Gj is selectively enabled for writing, and the hook number hj is loaded into the register RGj via the data bus 12.
こうして、バグ・テーブル(第5図)にリストされてい
るフックナンバと同しポイント識別データかフックナン
バ・レジスタRGI、・・・・RGNに保持される。In this way, the same point identification data as the hook numbers listed in the bug table (FIG. 5) are held in the hook number registers RGI, . . . RGN.
しかして、第3図に示すように、ROMプログラムの実
行において、CPU18は、各ポイント(命令C)に達
したところで、そのフックナンバhiをデータ・バス1
2上に出力すると同時に書込制御信号WRをアクティブ
状態にすることにより、そのフックナンバh[をレジス
タ2oに書き込む。そうすると、その)、クナンバhi
はレジスタ20より比較器CPI、・・・・CPNに与
えられ、各比較器CPjにおいて、そのフックナンバh
1がフックナンバ・レジスタRGjに保持されているフ
ックナンバhj と比較される。しかして、当該ポイン
トのフックナンバh1がバグ・テーブルにリストされて
いるものならば、(すなわち、該ポイントの後にバグb
gがあるならば)、いずれかの比較器で比較−散(hi
=hj)が得られ)その比較器より“H”レベルの比較
一致信号か出力され、この信号は割込要求出力回路22
に入力される。しかし、このフックナンバhjかバグ・
テーブルにリストされていなければ、(すなわち、該ポ
イントの後にバグbgがないならば)、いずれの比較器
でも比較一致は得られず、したがって割込要求出力回路
22に“H”レベルの信号は入力されない。As shown in FIG. 3, when the CPU 18 reaches each point (instruction C) in executing the ROM program, the CPU 18 transfers the hook number hi to the data bus 1.
By outputting the hook number h[ to the register 2o and at the same time making the write control signal WR active, the hook number h[ is written to the register 2o. Then, that), kunamba hi
is given to the comparators CPI, . . . CPN from the register 20, and in each comparator CPj, its hook number h
1 is compared with the hook number hj held in the hook number register RGj. Therefore, if the hook number h1 of the point is listed in the bug table (i.e., if there is a bug b after the point)
g), the comparison − dispersion (hi
=hj) is obtained), and the comparator outputs an "H" level comparison match signal, and this signal is sent to the interrupt request output circuit 22.
is input. However, this hook number hj or bug
If it is not listed in the table (that is, if there is no bug bg after the point), no comparison match will be obtained in any of the comparators, and therefore an “H” level signal will be sent to the interrupt request output circuit 22. Not entered.
一方、CPU18は、命令Cの次の命令c’でリード信
号RDをアクティブ(“L″)とし、これにより割込要
求出力回路22を出方可能状態とする。上記のようにい
ずれかの比較器より“H”レベルの比較一致仁号か出力
されていれば、割込要求出力回路22よりH”レベルの
信号が割込信号INT(またはNMI)か出力される。On the other hand, the CPU 18 makes the read signal RD active ("L") with the instruction c' following the instruction C, thereby making the interrupt request output circuit 22 ready for output. As described above, if any of the comparators outputs a comparison match signal at the "H" level, the interrupt request output circuit 22 outputs the interrupt signal INT (or NMI) at the H level. Ru.
CPU18は、この割込信号INT(NMI)を受は取
ったときは、RAMに格納されている差替用の部分プロ
グラムPl゛のアドレスmlにジャンプしその部分プロ
グラムP1゛を実行する。その結果、バグbglの実行
が回避される。このようなバグbgiが存在しないとき
は、割込要求出力回路22が割込信号INT(NMI)
を出力することはないので、CPU18の割込処理(差
替部分プログラムPiの実行処理)もなく、命令C“に
続けて次のROMアドレスの命令りの実行に移る。When the CPU 18 receives this interrupt signal INT (NMI), it jumps to the address ml of the replacement partial program P1' stored in the RAM and executes the partial program P1'. As a result, execution of bug bgl is avoided. When such a bug bgi does not exist, the interrupt request output circuit 22 outputs the interrupt signal INT (NMI).
Since the CPU 18 does not output any interrupt processing (execution processing of the replacement partial program Pi), the CPU 18 proceeds to execute the instruction at the next ROM address following the instruction C".
このように、本実施例では、ROMプログラムの各ポイ
ントH1におけるバグ・チエツクは、その時CPU18
より発生されるフックナンバを、バグ−テーブルにリス
トされレジスタに保持されているフックナンバの全てと
ハードウェア的に同時に比較することによって瞬時に行
う。これにより、バグのないポイントでは順駄な時間を
費やすことかなく、バグのあるポイントでは必要最小限
の時間でRAMの部分プログラムに差し替えることがで
きる。In this way, in this embodiment, the bug check at each point H1 of the ROM program is performed by the CPU 18 at that time.
This is done by simultaneously comparing the hook numbers generated by the bug table with all the hook numbers listed in the bug table and held in registers in hardware. As a result, points with no bugs can be replaced with partial programs in RAM without wasting time, and points with bugs can be replaced with the minimum necessary time.
なお、本実施例において、CPU18は、ポイントHi
の命令(C)でフックナンバhiを出力した後、次の命
令C”でリードサイクルを実行することにより、制御回
路より割込信号を選択的に受ける。このように、リード
サイクルを挿入したのはCPUに命令キューがある場合
を考慮したためである。すなわち、命令キューのあるC
PUでは、命令Cのライト・サイクル中に割込を待つこ
となく次の命令をフェッチするので、それから割込が入
ってもCPUは割込処理に入れないという不具合が生ず
る。しかし、リードサイクルを挿入すると、このサイク
ル内でデータ取込みのための間があるので、割込が入っ
ても、これに応答することができる。Note that in this embodiment, the CPU 18
After outputting the hook number hi with the instruction (C), an interrupt signal is selectively received from the control circuit by executing a read cycle with the next instruction C''. This is because we considered the case where the CPU has an instruction queue.
Since the PU fetches the next instruction without waiting for an interrupt during the write cycle of instruction C, a problem arises in that even if an interrupt occurs, the CPU cannot start the interrupt processing. However, when a read cycle is inserted, there is a pause for data acquisition within this cycle, so even if an interrupt occurs, it is possible to respond to it.
また、フックナンバ・レジスタRGの個数は任意に選ぶ
ことができる。動作モード(文字入力。Further, the number of hook number registers RG can be arbitrarily selected. Operation mode (character input.
印字等)毎にフックナンバの入れ替えを行うことで、少
ない個数でも対応することが可能である。By replacing the hook numbers each time (printing, etc.), it is possible to handle even a small number of prints.
[発明の効果]
本発明は、上述したような構成またはステップを何する
ことにより、次のような効果を奏する。[Effects of the Invention] The present invention achieves the following effects by performing the above-described configuration or steps.
請求項1のプログラムシーケンス制tII装置によれば
、バグの手前に位置するポイントを識別するデータをレ
ジスタ手段に保持しておき、各ポイントでCPUより発
生させるポイント識別データと該レジスタ手段に保持し
ているポイント識別データとを照合し、その照合結果に
したがって選択的にCPUに対する割込信号を発生する
ことによりハードウェア的に瞬時にバグ−チエツクを行
うようにしたので、バグのないポイントでは無駄な時間
を費やすことなく本プログラムの実行を進めることがで
き、バグのあるポイントでは必要最小限の時間でRAM
の部分プログラムに差し替えることができる。したがっ
て、CPtJの処理速度が向上し、特にループ処理にポ
イントかある場合において大きな効果か得られる。According to the program sequence system tII device of claim 1, data for identifying a point located before a bug is held in the register means, and point identification data generated by the CPU at each point is held in the register means. By comparing the point identification data with the existing point identification data and selectively generating an interrupt signal to the CPU according to the comparison result, bug checking is performed instantly using hardware, so points without bugs are wasted. You can proceed with the execution of this program without spending a lot of time, and at the point where there is a bug, the RAM is saved in the minimum amount of time necessary.
It can be replaced with a partial program. Therefore, the processing speed of CPtJ is improved, and a great effect can be obtained especially when there is a point in loop processing.
請求項2のプログラムシーケンス制御方法によれば、書
込サイクルでCPUにポイント識別データを発生させ、
次に読出サイクルでCPUに上記照合の結果を読み込ま
せるようにしたので、その照合結果次第で割込かかかっ
ても、CPtJはこれに応動して差替用の部分プログラ
ムに切り替わることができ、これにより、命令キューの
あるCPUでも上記のような本発明の効果が得られる。According to the program sequence control method of claim 2, causing the CPU to generate point identification data in a write cycle;
Next, we made the CPU read the results of the above verification in the read cycle, so even if an interrupt occurs depending on the verification results, CPtJ can respond to this and switch to the replacement partial program. As a result, even a CPU with an instruction queue can obtain the effects of the present invention as described above.
第1図は、本発明の一実施例によるプログラムシーケン
ス制御装置の構成例を示すブロック図、第2図は、実施
例の制御装置とCPUとの接続構成を示すブロック図、
第3図は、実施例の作用を説明するためのプログラム図
、
第4図は、ROMプログラムのバグを回避するための通
常の方法を示すプログラム図、第5図は、RAMの部分
プログラムに差し替えるためのバグ・テーブルを示す図
、および第6図は、従来方式の作用を説明するためのプ
ログラム図である。
図面において、
10・・・・CPU。
18・・・・プログラムシーケンス制御装置、20・・
・・レジスタ、
RGI、〜RGn・・・・フックナンバ・レジスタ、C
Pl、〜CPn・・・・比較器、
22・・・・割込要求出力回路。
第2図
第3図
ROMブDグラム
第4図FIG. 1 is a block diagram showing a configuration example of a program sequence control device according to an embodiment of the present invention, FIG. 2 is a block diagram showing a connection configuration between the control device of the embodiment and a CPU, and FIG. A program diagram for explaining the operation of the embodiment, FIG. 4 is a program diagram showing a normal method for avoiding bugs in ROM programs, and FIG. 5 is a bug table for replacing a partial program in RAM. and FIG. 6 are program diagrams for explaining the operation of the conventional system. In the drawing, 10...CPU. 18...Program sequence control device, 20...
...Register, RGI, ~RGn...Hook number register, C
Pl, ~CPn... Comparator, 22... Interrupt request output circuit. Figure 2 Figure 3 ROM program diagram Figure 4
Claims (2)
イントを所定の間隔をおいて設定し、CPUの実行が各
ポイントに達した時にそのポイントと次のポイントとの
間にバグが存在しているかどうか検査し、そのようなバ
グが存在しているときは一時的に別の記憶装置に格納し
た差替用の部分プログラムを実行して前記バグの実行を
回避するようにしたコンピュータシステムにおいて、各
バグの手前に位置するポイントを識別するデータを保持
するレジスタ手段と、 各ポイントでCPUの発生するそのポイントを識別する
データと前記レジスタ手段に保持されているポイント識
別データとを照合する手段と、前記照合手段の照合結果
にしたがって選択的にCPUに対して前記差替用の部分
プログラムを実行させるための割込信号を発生する手段
と、を具備したことを特徴とするプログラムシーケンス
制御装置。(1) Multiple points are set in advance at predetermined intervals in a program stored in a storage device, and when the CPU reaches each point, a bug exists between that point and the next point. In a computer system that checks whether there is a bug, and if such a bug exists, executes a replacement partial program temporarily stored in another storage device to avoid execution of the bug, register means for holding data for identifying a point located in front of each bug; and means for collating data for identifying the point generated by the CPU at each point with point identification data held in the register means; , means for generating an interrupt signal for selectively causing a CPU to execute the replacement partial program according to the verification result of the verification means.
イントを所定の間隔をおいて設定し、CPUの実行が各
ポイントに達した時にそのポイントと次のポイントとの
間にバグが存在しているかどうか検査し、そのようなバ
グが存在しているときは一時的に別の記憶装置に格納し
た差替用の部分プログラムを実行して前記バグの実行を
回避するようにしたコンピュータシステムにおいて、バ
グの手前に位置するポイントを識別するデータを予め第
1のレジスタ手段に保持しておき、各ポイントにてその
ポイントを識別するデータをCPUに書込サイクルで発
生させて第2のレジスタ手段に書き込み、 前記第2のレジスタ手段に書き込まれたポイント識別デ
ータと前記第1のレジスタ手段に保持されているポイン
ト識別データとを照合し、 前記書込サイクルの直後に読出サイクルで前記照合の結
果をCPUに読み込ませ、照合一致の結果が得られたと
きCPUに割込処理として前記差替用の部分プログラム
を実行させる、 ようにしたことを特徴とするプログラムシーケンス制御
方法。(2) Multiple points are set in advance at predetermined intervals in a program stored in a storage device, and when the CPU reaches each point, it is determined that a bug exists between that point and the next point. In a computer system that checks whether there is a bug, and if such a bug exists, executes a replacement partial program temporarily stored in another storage device to avoid execution of the bug, Data for identifying a point located in front of the bug is held in advance in the first register means, and at each point, data for identifying that point is generated by the CPU in a write cycle and is stored in the second register means. writing, comparing the point identification data written in the second register means with the point identification data held in the first register means, and reading the result of the comparison in a read cycle immediately after the write cycle. A program sequence control method characterized in that the partial program for replacement is read into a CPU, and when a matching result is obtained, the CPU is caused to execute the replacement partial program as an interrupt process.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2293413A JPH04165532A (en) | 1990-10-30 | 1990-10-30 | Method and device for controlling program sequence |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2293413A JPH04165532A (en) | 1990-10-30 | 1990-10-30 | Method and device for controlling program sequence |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JPH04165532A true JPH04165532A (en) | 1992-06-11 |
Family
ID=17794452
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2293413A Pending JPH04165532A (en) | 1990-10-30 | 1990-10-30 | Method and device for controlling program sequence |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPH04165532A (en) |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2002007159A (en) * | 2000-06-26 | 2002-01-11 | Matsushita Electric Ind Co Ltd | Semiconductor device |
-
1990
- 1990-10-30 JP JP2293413A patent/JPH04165532A/en active Pending
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2002007159A (en) * | 2000-06-26 | 2002-01-11 | Matsushita Electric Ind Co Ltd | Semiconductor device |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| GB2329049A (en) | A debugger interface unit for identifying selected exceptions | |
| US7761744B2 (en) | Debugging method | |
| US20050229163A1 (en) | Thread-scoped breakpoints | |
| JP2922723B2 (en) | Information processing device | |
| US8108840B2 (en) | Method for enhancing debugger performance of hardware assisted breakpoints | |
| US8701089B2 (en) | Program execution device and method for controlling the same | |
| JP2944321B2 (en) | Logical evaluation system | |
| JP3356007B2 (en) | Graphics LSI | |
| JP2738360B2 (en) | Multitask program debugging method and debugging system | |
| JP2616542B2 (en) | Pseudo failure generation system | |
| JPS59183443A (en) | Debug device | |
| JP2001147830A (en) | Method for changing state of real time os | |
| CN120386709A (en) | Data code debugging method and terminal | |
| JP2967741B2 (en) | CPU compatibility test equipment | |
| JP2005122337A (en) | Bus system, host bridge, on-line restarting method for bus system, and program | |
| JP2570119B2 (en) | Software simulator | |
| JP2002251296A (en) | Debug method | |
| JPH08241225A (en) | Evaluation device | |
| JPS6059446A (en) | Test method of processor | |
| JPH05250207A (en) | Debug maintenance system | |
| JPS6167146A (en) | Pseudo fault generating system | |
| JPH04287231A (en) | Microprocessor | |
| JPH0784826A (en) | Microprocessor | |
| JPH0272438A (en) | Debugging system | |
| JPH04123235A (en) | Debugging method and system for microprogram |