Method and apparatus for correcting common errors in multiple versions of a computer program
AssigneeGeneral Electric Company
InventorRobert Dennis Jones
Life of this patent
Estimating the term…
Loading patent…
AssigneeGeneral Electric Company
InventorRobert Dennis Jones
Estimating the term…
The present invention relates to a repair program for multiple versions of computer programs that have a common error by using a pattern search and substitution technique. The invention includes identifying a common error in a main computer program, finding a common code section that contains the common error, and locating a segment of the common code section that is modifiable. The code section is then modified by optimizing the code to perform the same functionality and adding additional code to correct the error. A repair program is then written to search other versions of the main computer program and perform the modification step automatically without having to manipulate the source or machine code manually on the various versions of the software.
A method of correcting a common error in multiple versions of a computer program comprising the steps of:
A computer repair program stored on a computer readable storage medium to repair an error in a one version of an affected computer program stored in a computer, the computer repair program programmed to:
Dependencies are inferred from the claim text.
Drawings are temporarily unavailable. Open the PDF at USPTO
Debugging of software: by instrumenting at runtime
Arrangements for software engineering: software maintenance or management
Computing and data processing
Term ended 10 Jun 2019 (estimated)
USPTO file history isn’t available for this patent, so only indexed dates are shown.
The present invention relates generally to computer programs, and more particularly to a method and apparatus for correcting common errors in multiple versions of a computer program using pattern substitution.
It is commonly known that software programs are constantly updated, adding new features and repairing errors. Each update is considered a new version and oftentimes, there are many versions of a software program in existence at any given time. As a result, many versions of a program may have commonly-shared problems, such as a common Year 2000 (Y2K) problem.
To repair a Y2K problem in multiple versions of a computer program by conventional methods would include modifying the source code and creating yet another new version. If there are N existing versions of a given program, such a repair could require the creation of N new versions. Furthermore, when creating a new version of the program using compilation tools, the variables may be at different memory locations than in the prior version, which could result in additional problems. For example, because complex software may contain small errors that are sensitive to the locations of these variables, this technique may result in an unexpected change in the behavior of the program. Therefore, additional testing is required to determine that no undesired behavioral changes were induced. In other words, the programmer who is repairing the program for one problem, for example a Y2K problem, must thoroughly test each version of the program to ensure that no additional problems have been caused because of the repair.
The drawings illustrate the best mode presently contemplated for carrying out the invention.
In the drawings:
FIG. 1 is a schematic view of a general purpose computer.
Referring to FIG. 1, a general purpose computer 10 is commonly thought of as including a computer monitor 12 and the computer itself 14. The computer 14 includes a hard drive 16 capable of storing computer programs and a disk drive 18 for reading data and computer program files from a transportable medium 20. The transportable medium 20 may be a floppy disk or any other computer readable storage medium that can transport data into and from the computer 14. Typically, the computer program to be repaired is located on the hard drive 16 and the repair program of the present invention would reside on a transportable computer readable storage medium 20 to repair the main program on the hard drive 16. Alternatively, a network connection to the computer could be used to download the repair program.
Referring now to FIG. 2, a method of generating the repair program is shown. The method is designed to generate a repair program for the repair of multiple versions of a computer program affected by an error from a review of a single version of the computer program affected by the error. In general, to write the repair program, the following steps must first be performed. First 100, the common error in the computer program must be identified 104, and then a common code section that contains the common error must be found 106 from a review of the source code 102. Specifically, to begin 100, an engineer reviews the source code 102 of one version of a computer program affected by an error. By reviewing 102 one version of the program affected by the error, the specific error as implemented in the source code of the affected program, can be identified 104. Then, a larger section of code, which contains the code including the error, is identified 106.
In further detail, the step of finding a common code section is determined not only on a section that contains the common error, but also on one that has not been previously modified as between multiple versions of the main computer program. The machine code that is examined is generated when compiling the common code to locate a segment that has relocatable code that can be modified manually. Therefore, once a specific section of code containing the error is identified 106, a determination 108 of whether the identified section is common to other versions of the computer program is made. In a Y2K or other repair, it is preferable to use a segment containing relocatable code where the address of the date data is relative. It is also preferred to avoid areas that require a linker to resolve the final location of variables since these addresses may differ from version to version. A subroutine that receives the date data, or its address, as an argument is preferred if the other criteria are met. The digital pattern of this affected segment of machine code is the original pattern that can then be found in multiple versions of the main program.