JP3075359B2 - Program debugging start processing method - Google Patents

Program debugging start processing method

Info

Publication number
JP3075359B2
JP3075359B2 JP02249378A JP24937890A JP3075359B2 JP 3075359 B2 JP3075359 B2 JP 3075359B2 JP 02249378 A JP02249378 A JP 02249378A JP 24937890 A JP24937890 A JP 24937890A JP 3075359 B2 JP3075359 B2 JP 3075359B2
Authority
JP
Japan
Prior art keywords
program
debugged
user
task
debugger
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 - Lifetime
Application number
JP02249378A
Other languages
Japanese (ja)
Other versions
JPH04127332A (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.)
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 JP02249378A priority Critical patent/JP3075359B2/en
Publication of JPH04127332A publication Critical patent/JPH04127332A/en
Application granted granted Critical
Publication of JP3075359B2 publication Critical patent/JP3075359B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Description

【発明の詳細な説明】 〔概要〕 複数の利用者が同時に並行してプログラムを動作でき
るようになっている情報処理装置におけるプログラムデ
バッグ開始処理方式に関し, 利用者が被デバッグプログラムとは無関係なタスクや
プロセスについて意識せずに,直ちにプログラムのデバ
ッグを開始できるようにすることを目的とし, デバッガプログラムにおいて被デバッグプログラムに
係る利用者識別記号とプログラム名とを入力する手段
と,入力した利用者識別記号とプログラム名とを管理プ
ログラムに通知する手段と,管理プログラムにおいて通
知された利用者識別記号とプログラム名とを保持し,プ
ログラムのローディングが発生するたびに,その利用者
識別記号とプログラム名とが保持しているものと一致す
るかを判定する手段と,ともに一致する場合に,ローデ
ィングしたプログラムを実行開始直前の状態で待機さ
せ,デバッガプログラムに通知する手段とを備えるよう
に構成する。
DETAILED DESCRIPTION OF THE INVENTION [Summary] The present invention relates to a program debugging start processing method in an information processing apparatus in which a plurality of users can simultaneously operate a program in parallel. Means for inputting a user identification symbol and a program name relating to a program to be debugged in a debugger program, without having to be aware of processes and processes, A means for notifying the management program of the symbol and the program name, and holding the user identification symbol and the program name notified in the management program, and each time a program is loaded, the user identification symbol and the program name are stored. Means for determining whether or not the And a means for making the loaded program stand by in a state immediately before the start of execution and notifying the debugger program.

〔産業上の利用分野〕[Industrial applications]

本発明は,複数の利用者が同時に並行してプログラム
を動作できるようになっている情報処理装置におけるプ
ログラムデバッグ開始処理方式に関する。
The present invention relates to a program debugging start processing method in an information processing apparatus in which a plurality of users can simultaneously operate a program.

〔従来の技術〕[Conventional technology]

作成したプログラムは,必ずしも所期の結果を出力せ
ず,また異常終了することがあるため,その原因を調
べ,プログラムを修正することが必要になる。すなわ
ち,プログラムのデバッグが必要になる。
The created program does not always output the expected result and may end abnormally, so it is necessary to investigate the cause and correct the program. That is, it is necessary to debug the program.

その方法としては,例えば被デバッグプログラム内の
命令の1つまたは複数箇所を,いわゆるブレークポイン
トとして指定し,CPUがそれらの命令のいずれかを実行し
ようとしたとき停止させ,そのときに各変数が期待した
値であるかどうかを調べるなどの方法がとられる。
One way to do this is to specify one or more of the instructions in the program to be debugged as so-called breakpoints, stop the CPU when it tries to execute any of those instructions, and then make each variable A method such as checking whether the value is the expected value is used.

通常,デバッグ作業時に,システム内には被デバッグ
プログラムの他に,デバッガプログラムと呼ばれるプロ
グラムが同時に動作している。デバッガプログラムは,
キーボードディスプレイ装置を通じて利用者との会話を
行い,利用者の指示に従って,被デバッグプログラムを
停止・再開させ,また,被デバッグプログラムの変数を
読んだり書き込んだりし,さらにブレークポイントの設
定や解除を行うなど,被デバッグプログラムの動きを制
御するものである。
Normally, at the time of debugging, a program called a debugger program is simultaneously operating in the system in addition to the program to be debugged. The debugger program is
Conversation with the user through the keyboard display device, stop and restart the program to be debugged, read and write variables of the program to be debugged, and set and release breakpoints according to the user's instructions. Controls the operation of the program to be debugged.

被デバッグプログラムの動作中は,デバッガプログラ
ムは,通常待ち状態にあり,被デバッグプログラムに何
らかの事象(例えばブレークポイントの実行)が発生す
ると,割込みや管理プログラム(OSともいう)のサービ
ス機能呼び出しなどを契機に,管理プログラムは被デバ
ッグプログラムを待ち状態に変更し,それまで待ち状態
にあったデバッガプログラムを動作状態に変更する。こ
うして,被デバッグプログラムとデバッガプログラムと
は,交互に動作する。
During the operation of the debugged program, the debugger program is normally in a waiting state, and when an event (for example, execution of a breakpoint) occurs in the debugged program, an interrupt or a service function call of a management program (also referred to as an OS) is performed. At the same time, the management program changes the program to be debugged to the waiting state, and changes the debugger program that has been in the waiting state to the operating state. Thus, the debugged program and the debugger program operate alternately.

ところで,今日の情報処理装置においては,同時に複
数のキーボードディスプレイ装置から,複数の利用者が
独立にかつ並行してプログラムを実行させる形態をとる
ものが多い。
By the way, many of today's information processing devices take a form in which a plurality of users simultaneously and independently execute programs from a plurality of keyboard display devices.

また,システムの内部では,通常1つのプログラム実
行単位ごとに,1つまたは複数のタスクが生成されるよう
になっている。タスクは生成されるとき,管理プログラ
ム(OS)内の領域に一定の管理情報が作られるととも
に,主記憶上に一定の領域が与えられる。そして,その
領域にプログラムがローディングされ,プログラムの実
行が開始される。管理プログラムは,各タスクに逐次CP
U実行権を割り当てることによって,各プログラムの処
理を進めていく。
In the system, one or a plurality of tasks are usually generated for each program execution unit. When a task is created, certain management information is created in an area in a management program (OS), and a certain area is given on main memory. Then, the program is loaded into the area, and the execution of the program is started. The management program assigns a CP to each task
U The execution of each program proceeds by assigning the execution right.

デバッガプログラムのタスクと,被デバッグプログラ
ムのタスクとの関係は,管理プログラムによって異な
る。ある管理プログラムでは,デバッガプログラムのタ
スクが被デバッグタスクを生成し,そこに被デバッグプ
ログラムをローディングして実行させる機能を有する。
この場合,管理プログラムは被デバッグプログラムの開
始時点で,被デバッグタスクを停止させて,そのタスク
を生成したタスクに通知すれば,デバッグ処理が開始で
きる。
The relationship between the task of the debugger program and the task of the debugged program differs depending on the management program. In a certain management program, a task of a debugger program generates a task to be debugged, and has a function of loading and executing the program to be debugged there.
In this case, the debug process can be started by stopping the task to be debugged at the start of the program to be debugged and notifying the task that generated the task.

しかし,そのような処理機能を持たない管理プログラ
ムにおいては,デバッガプログラムのタスクと被デバッ
グタスクとは,はじめ関連がないので,システム内で被
デバッグプログラムが開始される時点を検出した後,両
者を連結し,交互の動作を開始させる処理が必要にな
る。
However, in a management program that does not have such a processing function, the task of the debugger program and the task to be debugged are initially unrelated, so after detecting the point in time at which the program to be debugged starts in the system, It is necessary to perform a process of connecting and starting alternate operations.

システム内で動作する被デバッグプログラムがただ1
つの場合には,プログラム名を指定すればよかった。し
かし,複数の利用者が各々独立に並行して使用できる情
報処理装置においては,同名のプログラムが実行される
可能性がある。このため,プログラム名によるデバッグ
開始指定は,実際上不可能である。
Only one debugged program running in the system
In the case of two, the program name had to be specified. However, a program having the same name may be executed in an information processing apparatus that can be used independently and in parallel by a plurality of users. For this reason, it is practically impossible to specify the debug start by the program name.

もう1つの方法は,被デバッグプログラムを実行する
タスクを指定する方法であるが,これは指定方法が困難
となる。なぜなら,一般の利用者は,タスク番号をあら
かじめ指定できないし,タスクの一覧表から,目的のタ
スクを識別することが困難であるからである。
Another method is to specify a task to execute the program to be debugged, but this makes the specification method difficult. This is because a general user cannot specify a task number in advance, and it is difficult to identify a target task from a list of tasks.

この第2の型の管理プログラムでは,デバッガプログ
ラムの動作するジョブと,被デバッグプログラムのジョ
ブとは,はじめ独立であるため,被デバッグプログラム
は1つのジョブの下で,タスクが生成され,そのタスク
上でジョブの初期化処理が実行される。その中ではタス
クの実行環境情報を作るために管理プログラム内のいく
つかのプログラムが順に実行され,最後に,被デバッグ
プログラムが開始される。
In the management program of the second type, since the job in which the debugger program operates and the job of the program to be debugged are initially independent, a task is generated under one job in the program to be debugged. Above, the initialization processing of the job is executed. Among them, several programs in the management program are executed in order to create execution environment information of the task, and finally, the program to be debugged is started.

この被デバッグプログラムの開始以前のプログラムの
走行は,普通の利用者にとっては,デバッグ上,意味の
ないものである。そのため,もし被デバッグプログラム
のジョブの下で生成されたタスクの処理の最初からデバ
ッグが始まると,利用者はデバッガプログラムの対話機
能を使用して,被デバッグプログラムがロードされるま
で,処理を進める必要があった。
The running of the program before the start of the debugged program is meaningless to a normal user for debugging. Therefore, if debugging starts from the beginning of the processing of a task generated under the job of the debugged program, the user uses the interactive function of the debugger program to proceed until the program to be debugged is loaded. Needed.

また,ユーザのジョブの下に,複数のタスクが生成さ
れる場合がある。例えば,はじめに1つのタスクが生成
され,そこで管理プログラムの初期化処理が始まり,そ
の中からもう1つのタスク(あるいは,固有のメモリ領
域を持たないタスクに似た小さい実行単位であるプロセ
ス)が生成され,その中で被デバッグプログラムのロー
ディング処理が実行されることがある。なお,このとき
に使用されるプログラムの手続き部は,通常,管理プロ
グラム内にすでにある。
Further, a plurality of tasks may be generated under a user's job. For example, one task is created first, and the initialization process of the management program starts, and another task (or a process that is a small execution unit similar to a task without a specific memory area) is created from it. In such a case, the loading process of the program to be debugged may be executed. The procedure division of the program used at this time is usually already in the management program.

このような場合,被デバッグプログラムの開始まで
に,どのタスクやプロセスを追跡していけばよいのか分
からず,開始点に到達することがさらに困難であった。
In such a case, it is more difficult to reach the starting point because it is not known which task or process should be tracked before the debugged program starts.

〔発明が解決しようとする課題〕[Problems to be solved by the invention]

本発明は上記問題点の解決を図り,利用者が被デバッ
グプログラムの開始以前に走行するシステムプログラム
や,ユーザジョブの下に生成される被デバッグプログラ
ムとは無関係なタスクやプロセスについて意識せずに,
直ちにプログラムのデバッグを開始できるようにするこ
とを目的としている。
SUMMARY OF THE INVENTION The present invention solves the above problems, and allows a user to be aware of a system program that runs before the start of a debugged program and tasks and processes generated under a user job that are not related to the debugged program. ,
The purpose is to be able to start debugging the program immediately.

〔課題を解決するための手段〕[Means for solving the problem]

第1図は本発明の構成例を示す。 FIG. 1 shows a configuration example of the present invention.

第1図において,10はCPUおよびメモリなどからなる情
報処理装置,11はオペレーティング・システム(OS)と
呼ばれる管理プログラム,12はプログラムの起動制御を
行うプログラム起動制御部,13は被デバッグプログラム
検出部,14は被デバッグ指定情報管理部,15はデバッグ対
象である被デバッグプログラムの情報を管理するデバッ
グ開始管理表,16は被デバッグプログラムの情報を通知
する通知部,17はデバッガプログラム,18は利用者識別記
号・プログラム名入力部,19は被デバッグプログラムの
利用者識別記号およびプログラム名を管理プログラム11
に通知する通知部,20は利用者との会話を行いながらデ
バッグを進めるデバッグ会話処理部,21はデバッグ対象
の被デバッグプログラム,22−1,22−2はタスク領域,23
−1,23−2はタスクの管理情報を記憶するタスク制御ブ
ロック(TCB),24はキーボードディスプレイ装置などの
入力装置,25はプログラムを記憶する二次記憶装置など
のプログラム格納装置を表す。
In FIG. 1, reference numeral 10 denotes an information processing device including a CPU and a memory, reference numeral 11 denotes a management program called an operating system (OS), reference numeral 12 denotes a program start control unit for controlling start of a program, and reference numeral 13 denotes a program to be debugged detection unit. , 14 is a debug-designated information management unit, 15 is a debug start management table for managing information of a debug target program to be debugged, 16 is a notification unit for notifying information of a debug target program, 17 is a debugger program, and 18 is a use. The user identification code and program name input section 19 is used to manage the user identification code and program name of the program to be debugged.
, A debug conversation processing unit for performing debugging while conversing with the user, 21 a debugged program to be debugged, 22-1 and 22-2 a task area, 23
Reference numerals -1, 23-2 denote task control blocks (TCBs) for storing task management information; 24, an input device such as a keyboard display device; and 25, a program storage device such as a secondary storage device for storing programs.

利用者が,あるプログラムを動作させるときには,事
前に利用者識別記号(以下,利用者IDという)を入力
し,動作させたいプログラム名を入力する。
When a user operates a certain program, the user inputs a user identification symbol (hereinafter, referred to as a user ID) in advance, and then inputs a program name to be operated.

このシステムでは,デバッガプログラム17と被デバッ
グプログラム21とは,独立に起動される。したがって,
デバッガプログラム17は,デバッグ制御の対象となる被
デバッグプログラム21を知る必要がある。そのため,以
下の手段を備えている。
In this system, the debugger program 17 and the debugged program 21 are started independently. Therefore,
The debugger program 17 needs to know the debugged program 21 to be debugged. Therefore, the following means are provided.

利用者識別記号・プログラム名入力部18は,被デバッ
グプログラム21の利用者IDとプログラム名とを,入力装
置24から管理プログラム11を介して入力する。
The user identification code / program name input unit 18 inputs the user ID and the program name of the program 21 to be debugged from the input device 24 via the management program 11.

そして,通知部19により,管理プログラム11の被デバ
ッグ指定情報管理部14に対して,被デバッグプログラム
21の利用者IDおよびプログラム名を通知する。
The notifying unit 19 sends the debugged program to the debug target designated information management unit 14 of the management program 11.
Notify 21 user IDs and program names.

被デバッグ指定情報管理部14は,通知された利用者ID
およびプログラム名をデバッグ開始管理表15に記入し記
憶する。
The debugged specified information management unit 14 sends the notified user ID
And the program name is entered and stored in the debug start management table 15.

利用者から被デバッグプログラム21の起動依頼がある
と,管理プログラム11におけるプログラム起動制御部12
は,被デバッグプログラム21のローディング時に,被デ
バッグプログラム検出部13により,デバッグ開始管理表
15を参照し,ローディングするプログラムの利用者IDお
よびプログラム名と,デバッグ開始管理表15に保持して
いる利用者IDおよびプログラム名とがともに一致するか
どうかを判定する。
When a user requests to start the debugged program 21, the program start control unit 12 in the management program 11
When the debugged program 21 is loaded, the debugged program detection unit 13 executes
15, it is determined whether the user ID and the program name of the program to be loaded match the user ID and the program name stored in the debugging start management table 15.

管理プログラム11は,利用者IDとプログラム名がとも
に一致する場合に,ローディングした被デバッグプログ
ラム21を実行開始直前の状態で待機させ,通知部16によ
り,被デバッグプログラム21のタスクに関する情報を,
デバッガプログラム17に通知する。
When both the user ID and the program name match, the management program 11 causes the loaded debugged program 21 to wait in a state immediately before the start of execution, and notifies the information about the task of the debugged program 21 by the notifying unit 16.
Notify the debugger program 17.

デバッガプログラム17のデバッグ会話処理部20は,通
知された情報をもとに被デバッグプログラム21を認識
し,利用者との会話処理により,被デバッグプログラム
21に対するデバッグ制御を行う。
The debug conversation processing unit 20 of the debugger program 17 recognizes the program 21 to be debugged based on the notified information, and executes the program to be debugged by conversation processing with the user.
Perform debug control for 21.

〔作用〕[Action]

本発明は,システムの利用者が利用を始めるとき,必
ず利用者IDを入力することを利用する。例えば利用開始
を宣言するログオン・コマンドにより,利用者IDが入力
されたとき,システムは同じ利用者IDですでに利用して
いる人がいないかどうかを調べ,もしいる場合には,後
の利用者の利用を禁止する。このため,利用者IDとプロ
グラム名とを組み合わせると,システム内で一意にプロ
グラムを識別することができる。これを被デバッグプロ
グラム21の指定に利用することにより,管理プログラム
11との連携をとり,デバッガプログラム17は被デバッグ
プログラム21のデバッグを開始する。
The present invention utilizes that a user of a system always enters a user ID when starting to use the system. For example, when a user ID is entered by a logon command declaring the start of use, the system checks whether there is already a user with the same user ID, and if so, uses it later. Prohibit the use of persons. Therefore, by combining the user ID and the program name, the program can be uniquely identified in the system. By using this to specify the debugged program 21, the management program
The debugger program 17 starts debugging the program 21 to be debugged in cooperation with the program 11.

そのため,始めに利用者はデバッガプログラム17を起
動する。この起動により,タスク領域22−1が確保され
て,タスク制御ブロック23−1が生成され,デバッガプ
ログラム17のタスクが動作する。このデバッガプログラ
ム17の中で,利用者は,これから被デバッグプログラム
21を起動するときに使用する利用者IDとプログラム名と
を入力する。
Therefore, the user starts the debugger program 17 first. With this activation, the task area 22-1 is secured, the task control block 23-1 is generated, and the task of the debugger program 17 operates. In this debugger program 17, the user will
Enter the user ID and program name to be used when starting 21.

デバッガプログラム17は,管理プログラム11に対し
て,その利用者IDのもとでその被デバッグプログラム21
がローディングまたは動的に結合された場合に,自タス
クに通知されるよう依頼する。その後,管理プログラム
11のサービス機能を使用して待ち状態に入る。
The debugger program 17 sends the debugged program 21 to the management program 11 under the user ID.
Ask your task to be notified when is loaded or dynamically linked. Then, the management program
Enter wait state using 11 service functions.

管理プログラム11は,システム内でプログラムのロー
ディングが発生するたびに,その利用者IDとプログラム
名とを調べ,もし先にデバッガプログラム17から通知さ
れたものと一致したならば,そのローディング完了の
後,そのタスクを停止状態にし,待ち状態にあるデバッ
ガプログラム17に通知する。このとき,被デバッグプロ
グラム21のタスク制御ブロック23−2等の管理情報のア
ドレスを通知する。これより,デバッガプログラム17
は,被デバッグプログラム21のデバッグを開始する。以
後,デバッガプログラム17は,その管理情報アドレスを
指定して,被デバッグプログラム21のブレークポイント
の設定や,再開,データの読み取り,書き出しなどを依
頼する。
Each time a program is loaded in the system, the management program 11 checks the user ID and the program name. If the user ID and the program name match with the one notified by the debugger program 17, the management program 11 completes the loading. Then, the task is stopped and the debugger program 17 in the waiting state is notified. At this time, the address of the management information of the task control block 23-2 of the debugged program 21 is notified. The debugger program 17
Starts debugging of the program 21 to be debugged. Thereafter, the debugger program 17 designates the management information address and requests the setting of a breakpoint of the program to be debugged 21, the restart, the reading and writing of data, and the like.

〔実施例〕〔Example〕

第2図は本発明の実施例に係るデバッグ開始処理の流
れ,第3図は本発明の実施例によるデバッガプログラム
の処理フロー,第4図は本発明の実施例によるデバッグ
会話処理の処理フロー,第5図は本発明の実施例に係る
デバッグ開始管理表の構成例,第6図は本発明に実施例
に係るタスク制御ブロックの構成例,第7図は本発明の
実施例による利用者プログラムの開始処理の処理フロー
を示す。
FIG. 2 is a flowchart of a debug start process according to the embodiment of the present invention, FIG. 3 is a debugger program process flow according to the embodiment of the present invention, FIG. 4 is a debug conversation process flow according to the embodiment of the present invention, FIG. 5 is a configuration example of a debug start management table according to the embodiment of the present invention, FIG. 6 is a configuration example of a task control block according to the embodiment of the present invention, and FIG. 7 is a user program according to the embodiment of the present invention. 3 shows a processing flow of the start processing of the processing.

第1図に示す構成によるデバッグ開始処理の全体の処
理の流れを,第2図に示す〜に従って説明する。
The overall flow of the debugging start process with the configuration shown in FIG. 1 will be described with reference to FIGS.

デバッガプログラム17の起動は,通常の利用者プロ
グラムの起動と同様に,利用者IDを指定して,ログオン
・コマンドを投入し,それに続いてプログラム名を指定
して,起動コマンドを投入することにより行う。また
は,ジョブ制御文などによりデバッガプログラム17を起
動する。実行プログラム名としては,デバッガプログラ
ム17のプログラム名を指定する。
The debugger program 17 is started by specifying a user ID and issuing a logon command, followed by specifying a program name and issuing a start command in the same manner as a normal user program is started. Do. Alternatively, the debugger program 17 is started by a job control statement or the like. The program name of the debugger program 17 is specified as the execution program name.

管理プログラム11によってデバッガプログラム17が
起動されると,デバッガプログラム17は,デバッグしよ
うとする被デバッグプログラム21を起動するときに指定
する利用者IDを会話処理によって入力する。ここでは,
利用者IDとしてCが入力されたとする。なお,このCの
利用者IDは,デバッガプログラム17の利用者IDとは異な
る。
When the debugger program 17 is started by the management program 11, the debugger program 17 inputs a user ID specified when starting the debugged program 21 to be debugged by conversation processing. here,
It is assumed that C has been input as the user ID. Note that the user ID of C is different from the user ID of the debugger program 17.

次に,被デバッグプログラム21のプログラム名を会
話処理によって入力する。ここでは,プログラム名とし
てDが入力されたとする。
Next, the program name of the program 21 to be debugged is input by conversation processing. Here, it is assumed that D is input as the program name.

デバッガプログラム17は,管理プログラム(OS)11
に対して,利用者ID=Cとプログラム名=Dを内容とす
る被デバッグプログラム開始事象通知を依頼する。管理
プログラム11は,通知された利用者ID=Cとプログラム
名=Dを記憶する。
The debugger program 17 is the management program (OS) 11
Is requested to notify the start event of the program to be debugged having the contents of user ID = C and program name = D. The management program 11 stores the notified user ID = C and program name = D.

デバッガプログラム17は,被デバッグプログラムグ
ラム開始事象の通知をOSに依頼したならば,WAITマクロ
を発行し,タスク実行待ち状態に入る。
When the debugger program 17 has requested the OS to notify the start event of the program to be debugged, it issues a WAIT macro and enters a task execution wait state.

一方,被デバッグプログラム21は,利用者プログラ
ムの1つとして,デバッガプログラム17とは独立に,例
えばログオン・コマンドおよびそれに続くプログラム起
動コマンド,またはジョブ制御文などにより起動され
る。被デバッグプログラム21の利用者IDがC,プログラム
名がDであったとする。
On the other hand, the debugged program 21 is started as one of the user programs independently of the debugger program 17 by, for example, a logon command and a subsequent program start command or a job control statement. Assume that the user ID of the debugged program 21 is C and the program name is D.

管理プログラム11は,プログラム名=Dのプログラ
ムのローディング処理を行う。この際に,利用者ID=C
とプログラム名=Dの情報がデバッグ開始管理表15に記
憶されているかどうかを調べる。
The management program 11 performs a loading process of the program with the program name = D. At this time, user ID = C
It is checked whether or not the information of program name = D is stored in the debug start management table 15.

ローディングした被デバッグプログラム21の利用者
ID=Cおよびプログラム名=Dが,記憶されているもの
と一致した場合には,被デバッグプログラム21を実行の
開始直前で停止状態にする。
User of loaded debugged program 21
If the ID = C and the program name = D match the stored ones, the debugged program 21 is stopped just before the start of execution.

また,管理プログラム11は,デバッガプログラム17
に対して,被デバッグプログラム21のタスクの管理情報
のアドレス等を通知する。
The management program 11 is a debugger program 17
, The address of the management information of the task of the program to be debugged 21 is notified.

デバッガプログラム17は,利用者に対し,デバッグ
開始を表示し,デバッグのための会話処理を行う。以下
は,デバッグの例である。
The debugger program 17 displays the start of debugging to the user and performs a conversation process for debugging. The following is an example of debugging.

ブレークポイントの設定指示があると,管理プログ
ラム11に,その設定を依頼する。
When a breakpoint setting instruction is issued, the management program 11 is requested to set the breakpoint.

ブレークポイントの設定が完了すると,それを表示
する。
When the breakpoint is set, it is displayed.

実行開始の指示があると,管理プログラム11に被デ
バッグプログラム21の実行開始を依頼する。
When the execution start instruction is issued, the management program 11 is requested to start execution of the debugged program 21.

被デバッグプログラム21は,処理を再開する。 The debugged program 21 resumes processing.

ブレークポイント上で被デバッグプログラム21の動
作が停止すると,管理プログラム11は,デバッガプログ
ラム17にそれを通知する。
When the operation of the debugged program 21 stops at the break point, the management program 11 notifies the debugger program 17 of the stop.

デバッガプログラム17は,被デバッグプログラム21
の停止を利用者に通知し,同様にデバッグのための会話
処理を行う。
The debugger program 17 is the debugged program 21
Is notified to the user, and a conversation process for debugging is similarly performed.

以上の処理を実現するデバッガプログラム17の処理フ
ローは,第3図に示すとおりである。
The processing flow of the debugger program 17 for realizing the above processing is as shown in FIG.

被デバッグプログラム21の利用者識別記号(利用者
ID)を入力する。
User identification code of the debugged program 21 (user
ID).

被デバッグプログラム名を入力する。 Enter the name of the program to be debugged.

管理プログラム(OS)11に被デバッグプログラム21
開始時のローディング事象の通知を依頼する。
Debugged program 21 in management program (OS) 11
Request notification of the loading event at the start.

待ち(WAIT)状態に入る。 Enter the WAIT state.

利用者とのデバッグ会話処理によってデバッグを行
う。
Debugging is performed by debugging conversation processing with the user.

第3図に示す処理のデバッグ会話処理の処理フロー
は,第4図に示すとおりである。
The processing flow of the debug conversation processing of the processing shown in FIG. 3 is as shown in FIG.

デバッガプログラム17が提供するデバッグコマンド
を入力する。デバッグコマンドの内容に応じて,以下の
処理〜を行う。
A debug command provided by the debugger program 17 is input. The following processes are performed according to the contents of the debug command.

デバッガタスクへの指示情報であれば,デバッガタ
スク内の処理を行う。
If it is the instruction information for the debugger task, the process in the debugger task is performed.

被デバッグプログラム21のデータの読み取りまたは
書き出しであれば,被デバッグタスク用メモリ領域やレ
ジスタ退避域へのリード(READ)またはライト(WRIT
E)を行う。
To read or write the data of the debugged program 21, read (READ) or write (WRIT) the memory area or register save area for the debugged task.
E).

被デバッグプログラム21の実行指示であれば,被デ
バッグタスクの動作を開始させる。その後,被デバッグ
タスクの事象発生を待つ。
If the instruction is to execute the debugged program 21, the operation of the debugged task is started. After that, it waits for the event of the task to be debugged.

デバッグコマンドが終了コマンドであれば,デバッ
グの終了処理を行う。
If the debug command is an end command, a debug end process is performed.

第5図は,第1図に示すデバッグ開始管理表15の構成
例を示している。
FIG. 5 shows a configuration example of the debug start management table 15 shown in FIG.

被デバッグ指定情報管理部14は,デバッガプログラム
17からの通知により,デバッグ開始管理表15に,被デバ
ッグプログラム21の利用者IDと被デバッグプログラム名
と要求元タスクのTCBアドレスを記憶する。要求元タス
クのTCBアドレスとは,デバッガプログラム17のタスク
制御ブロック23−1のアドレスであり,被デバッグプロ
グラム21のローディング事象を通知するときに使用す
る。
The debug specification information management unit 14 is a debugger program.
In response to the notification from 17, the user ID of the program 21 to be debugged, the program name to be debugged, and the TCB address of the requesting task are stored in the debug start management table 15. The TCB address of the request source task is the address of the task control block 23-1 of the debugger program 17, and is used when notifying the loading event of the debugged program 21.

第6図は,タスク制御ブロック23の構成例を示してい
る。
FIG. 6 shows a configuration example of the task control block 23.

タスク制御ブロック23は,CPU実行権を与える単位であ
るタスクを管理するための制御表で,タスク管理機能を
持つ通常のオペレーティング・システムで用いられてい
るものである。
The task control block 23 is a control table for managing a task which is a unit for giving a CPU execution right, and is used in a normal operating system having a task management function.

管理情報として,例えば利用者ID,そのタスク上で動
作するプログラム名,メモリ領域開始アドレス,そのメ
モリ領域のサイズ,動作状態にあるか待ち状態にあるか
などのタスクの状態を示す情報,待ち状態時のCPUのレ
ジスタ退避域などがある。
As management information, for example, a user ID, a name of a program operating on the task, a memory area start address, information on a size of the memory area, information indicating a task state such as operating or waiting, and a waiting state. There is a CPU register save area at the time.

第1図に示すプログラム起動制御部12による利用者プ
ログラムの開始処理の処理フローは,例えば第7図に示
す〜のようになっている。
The processing flow of the start processing of the user program by the program activation control unit 12 shown in FIG. 1 is, for example, as shown in FIG.

利用者ID(例えばC)を入力する。 Enter the user ID (for example, C).

利用者管理表(図示省略)を検索する。 Search the user management table (not shown).

同じ利用者IDのプログラムが走行中かどうかを調
べ,走行中でなければ,処理へ進む。
It is checked whether or not the program of the same user ID is running, and if not, the process proceeds.

同じ利用者IDのプログラムが他に走行していれば,
利用禁止を表示する。
If another program with the same user ID is running,
Displays usage prohibition.

同じ利用者IDのプログラムが走行中でなければ,実
行プログラム名(例えばD)を入力する。
If a program with the same user ID is not running, an execution program name (for example, D) is input.

利用者プログラムを動作させるためのタスクを生成
する。
Generate a task to run the user program.

利用者プログラムDをロードする。 Load the user program D.

第1図に示すデバッグ開始管理表15に,利用者ID=
Cとプログラム名=Dの情報が登録されているかどうか
を調べる。登録されていない場合,処理へ移る。
In the debugging start management table 15 shown in FIG.
It is checked whether information of C and program name = D is registered. If not registered, the process proceeds.

登録されていれば,そのタスクを停止状態にし,要
求元タスクすなわち第1図に示すデバッガプログラム17
に通知する。
If it is registered, the task is stopped, and the requesting task, that is, the debugger program 17 shown in FIG.
Notify.

デバッグ開始管理表15に登録されていなければ,通
常の利用者プログラムとしてプログラムの実行を開始す
る。
If it is not registered in the debug start management table 15, the program execution is started as a normal user program.

〔発明の効果〕〔The invention's effect〕

以上説明したように,本発明によれば,複数の利用者
が同時に並行してプログラムを動作できるようになって
いるシステムにおいて,独立に動作するデバッガプログ
ラムからデバッグ対象の被デバッグプログラムを簡単に
認識して,デバッグを開始できるようになる。
As described above, according to the present invention, in a system in which a plurality of users can operate programs in parallel at the same time, a debug target program to be debugged can be easily recognized from an independently operating debugger program. Then, you can start debugging.

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

第1図は本発明の構成例, 第2図は本発明の実施例に係るデバッグ開始処理の流
れ, 第3図は本発明の実施例によるデバッガプログラムの処
理フロー, 第4図は本発明の実施例によるデバッグ会話処理の処理
フロー, 第5図は本発明の実施例に係るデバッグ開始管理表の構
成例, 第6図は本発明に実施例に係るタスク制御ブロックの構
成例, 第7図は本発明の実施例による利用者プログラムの開始
処理の処理フローを示す。 図中,10は情報処理装置,11は管理プログラム,12はプロ
グラム起動制御部,13は被デバッグプログラム検出部,14
は被デバッグ指定情報管理部,15はデバッグ開始管理表,
16は通知部,17はデバッガプログラム,18は利用者識別記
号・プログラム名入力部,19は通知部,20はデバッグ会話
処理部,21は被デバッグプログラム,22−1,22−2はタス
ク領域,23−1,23−2はタスク制御ブロック,24は入力装
置,25はプログラム格納装置を表す。
1 is a configuration example of the present invention, FIG. 2 is a flow of a debugging start process according to an embodiment of the present invention, FIG. 3 is a processing flow of a debugger program according to the embodiment of the present invention, and FIG. FIG. 5 is a configuration example of a debug start management table according to the embodiment of the present invention, FIG. 6 is a configuration example of a task control block according to the embodiment of the present invention, FIG. 9 shows a processing flow of a start process of a user program according to the embodiment of the present invention. In the figure, 10 is an information processing device, 11 is a management program, 12 is a program start control unit, 13 is a debugged program detection unit, 14
Is the debugged information management unit, 15 is the debug start management table,
16 is a notification section, 17 is a debugger program, 18 is a user identification symbol / program name input section, 19 is a notification section, 20 is a debug conversation processing section, 21 is a program to be debugged, and 22-1 and 22-2 are task areas. , 23-1 and 23-2 represent task control blocks, 24 represents an input device, and 25 represents a program storage device.

フロントページの続き (56)参考文献 特開 平1−169546(JP,A) S.J.Leffleretal”T he Design and Impl ementation of the 4.3BSD Unix Operat ing System”(USA)Ad dison−Wesley Pub.C o.Inc.(Nov.1989)pp.69 −86 アスキー編集局編「標準MS−DOS ハンドブック」(昭60−10−5)アスキ ーpp.180−205 (58)調査した分野(Int.Cl.7,DB名) G06F 11/28 Continuation of front page (56) References JP-A-1-169546 (JP, A) J. Refleletal "The Design and Implementment of the 4.3 BSD Unix Operating System" (USA) Addison-Wesley Pub. Co. Inc. (Nov. 1989) pp. 69-86 ASCII Editing Bureau “Standard MS-DOS Handbook” (Showa 60-10-5). 180-205 (58) Field surveyed (Int. Cl. 7 , DB name) G06F 11/28

Claims (1)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】利用者識別記号とプログラム名とを入力す
る手段を有し,これに基づいてプログラムを主記憶上に
ローディングし,プログラムを実行する管理プログラム
(11)を有する情報処理装置(10)におけるプログラム
デバッグ開始処理方式において, 被デバッグプログラム(21)と同じ情報処理装置(10)
上で独立に動作するデバッガプログラム(17)において
被デバッグプログラムに係る利用者識別記号とプログラ
ム名とを入力する手段(18)と, 入力した利用者識別記号とプログラム名とを管理プログ
ラムに通知する手段(19)と, 管理プログラムにおいて通知された利用者識別記号とプ
ログラム名とを保持し,プログラムのローディングが発
生するたびに,そのプログラムの利用者識別記号および
プログラム名と,保持している利用者識別記号およびプ
ログラム名とがそれぞれ一致するかどうかを判定する手
段(13,14)と, ともに一致する場合に,ローディングしたプログラムを
実行開始直前の状態で待機させ,デバッガプログラムに
通知する手段(16)とを備えたことを特徴とするプログ
ラムデバッグ開始処理方式。
An information processing apparatus (10) having means for inputting a user identification symbol and a program name, loading a program on a main memory based on the user identification code, and having a management program (11) for executing the program. The same information processing device (10) as the program to be debugged (21)
Means (18) for inputting a user identification symbol and a program name relating to a program to be debugged in a debugger program (17) which operates independently on the above, and notifies the management program of the input user identification symbol and the program name. Means (19), the user identification symbol and the program name notified in the management program are retained, and each time the program is loaded, the user identification symbol and the program name of the program and the retained usage are stored. Means for determining whether the user identification symbol and the program name match (13, 14), and when both match, means for waiting the loaded program in a state immediately before the start of execution and notifying the debugger program ( 16) A program debugging start processing method characterized by comprising:
JP02249378A 1990-09-19 1990-09-19 Program debugging start processing method Expired - Lifetime JP3075359B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP02249378A JP3075359B2 (en) 1990-09-19 1990-09-19 Program debugging start processing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP02249378A JP3075359B2 (en) 1990-09-19 1990-09-19 Program debugging start processing method

Publications (2)

Publication Number Publication Date
JPH04127332A JPH04127332A (en) 1992-04-28
JP3075359B2 true JP3075359B2 (en) 2000-08-14

Family

ID=17192129

Family Applications (1)

Application Number Title Priority Date Filing Date
JP02249378A Expired - Lifetime JP3075359B2 (en) 1990-09-19 1990-09-19 Program debugging start processing method

Country Status (1)

Country Link
JP (1) JP3075359B2 (en)

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH01169546A (en) * 1987-12-24 1989-07-04 Yokogawa Electric Corp Multi-task debugger

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
S.J.Leffleretal"The Design and Implementation of the 4.3BSD Unix Operating System"(USA)Addison−Wesley Pub.Co.Inc.(Nov.1989)pp.69−86
アスキー編集局編「標準MS−DOSハンドブック」(昭60−10−5)アスキーpp.180−205

Also Published As

Publication number Publication date
JPH04127332A (en) 1992-04-28

Similar Documents

Publication Publication Date Title
US5319645A (en) Method for debugging and testing the correctness of programs
US8136097B2 (en) Thread debugging device, thread debugging method and information storage medium
US4675814A (en) Method of switching operating systems for a data processing system
US4660144A (en) Adjunct machine
JP2001134466A (en) Debug device and debug method and program recording medium
JPH06100956B2 (en) Device for pointer control
US7865883B1 (en) Parallel and asynchronous debugger and debugging method for multi-threaded programs
JP2000066904A (en) Method for controlling multitask and storage medium
US6131109A (en) Multitask processor, a multitask processing method, a multitask processing display method and a storage medium for processing by correlating task and object
JPH09259002A (en) Debug support device
JP3075359B2 (en) Program debugging start processing method
JPH07225694A (en) Virtual computer system
JPH08272755A (en) Process switching device
JPH0922369A (en) Illicit operation detection method in kernel of multi-tasking system
JPH04314141A (en) Method and mechanism for controlling multi-task
JP2001229038A (en) Multi-operating computer system
JP2000293385A (en) System and method for thread management and recording medium with management program recorded thereon
JPH03138753A (en) Boot loader for multiprocessor system
JP2000250777A (en) Information processor, information processing method and storage medium
JPH0589049A (en) Command executing device
JP2023071103A (en) Process schedule method
JP2007041887A (en) Debugging apparatus, its memory access method and program for realizing memory access method
JPH0378034A (en) Program parallel execution device
JPS6214240A (en) Program inspecting system
JPS62290942A (en) Debugger starting system