Debugging method and apparatus for multitask programs and...

Error detection/correction and fault detection/recovery – Data processing system error or fault handling – Reliability and availability

Reexamination Certificate

Rate now

  [ 0.00 ] – not rated yet Voters 0   Comments 0

Details

C714S012000, C714S034000, C717S129000

Reexamination Certificate

active

06718484

ABSTRACT:

CROSS REFERENCE TO RELATED APPLICATIONS
The contents of Japanese Patent Application No. 11-31622 filed on Nov., 1999 in Japan, are incorporated herein by reference.
BACKGROUND OF THE INVENTION
1. Field of the Invention
The present invention relates to a debugging method and apparatus for multitask programs, as well as to a recording medium storing a program used for realization of the debugging method and apparatus. More particularly, the present invention relates to a debugging method and apparatus which enables each of selected tasks to be stopped at an arbitrary target program position, as well as to a recording medium storing a program used for realization of such a debugging method and apparatus.
With the recent decrease in price of CPUs due to development of computer-related techniques, an increasing number of computer systems have employed a plurality of CPUs. Further, in order to effectively use a plurality of CPUs, in an increasing number of cases such a computer system has used a multitask program in which a plurality of tasks are performed concurrently and in parallel in order to execute a single job.
Multitask programs are divided into a multithread program which executes in parallel a plurality of interdependent threads in a process, and a multiprocess program which executes in parallel a plurality of interdependent processes. An examples of the multiprocess program include a network parallel program in which a plurality of processes are executed on a plurality of computer systems in a distributed manner.
In order to properly operate such a multitask program formed of a plurality of interdependent tasks, the plurality of selected tasks must be synchronized at a proper timing (program position). If this synchronization is not established, the multitask program does not operate properly.
In view of the foregoing, there has been demand for a debugging technique for multitask programs which effectively determines whether a plurality of selected tasks are synchronized at a proper timing.
2. Description of the Related Art
Japanese Patent Application Laid-Open (kokai) No. 2-300942 discloses an existing debugging technique for multitask programs in which a plurality of tasks are concurrently executed in parallel. In the technique, when execution of any one of a plurality of tasks designated among tasks which operate on an operating system is stopped (at a breakpoint set by a debugger), the remainder of the designated tasks are stopped at the same time.
Japanese Patent Application Laid-Open (kokai) No. 4-314141 discloses a multitask control technique. According to the multitask control technique, for the purpose of debugging, when an arbitrary task constituting a multitask job reaches a previously set stop point or when an exception occurs, all tasks belonging to the same multitask job group as the arbitrary task are stopped. Further, execution of all the tasks of the multitask job group is resumed at an arbitrary point in time.
Although not relating directly to debugging processing, Japanese Patent Application Laid-Open (kokai) No. 63-4339 discloses a technique for controlling a plant by use of a plurality of tasks which constitute plant control. In order to overcome a drawback such that a system of a plant which is not required to stop is stopped undesirably, tasks are managed in order to form a task group which includes tasks which must be stopped concurrently upon stoppage of any one of the tasks. In the task managing technique, when, in response to detection of an anomalous state, an operating system stops a task belonging to a certain group, the remaining tasks of the same group are stopped.
However, use of such an existing debugging technique makes it impossible to realize barrier synchronization which enables each of selected tasks to stop at an arbitrary target program position.
That is, the existing techniques disclosed in the above-described Japanese Patent Application Laid-Open Nos. 2-300942 and 4-314141 employ a configuration such that when execution of any one of grouped tasks is stopped, the remaining tasks of the group are stopped concurrently. Therefore, barrier synchronization which enables each of selected tasks to be stopped at an arbitrary target program position cannot be realized.
Such barrier synchronization becomes necessary for debugging of a multitask program in which a plurality of tasks perform initialization processing or calculation processing, each task taking partial charge of the processing.
One conceivable method for realizing such barrier synchronization is such that a barrier synchronization mechanism is built in a multitask program to undergo debugging, through rewriting thereof; a breakpoint is set (an instruction for stopping the program is embedded) at a program position at which barrier synchronization is guaranteed to be completed; and the multitask program is executed up to that position.
However, when this method is employed, a multitask program to undergo debugging must be rewritten for insertion of a barrier synchronization mechanism. In some cases this may hide the real cause of an anomaly. Further, when a barrier synchronization mechanism to be inserted has a defect, there arise various problems, such as necessity of work for searching the defect, or generation of a new bug.
SUMMARY OF THE INVENTION
In view of the above-described problems, a first object of the present invention is to provide a new debugging method and apparatus for a multitask program which enables each of selected tasks to be stopped at an arbitrary target program position.
A second object of the present invention is to provide a program recording medium which stores therein a program used for realization of the debugging method and apparatus.
A third object of the present invention is to provide a debugging method and apparatus which can perform debugging efficiently, as well as a program recording medium which stores therein a program used for realization of such a debugging method and apparatus.
A fourth object of the present invention is to provide a debugging apparatus which can perform debugging on the basis of barrier synchronization, while matching the sequence of execution of programs.
In order to achieve the above objects, the present invention provides a debugging apparatus for debugging a multitask program. It comprises setting means for setting a barrier synchronization point which groups a breakpoint set for each of a plurality of tasks; judgment means operating each time a different one of the tasks stops at a corresponding breakpoint, in order to judge whether all tasks having breakpoints belonging to the barrier synchronization point have stopped at the respective breakpoints; resumption means operating, upon judgment by the judgment means that not all the tasks have stopped, in order to bring a newly stopped task into a suspended state and then resume execution of a multithread program; and control means for bringing the suspended tasks back to an executable state when the judgment means judges that all the tasks have stopped.
Preferably, the debugging apparatus of the present invention further comprises specifying means for specifying a barrier synchronization point which includes a breakpoint having first stopped a task. When a task stops at a breakpoint belonging to the specified barrier synchronization point, the judgment means judges whether all tasks having breakpoints belonging to the barrier synchronization point specified by the specifying means have stopped at the respective breakpoints.
In order to achieve the above objects, the present invention provides a debugging method for debugging a multitask program. It comprises setting a barrier synchronization point which groups a breakpoint set for each of a plurality of tasks; each time a different one of the tasks stops at a corresponding breakpoint, judging whether all tasks having breakpoints belonging to the barrier synchronization point have stopped at the respective breakpoints; upon judgment that not all the tasks have stopped, bringing a newly stopped task into a suspended

LandOfFree

Say what you really think

Search LandOfFree.com for the USA inventors and patents. Rate them and share your experience with other people.

Rating

Debugging method and apparatus for multitask programs and... does not yet have a rating. At this time, there are no reviews or comments for this patent.

If you have personal experience with Debugging method and apparatus for multitask programs and..., we encourage you to share that experience with our LandOfFree.com community. Your opinion is very important and Debugging method and apparatus for multitask programs and... will most certainly appreciate the feedback.

Rate now

     

Profile ID: LFUS-PAI-O-3208296

  Search
All data on this website is collected from public sources. Our data reflects the most accurate information available at the time of publication.