Instrumentation and dynamic test coverage information extraction method of C-language embedded software

A technology for embedded software and dynamic testing, applied in software testing/debugging and other directions, can solve the problems of large expansion rate of instrumentation code, low expansion rate of post-code, complicated instrumentation principle, etc., and achieve small code expansion rate and storage space. Small, does not occupy the effect of hardware resources
CN102419731AInactive Publication Date: 2012-04-18BEIJING INST OF CONTROL ENG

Patent Information

Authority / Receiving Office
CN Β· China
Current Assignee / Owner
BEIJING INST OF CONTROL ENG
Publication Date
2012-04-18
Estimated Expiration
Not applicable Β· inactive patent

Smart Images

  • Figure 1
    Figure 1
  • Figure 2
    Figure 2
Patent Text Reader

Abstract

The invention discloses an instrumentation and dynamic test coverage information extraction method of C-language embedded software. The method comprises the following steps of: regarding a C-language program as an array which is formed by all branch points, wherein each branch point corresponds to an element in the array; defining each element to be in two states, wherein 1 represents that the branch points are executed, and 0 represents that the branch points are unexecuted; defining the array in a special storage area; at each branch point of the C-language program, adding an operation code into a branch point information array which is defined in the special storage area, wherein the operation code is used for outputting information which indicates whether the branch points are executed; executing the C-language program into which the operation code is added, and then extracting the branch point information array from the special storage area; and according to the state of each element in the branch point information array, determining the execution situation of each branch point in the C-language program, and thus obtaining the dynamic test coverage of the C-language program. The instrumentation and dynamic test coverage information extraction method of the C-language embedded software has the characteristics of low code expansion rate, small storage space of branch point information, and convenience for extraction of coverage information.
Need to check novelty before this filing date? Find Prior Art

Description

technical field

[0001] The invention relates to a C language embedded software testing method, which is suitable for the dynamic white box test of the C language embedded software running in the DSP environment. Background technique

[0002] Software instrumentation and dynamic test coverage information extraction technology are the core technologies of dynamic white-box testing, which have been widely studied and have a variety of testing tools. In aerospace, aviation and other fields that require high reliability, the coverage rate of software dynamic white box testing also puts forward high index requirements.

[0003] At present, there are mainly two common stub insertion methods provided by test tools. One method is to output coverage information to external files. Since embedded software generally does not support file operations, this method is only applicable to non-embedded software; the other One method is to modify the first method, and replace the file output op...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More