CN113157574A - Software real object test coverage rate collection method and device and electronic equipment - Google Patents

Software real object test coverage rate collection method and device and electronic equipment Download PDF

Info

Publication number
CN113157574A
CN113157574A CN202110419900.XA CN202110419900A CN113157574A CN 113157574 A CN113157574 A CN 113157574A CN 202110419900 A CN202110419900 A CN 202110419900A CN 113157574 A CN113157574 A CN 113157574A
Authority
CN
China
Prior art keywords
waveform
real object
software
driving
test
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
Application number
CN202110419900.XA
Other languages
Chinese (zh)
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.)
Shanghai Paixing Information Technology Co Ltd
Original Assignee
Shanghai Paixing Information Technology Co 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 Shanghai Paixing Information Technology Co Ltd filed Critical Shanghai Paixing Information Technology Co Ltd
Priority to CN202110419900.XA priority Critical patent/CN113157574A/en
Publication of CN113157574A publication Critical patent/CN113157574A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3676Test management for coverage analysis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3688Test management for test execution, e.g. scheduling of test suites

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The invention discloses a software real object test coverage rate collecting method and device and electronic equipment. The method comprises the following steps: setting a plurality of real object test cases for the tested software; sampling and storing a real object waveform corresponding to the tested software when each real object test case is executed; converting the real object waveform into a driving waveform capable of driving the tested software; running the driving waveforms and the tested software in a simulation environment, and obtaining the case coverage rate after the running of each driving waveform is finished; and collecting all the use case coverage rates, and acquiring the real object test coverage rate of the tested software. According to the invention, because the coverage rate is collected in the simulation environment, the automation technology and the parallel technology can be fully utilized, a plurality of physical test cases can be run simultaneously, the test efficiency is improved, and the test sufficiency is verified.

Description

Software real object test coverage rate collection method and device and electronic equipment
Technical Field
The invention relates to the technical field of software test verification, in particular to a method and a device for collecting software real object test coverage rate.
Background
In recent years, the application of programmable logic device software in products such as aviation, aerospace, ships, railways and the like is increasing. Programmable logic devices can be configured and programmed by a user through software to perform a particular function, and can be erased and written repeatedly. During modification and upgrade, the hardware design is not required to be additionally changed, and only the program is modified and updated on the computer, so that the hardware design work becomes the software development work, the system design period is shortened, the realization flexibility is improved, and the cost is reduced.
With the higher and higher functional complexity of the programmable logic device software product design, the test and verification of the programmable logic device software becomes a focus of attention. Dynamic testing of programmable logic device software is generally performed by both simulation testing and physical testing. With the increasing software scale of the programmable logic device, statements, branches, conditions, expressions, state machines, overturning and the like which need to be covered in the test are increased in scale, so that the full coverage is more difficult, the efficiency of the simulation test is geometrically reduced, and the test verification quality and the progress plan are difficult to guarantee. Although the physical test is fast, because the programmable logic device software has strong hardware characteristics, and the one-to-one correspondence between the codes and the physical is difficult to trace, the physical test has poor testability, and the coverage rates of statements, branches, conditions, expressions, state machines, inversions and the like cannot be collected, so that the sufficiency of test verification is difficult to explain.
Disclosure of Invention
The invention aims to provide a method and a device for collecting software physical test coverage rate, which can utilize physical test waveform to reversely collect the test coverage rate, improve the test efficiency and verify the test sufficiency.
In order to achieve the aim, the invention provides a software real object test coverage rate collection method, which comprises the following steps: setting a plurality of real object test cases for the tested software; sampling and storing a real object waveform corresponding to the tested software when each real object test case is executed; converting the real object waveform into a driving waveform capable of driving the tested software; running the driving waveforms and the tested software in a simulation environment, and obtaining the case coverage rate after the running of each driving waveform is finished; and collecting all the use case coverage rates, and acquiring the real object test coverage rate of the tested software.
In a further embodiment, during execution of each physical test case, waveforms of input pin signals corresponding to the software to be tested are collected, and corresponding physical waveforms are obtained.
In a further embodiment, the real object waveform is stored as a data file in a custom format.
In a further embodiment, each of the real waveforms is converted into a VCD standard waveform defined by the IEEE standard, and a corresponding driving waveform is obtained.
In a further embodiment, the driving waveforms and the software to be tested are run in a serial manner on a single computer; or running the driving waveform and the tested software on a plurality of computers in a parallel mode.
In a further embodiment, a union of all the use case coverage rates is obtained as a real object test coverage rate of the software to be tested.
In order to achieve the above object, the present invention further provides a device for collecting coverage rate of software real object test, comprising: the case setting unit is used for setting a plurality of real object test cases for the tested software; the waveform sampling storage unit is used for sampling and storing the real object waveform corresponding to the tested software when each real object test case is executed; the waveform conversion unit is used for converting the real object waveform into a driving waveform capable of driving the tested software; the case coverage rate obtaining unit is used for operating the driving waveforms and the tested software in a simulation environment and using the case coverage rate after the operation of each driving waveform is finished; and the coverage rate collection unit is used for collecting all the use case coverage rates and acquiring the real object test coverage rate of the tested software.
In a further embodiment, the waveform sampling storage unit is further configured to, when each physical test case is executed, acquire a waveform of an input pin signal corresponding to the software under test to obtain a corresponding physical waveform, and store the physical waveform as a data file in a custom format.
In a further embodiment, the use case coverage obtaining unit is further configured to: running the driving waveform and the tested software on a single computer in a serial mode; or running the driving waveform and the tested software on a plurality of computers in a parallel mode.
In order to achieve the above object, the present invention also provides an electronic device, including: a processor; and a memory having stored therein computer-executable instructions that, when executed by the processor, cause the steps of the method of the present invention to be performed.
The invention has the beneficial effects that: the method comprises the steps of sampling and storing a real object waveform when a real object test case is executed, processing the real object waveform data, converting the real object waveform data into driving waveform data capable of driving tested software, driving the tested software to run by the driving waveform data in a simulation environment, counting the coverage rate of a single case, and combining to obtain the real object test coverage rate of the tested software. Because the coverage rate is collected in the simulation environment, the automation technology and the parallel technology can be fully utilized, a plurality of physical test cases can be run simultaneously, the test efficiency is improved, and the test sufficiency is verified.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the technical solutions and other advantages of the present invention will be made apparent from the detailed description of specific embodiments of the present invention with reference to the accompanying drawings. It is obvious that the drawings in the following description are only some embodiments of the invention, and that for a person skilled in the art, other drawings can be derived from them without inventive effort.
Fig. 1 is a flowchart of a software physical test coverage rate collection method according to a first embodiment of the present invention;
FIG. 2 is a flowchart of a software physical test coverage collection method according to a second embodiment of the present invention;
fig. 3 is a schematic structural diagram of a software physical test coverage rate collecting device according to a third embodiment of the present invention;
fig. 4 is a schematic structural diagram of an electronic device according to a fourth embodiment of the present invention.
Detailed Description
The technical solution in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. It is to be understood that the described embodiments are merely exemplary of the invention, and not restrictive of the full scope of the invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Reference will now be made in detail to embodiments of the present invention, examples of which are illustrated in the accompanying drawings, wherein like or similar reference numerals refer to the same or similar components or components having the same or similar functions throughout. The terms "first," "second," "third," and the like in the description and in the claims, as well as in the drawings, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. In the description of the present invention, "a plurality" means two or more unless specifically defined otherwise. Furthermore, the terms "comprising" and "having," as well as any variations thereof, are intended to cover a non-exclusive inclusion.
In the description of the present invention, it is to be noted that the terms "connected" and "connected" are to be interpreted broadly unless explicitly defined or limited otherwise. For example, the components may be electrically connected or in communication with each other, directly or indirectly through intervening media, or may be in communication within or interacting with each other. It will be understood that when an element is referred to as being "coupled" to another element, there are intervening elements present. The specific meanings of the above terms in the present invention can be understood by those skilled in the art according to specific situations.
Please refer to fig. 1, which is a flowchart illustrating a software object test coverage collecting method according to a first embodiment of the present invention. As shown in fig. 1, the method for collecting software real object test coverage in this embodiment includes the following steps: step S11, setting a plurality of real object test cases for the tested software; s12, sampling and storing the real object waveform corresponding to the tested software when each real object test case is executed; step S13, converting the real object waveform into a driving waveform capable of driving the tested software; step S14, running the driving waveforms and the tested software in a simulation environment, and obtaining the case coverage rate after the running of each driving waveform is finished; and step S15, collecting all the case coverage rates, and acquiring the real object test coverage rate of the tested software. A detailed description is given below.
In step S11, a plurality of real object test cases are set for the software under test.
Specifically, in this step, the software under test is programmable logic device software. The test cases can be designed by using a causal graph or by using an orthogonal experiment. For example, N physical test cases, case 1, case 2, …, case N (N ≧ 2) may be designed for the software under test. By setting a plurality of physical test cases for the tested software, the test efficiency can be improved and the test sufficiency can be verified by simultaneously operating the physical test cases.
In step S12, the real object waveform corresponding to the software under test is sampled and stored during execution of each real object test case.
In a further embodiment, during execution of each physical test case, waveforms of input pin signals corresponding to the software to be tested are collected to obtain corresponding physical waveforms. Specifically, since the software under test (programmable logic device software) runs on the target chip (programmable logic device), the waveform of the input pin signal on the target chip is acquired. For example, the real waveform 1 is obtained by collecting a waveform corresponding to the execution of example 1, the real waveform 2, … is obtained by collecting a waveform corresponding to the execution of example 2, and the real waveform N is obtained by collecting a waveform corresponding to the execution of example N.
In a further embodiment, the real object waveform is stored as a data file in a custom format.
Regarding step S13, the real object waveform is converted into a driving waveform capable of driving the tested software.
In a further embodiment, each of the real waveforms may be converted into a VCD standard waveform defined by the IEEE standard, so as to obtain a corresponding driving waveform. The vcd (value Change dump) file is an ASCII file defined in IEEE1364 standard (Verilog HDL language standard), and is a common file format. The VCD file mainly contains header information, predefinition of variables, and change information of variables. Since it contains information on the change of the signal, which is equivalent to recording the information of the entire simulation, the simulation can be reproduced with this file, and the waveform can be displayed. Because the VCD is part of the Verilog HDL language standard, all Verilog simulators are able to view this file, allowing the user to dump (dump) the VCD files through system functions in Verilog code.
In a further embodiment, each of the custom-formatted real object waveforms may be separately converted into a driving waveform by programming the waveform to convert to a VCD standard waveform defined by the IEEE standard. For example, the drive waveform 1 is obtained by converting the real waveform 1, the drive waveform 2 is obtained by converting the real waveform 2, … is obtained, and the drive waveform N is obtained by converting the real waveform N.
And step S14, running the driving waveforms and the tested software in a simulation environment, and obtaining the coverage of each case after the driving waveforms are completely run.
Specifically, in this step, the driving waveforms and the software to be tested are run in the simulation software, and the case coverage rate after the completion of the running of each driving waveform is obtained until all the driving waveforms are finished. For example, case coverage 1 is obtained from the running drive waveform 1, case coverage 2, … is obtained from the running drive waveform 2, and case coverage N is obtained from the running drive waveform N.
In a further embodiment, the driving waveform and the software under test can be run in a serial manner on a single computer; the driving waveform and the tested software can be operated on a plurality of computers in a parallel mode. By adopting a parallel mode, the running speed can be increased, and the testing efficiency is improved.
And step S15, collecting all the use case coverage rates, and acquiring a real object test coverage rate of the software to be tested.
In a further embodiment, a union of all the use case coverage rates is obtained as a real object test coverage rate of the software to be tested. And merging all case coverage rates by writing a program, and taking a union set of all case coverage rates to obtain the real object test coverage rate of the tested software. Because a plurality of physical test cases are designed for the tested software, the union set of case coverage rates corresponding to the physical test cases is the physical test coverage rate of the tested software. For example, the case coverage 1 corresponding to the case 1, the case coverage 2 and … corresponding to the case 2, and the case coverage N corresponding to the case N are combined to obtain the real test coverage of the software under test.
According to the method for collecting the real object test coverage rate of the software, the real object waveform when the real object test case is executed is sampled and stored, then the real object waveform data is processed and converted into driving waveform data capable of driving the tested software, the driving waveform data is used for driving the tested software to run in a simulation environment, then the coverage rate of a single case is counted, and the real object test coverage rate of the tested software is obtained through combination. Because the coverage rate is collected in the simulation environment, the automation technology and the parallel technology can be fully utilized, a plurality of physical test cases can be run simultaneously, the test efficiency is improved, and the test sufficiency is verified.
Please refer to fig. 2, which is a flowchart illustrating a software object test coverage collecting method according to a second embodiment of the present invention.
As shown in fig. 2, the working flow of the software physical test coverage rate collecting method according to this embodiment is as follows: (1) designing N physical test cases, namely case 1, case 2, … and case N (N is more than or equal to 2), aiming at the tested software; (2) acquiring a corresponding waveform when the case 1 is executed to obtain a real object waveform 1, acquiring a corresponding waveform when the case 2 is executed to obtain a real object waveform 2, …, and acquiring a corresponding waveform when the case N is executed to obtain a real object waveform N; (3) converting the real object waveform 1 to obtain a driving waveform 1, converting the real object waveform 2 to obtain a driving waveform 2, …, and converting the real object waveform N to obtain a driving waveform N; (4) running the driving waveform and the tested software on N computers in a parallel mode; acquiring a use case coverage rate 1 according to the running driving waveform 1, acquiring a use case coverage rate 2, … according to the running driving waveform 2, and acquiring a use case coverage rate N according to the running driving waveform N; (5) and combining the coverage rates of all the use cases, and taking a union set of the coverage rates of all the use cases to obtain the real object test coverage rate of the tested software.
According to the method for collecting the coverage rate of the software physical test, the coverage rate is collected in the simulation environment, the driving waveform and the tested software are operated on the plurality of computers in a parallel mode, the automation technology and the parallel technology can be fully utilized, the plurality of physical test cases are operated simultaneously, the operation speed can be increased, the test efficiency is improved, and the test sufficiency is verified.
Based on the same inventive concept, the invention also provides a software real object test coverage rate collecting device.
Please refer to fig. 3, which is a schematic structural diagram of a device for collecting coverage rate of a software physical test according to a third embodiment of the present invention. As shown in fig. 3, the software physical test coverage collecting device 30 according to this embodiment includes: a use case setting unit 31, a waveform sample storage unit 32, a waveform conversion unit 33, a use case coverage acquisition unit 34, and a coverage collection unit 35.
Specifically, the use case setting unit 31 is configured to set a plurality of real test use cases for the software to be tested; the waveform sampling storage unit 32 is used for sampling and storing the real object waveform corresponding to the tested software when each real object test case is executed; the waveform conversion unit 33 is configured to convert the real object waveform into a driving waveform that can drive the tested software; the use case coverage rate obtaining unit 34 is configured to run the driving waveforms and the software to be tested in a simulation environment, and use the use case coverage rate after each driving waveform is run; the coverage rate collecting unit 35 is configured to collect all the use case coverage rates, and obtain a real object test coverage rate of the software to be tested. Specifically, the software under test is programmable logic device software.
In a further embodiment, the use case setting unit 31 may design the test use case by using a causal graph, or by using an orthogonal experiment. For example, N physical test cases, case 1, case 2, …, case N (N ≧ 2) may be designed for the software under test. By setting a plurality of physical test cases for the tested software, the test efficiency can be improved and the test sufficiency can be verified by simultaneously operating the physical test cases.
In a further embodiment, the waveform sampling storage unit 32 may be configured to, when each physical test case is executed, acquire a waveform of an input pin signal corresponding to the software to be tested, obtain a corresponding physical waveform, and store the physical waveform as a data file in a custom format. Specifically, because the software to be tested (programmable logic device software) runs on the target chip (programmable logic device), the waveform of the input pin signal on the target chip is collected and stored as a data file in a custom format. For example, the real waveform 1 is obtained by collecting a waveform corresponding to the execution of example 1, the real waveform 2, … is obtained by collecting a waveform corresponding to the execution of example 2, and the real waveform N is obtained by collecting a waveform corresponding to the execution of example N.
In a further embodiment, the waveform converting unit 33 may convert each of the real waveforms into a VCD standard waveform defined by the IEEE standard to obtain a corresponding driving waveform. Specifically, the waveform conversion unit 33 can convert the real object waveform in the custom format into a VCD standard waveform defined by the IEEE standard by writing a program, thereby individually converting each real object waveform into one driving waveform. For example, the drive waveform 1 is obtained by converting the real waveform 1, the drive waveform 2 is obtained by converting the real waveform 2, … is obtained, and the drive waveform N is obtained by converting the real waveform N.
In a further embodiment, the use case coverage rate obtaining unit 34 may operate the driving waveform and the tested software in a serial manner on a single computer, or may operate the driving waveform and the tested software in a parallel manner on a plurality of computers. By adopting a parallel mode, the running speed can be increased, and the testing efficiency is improved. Specifically, the use-case coverage rate obtaining unit 34 runs the driving waveforms and the software to be tested in the simulation software, and obtains the use-case coverage rate after the completion of the running of each driving waveform until all the driving waveforms are completed. For example, case coverage 1 is obtained from the running drive waveform 1, case coverage 2, … is obtained from the running drive waveform 2, and case coverage N is obtained from the running drive waveform N.
In a further embodiment, the coverage collecting unit 35 obtains a union of all the use case coverage as a real test coverage of the software under test. The coverage rate collection unit 35 may combine all the use case coverage rates by writing a program, and obtain a union of all the use case coverage rates to obtain the physical test coverage rate of the software to be tested. Because a plurality of physical test cases are designed for the tested software, the union set of case coverage rates corresponding to the physical test cases is the physical test coverage rate of the tested software. For example, the case coverage 1 corresponding to the case 1, the case coverage 2 and … corresponding to the case 2, and the case coverage N corresponding to the case N are combined to obtain the real test coverage of the software under test.
It should be noted that some of the block diagrams shown in the figures are functional entities and do not necessarily correspond to physically or logically separate entities. These functional entities may be implemented in the form of software, or in one or more hardware circuits or integrated circuits, or in different networks and/or processor means and/or microcontroller means. Meanwhile, in some cases, reference may be made to the foregoing embodiments.
The software real object test coverage rate collecting device provided by the embodiment samples and stores a real object waveform when a real object test case is executed, processes real object waveform data, converts the real object waveform data into driving waveform data capable of driving tested software, drives the tested software to run by using the driving waveform data in a simulation environment, counts the coverage rate of a single case, and combines the coverage rates to obtain the real object test coverage rate of the tested software. Because the coverage rate is collected in the simulation environment, the automation technology and the parallel technology can be fully utilized, a plurality of physical test cases can be run simultaneously, the test efficiency is improved, and the test sufficiency is verified.
Based on the same inventive concept, the invention also provides electronic equipment. The electronic device can be a PC client, a server and the like.
Please refer to fig. 4, which is a schematic structural diagram of an electronic device according to a fourth embodiment of the present invention. The electronic device 40 comprises a processor 401 and a memory 402. The processor 401 is electrically connected to the memory 402.
The processor 401 is a control center of the electronic device 40, connects various parts of the whole electronic device by using various interfaces and lines, and executes various functions and processes data of the electronic device by running or loading an application program stored in the memory 402 and calling the data stored in the memory 402, thereby performing overall monitoring of the electronic device.
The memory 402 is used to store computer-executable instructions; the computer executable instructions, when executed by the processor 401, cause the steps of the method as previously described in the present invention to be performed.
The methods described in embodiments of the present invention may be implemented using computer systems or architectures known to those skilled in the relevant art. Computer systems, such as PDAs, smart phones, palmtops, servers, clients, or any other type of special or general purpose electronic device may be used as may be suitable or appropriate for a particular application or environment. The computer system may include one or more processors, which may be implemented using a general or special purpose processing engine such as, for example, a microprocessor, microcontroller or other control processing module.
The computer system may also include a main memory, such as a random access memory or other dynamic memory, for storing information and instructions to be executed by the processor. Such main memory may also be used for storing temporary variables or other intermediate information during execution of instructions to be executed by the processor. The computer system may also include a read only memory or other static storage device for the processor that stores static information and processor instructions.
The computer system may also include an information storage system, which may include, for example, a media drive and a removable storage interface. The media drive may include a drive or other mechanism to support fixed or removable storage media, such as a hard disk drive, a floppy disk drive, a magnetic tape drive, an optical disk, a digital video drive, a read or write drive, other removable or fixed media drive. For example, the storage media may include, for example, a hard disk, floppy disk, magnetic tape, optical disk, CD or DVD, or other fixed or removable medium that is read by and written to by the media drive. The storage media may include a computer-readable storage medium having stored therein particular computer software or data.
The computer system may also include a communications interface. Such a communication interface may be used to allow software and data to be transferred between the computer system and external devices. In this embodiment, the communication interface may include a modem, a network interface (e.g., an Ethernet or other NIC card), a communication port (e.g., a USB port), a PCMCIA slot and card, or the like. Software and data transferred via the communications interface are in the form of signals which may be electronic, electromagnetic, optical or other signals capable of being received by the communications interface medium.
In this document, the terms "computer-executable instructions," "computer-readable medium," and the like may be used generally to refer to a tangible medium, such as a memory, a storage device, or a storage unit. These and other forms of computer-readable media may store one or more instructions for use by a processor, including a computer system, to cause the processor to perform specified operations. These instructions, generally referred to as "computer program code" (which may be combined in the form of a computer program or other combinations) when executed, cause a computer system to perform the functions of embodiments of the present invention. Note that the code may directly cause the processor to perform certain operations, be compiled to do so, and/or be combined with other software, hardware, and/or firmware (e.g., libraries that perform standard functions) to do so.
In embodiments where the elements are implemented using software, the software may be stored on a computer-readable medium and loaded into a computer system using, for example, a removable storage drive. When executed by a processor in a computer system, the control module (in this example, software instructions or computer-executable program code) causes the processor to perform the functions of the invention as described herein.
It will be appreciated that for clarity purposes, embodiments of the invention have been described above with reference to a single processing logic. However, the inventive concept may equally be implemented by means of a plurality of different functional units and processors to provide the signal processing functions. Thus, references to specific functional units are only to be seen as references to suitable means for providing the described functionality rather than indicative of a strict logical or physical structure or organization.
Aspects of the invention may be implemented in any suitable form including hardware, software, firmware or any combination of these. Alternatively, the invention may be implemented at least partly as computer software running on one or more data processors and/or digital signal processors or configurable modular components such as FPGA devices. Thus, the elements and components of an embodiment of the invention may be physically, functionally and logically implemented in any suitable way. Indeed the functionality may be implemented in a single unit, in a plurality of units or as part of other functional units.
The above description of the embodiments is only for helping understanding the technical solution of the present invention and its core idea; those of ordinary skill in the art will understand that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.

Claims (10)

1. A software real object test coverage rate collection method is characterized by comprising the following steps:
setting a plurality of real object test cases for the tested software;
sampling and storing a real object waveform corresponding to the tested software when each real object test case is executed;
converting the real object waveform into a driving waveform capable of driving the tested software;
running the driving waveforms and the tested software in a simulation environment, and obtaining the case coverage rate after the running of each driving waveform is finished;
and collecting all the use case coverage rates, and acquiring the real object test coverage rate of the tested software.
2. The method of claim 1, wherein sampling and storing the real object waveform corresponding to the software under test during execution of each real object test case further comprises:
and when each real object test case is executed, acquiring the waveform of an input pin signal corresponding to the tested software to obtain a corresponding real object waveform.
3. The method of claim 1, wherein the real object waveforms are stored as custom formatted data files.
4. The method of claim 1, wherein the step of converting the real-world waveform into a driving waveform capable of driving the software under test further comprises:
and converting each real object waveform into a VCD standard waveform defined by the IEEE standard to obtain a corresponding driving waveform.
5. The method of claim 1, wherein the step of running the driving waveforms and the software under test in a simulated environment further comprises:
running the driving waveform and the tested software on a single computer in a serial mode; or
And running the driving waveform and the tested software on a plurality of computers in a parallel mode.
6. The method according to claim 1, wherein the step of collecting all the use case coverage rates and obtaining the real object test coverage rate of the software under test further comprises:
and acquiring a union of all the use case coverage rates as a real object test coverage rate of the tested software.
7. A software real object test coverage rate collecting device is characterized by comprising:
the case setting unit is used for setting a plurality of real object test cases for the tested software;
the waveform sampling storage unit is used for sampling and storing the real object waveform corresponding to the tested software when each real object test case is executed;
the waveform conversion unit is used for converting the real object waveform into a driving waveform capable of driving the tested software;
the case coverage rate obtaining unit is used for operating the driving waveforms and the tested software in a simulation environment and using the case coverage rate after the operation of each driving waveform is finished;
and the coverage rate collection unit is used for collecting all the use case coverage rates and acquiring the real object test coverage rate of the tested software.
8. The apparatus of claim 7, wherein the waveform sample storage unit is further configured to:
and when each real object test case is executed, acquiring the waveform of an input pin signal corresponding to the tested software to obtain a corresponding real object waveform, and storing the real object waveform as a data file with a custom format.
9. The apparatus of claim 7, wherein the use case coverage obtaining unit is further configured to:
running the driving waveform and the tested software on a single computer in a serial mode; or
And running the driving waveform and the tested software on a plurality of computers in a parallel mode.
10. An electronic device, characterized in that the electronic device comprises:
a processor; and
memory having stored therein computer-executable instructions that, when executed by the processor, cause the steps of the method of any one of claims 1 to 6 to be performed.
CN202110419900.XA 2021-04-19 2021-04-19 Software real object test coverage rate collection method and device and electronic equipment Pending CN113157574A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110419900.XA CN113157574A (en) 2021-04-19 2021-04-19 Software real object test coverage rate collection method and device and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110419900.XA CN113157574A (en) 2021-04-19 2021-04-19 Software real object test coverage rate collection method and device and electronic equipment

Publications (1)

Publication Number Publication Date
CN113157574A true CN113157574A (en) 2021-07-23

Family

ID=76868698

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110419900.XA Pending CN113157574A (en) 2021-04-19 2021-04-19 Software real object test coverage rate collection method and device and electronic equipment

Country Status (1)

Country Link
CN (1) CN113157574A (en)

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104063321A (en) * 2014-06-27 2014-09-24 北京控制工程研究所 Test verifying system and test verifying method for microblaze soft-core program
CN104198786A (en) * 2014-09-11 2014-12-10 东华大学 Method for simulating waveform measured by logic analyzer by utilizing single chip microcomputer model
CN107797929A (en) * 2017-10-26 2018-03-13 北京广利核系统工程有限公司 The statistical method and device of FPGA emulation testing function coverage
CN108197026A (en) * 2017-12-30 2018-06-22 北京金风科创风电设备有限公司 Method, device and equipment for testing simulation software of wind generating set and storage medium
CN109726507A (en) * 2019-01-17 2019-05-07 湖南进芯电子科技有限公司 A kind of efficiently multi-functional verification platform and method
CN110968507A (en) * 2019-11-20 2020-04-07 北京创鑫旅程网络技术有限公司 Coverage rate statistical method and device
CN112417461A (en) * 2020-12-07 2021-02-26 北京梆梆安全科技有限公司 Fuzzy test method and system for equipment firmware

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104063321A (en) * 2014-06-27 2014-09-24 北京控制工程研究所 Test verifying system and test verifying method for microblaze soft-core program
CN104198786A (en) * 2014-09-11 2014-12-10 东华大学 Method for simulating waveform measured by logic analyzer by utilizing single chip microcomputer model
CN107797929A (en) * 2017-10-26 2018-03-13 北京广利核系统工程有限公司 The statistical method and device of FPGA emulation testing function coverage
CN108197026A (en) * 2017-12-30 2018-06-22 北京金风科创风电设备有限公司 Method, device and equipment for testing simulation software of wind generating set and storage medium
CN109726507A (en) * 2019-01-17 2019-05-07 湖南进芯电子科技有限公司 A kind of efficiently multi-functional verification platform and method
CN110968507A (en) * 2019-11-20 2020-04-07 北京创鑫旅程网络技术有限公司 Coverage rate statistical method and device
CN112417461A (en) * 2020-12-07 2021-02-26 北京梆梆安全科技有限公司 Fuzzy test method and system for equipment firmware

Similar Documents

Publication Publication Date Title
US10288681B2 (en) Test architecture with a small form factor test board for rapid prototyping
US12001317B2 (en) Waveform based reconstruction for emulation
CN110502374A (en) The traffic capture debugging tool of the basic reason of equipment fault when identification is tested automatically
US20110154110A1 (en) Verifying a Register-Transfer Level Design of an Execution Unit
CN112100957B (en) Method, emulator, storage medium for debugging a logic system design
CN110989926A (en) Fault disk slot positioning method and device and electronic equipment
US20070043548A1 (en) Verifying a simulated hardware environment for a simulated device under test
US6339837B1 (en) Hybrid method for design verification
CN112286750A (en) GPIO (general purpose input/output) verification method and device, electronic equipment and medium
CN110134598B (en) Batch processing method, device and system
CN117076337B (en) Data transmission method and device, electronic equipment and readable storage medium
CN117350208A (en) Method and apparatus for checking performance of sequential logic element
CN113849419A (en) Method, system, equipment and storage medium for generating test vector of chip
CN116663490A (en) Verification method, platform, device and medium of asynchronous memory chip
CN113157574A (en) Software real object test coverage rate collection method and device and electronic equipment
CN112395144A (en) Test method, test system, terminal equipment and readable storage medium
CN115422143A (en) Method, system, storage medium and terminal for converting oscilloscope file into MDA file format
US20030025490A1 (en) Method for verifying hardware circuits through simulation
CN110688289B (en) Processor performance event dynamic monitoring method based on simulation
CN114756463A (en) Test environment development method, system, equipment and medium
CN114610549A (en) Serial port flash memory chip test system and test method
CN117112447B (en) Data transmission method and device, electronic equipment and readable storage medium
CN115616387B (en) Control signal calibration method and system based on chip
CN116578449A (en) Test equipment supporting hot standby and recovery in chip verification and related method
CN117194198A (en) IO performance test method, system, terminal and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination