Chip verification method, terminal device, verification platform and storage medium
1. A chip verification method, for a terminal device, the method comprising the steps of:
creating a target test case based on the target verification plan;
sending the target test case to a Field Programmable Gate Array (FPGA) testing device so that the FPGA testing device tests a chip to be tested in the FPGA testing device by using the target test case to obtain test data;
acquiring the test data from the FPGA test device;
sending the test data to a verification platform so that the verification platform obtains the functional coverage rate of the chip to be tested based on the test data;
and obtaining a verification result of the chip to be tested based on the received function coverage rate returned by the verification platform.
2. The method of claim 1, wherein the step of sending the target test case to a Field Programmable Gate Array (FPGA) test device to enable the FPGA test device to test a chip to be tested in the FPGA test device by using the target test case to obtain test data comprises:
sending the target test case to a Field Programmable Gate Array (FPGA) testing device so that the FPGA testing device tests a chip to be tested in the FPGA testing device by using the target test case, collects the test data in the testing process and generates a test file by using the test data;
the step of obtaining the test data from the FPGA testing device includes:
and acquiring the test file from the FPGA test device, and extracting the test data from the test file.
3. The method of claim 2, wherein prior to the step of obtaining the test file from the FPGA testing device, the method further comprises:
receiving feedback information sent by the FPGA testing device;
the step of obtaining the test data from the FPGA testing device includes:
and when the feedback information is that the test of the chip to be tested is successful, obtaining the test file from the FPGA test device.
4. The method of claim 3, wherein after the step of receiving the feedback information sent by the FPGA test device, the method further comprises:
when the feedback information is that the test of the chip to be tested fails, obtaining test process information from the FPGA test device;
modifying the target verification plan by using the test process information to obtain a modified verification plan;
creating a new target test case by using the modified verification plan and the target test case;
and updating the target test case by using the new target test case, and returning to execute the step of sending the target test case to a Field Programmable Gate Array (FPGA) test device until the feedback information indicates that the test of the chip to be tested is successful, and continuing to execute the step of obtaining the test file from the FPGA test device.
5. A method for verifying a chip, for verifying a platform, the method comprising the steps of:
receiving test data sent by terminal equipment, wherein the test data is obtained by the terminal equipment from a Field Programmable Gate Array (FPGA) test device, the test data is obtained by testing a chip to be tested in the FPGA test device by utilizing a target test case sent by the terminal equipment, and the target test case is created based on a target verification plan;
obtaining the functional coverage rate of the chip to be tested based on the test data;
and sending the function coverage rate to the terminal equipment so that the terminal equipment obtains a verification result of the chip to be tested based on the function coverage rate.
6. The method of claim 5, wherein the verification platform is an EDA verification platform; before the step of obtaining the functional coverage of the chip to be tested based on the test data, the method further includes:
creating a functional coverage model based on the target verification plan;
the step of obtaining the functional coverage rate of the chip to be tested based on the test data comprises the following steps:
and obtaining the functional coverage rate based on the test data and the functional coverage rate model.
7. The method of claim 6, wherein the step of obtaining the functional coverage based on the test data and the functional coverage model comprises:
extracting the value of the real coverage point in the chip to be detected from the test data;
assigning a value to the simulation coverage point in the functional coverage rate model by using the value of the real coverage point;
and sampling the assigned simulation coverage points by using an objective function to obtain the functional coverage rate.
8. The method of claim 7, wherein the objective function is a sample function in the EAD validation platform.
9. A terminal device, characterized in that the terminal device comprises: memory, a processor and a chip authentication program stored on the memory and running on the processor, the chip authentication program when executed by the processor implementing the steps of the chip authentication method according to any one of claims 1 to 4.
10. A verification platform, comprising: memory, a processor and a chip authentication program stored on the memory and running on the processor, the chip authentication program when executed by the processor implementing the steps of the chip authentication method according to any one of claims 5 to 8.
11. A computer-readable storage medium, having stored thereon a chip authentication program, which when executed by a processor implements the steps of the chip authentication method according to any one of claims 1 to 8.
Background
The prototype verification by using FPGA (Field Programmable Gate Array) is an important ring in chip verification, for example: the FPGA is used for testing large flow for a long time, and the FPGA is used for butt joint testing with equipment of various manufacturers.
In the existing verification method, the FPGA is used for verifying the chip to be verified, and technicians manually record parameters in the verification process, so that the operation of the chip verification process is complex, and the chip verification efficiency is low.
Disclosure of Invention
The invention mainly aims to provide a chip verification method, terminal equipment, a verification platform and a storage medium, and aims to solve the technical problems that in the prior art, the operation of a chip verification process is complex, and the chip verification efficiency is low.
In order to achieve the above object, the present invention provides a chip verification method for a terminal device, the method comprising the steps of:
creating a target test case based on the target verification plan;
sending the target test case to a Field Programmable Gate Array (FPGA) testing device so that the FPGA testing device tests a chip to be tested in the FPGA testing device by using the target test case to obtain test data;
acquiring the test data from the FPGA test device;
sending the test data to a verification platform so that the verification platform obtains the functional coverage rate of the chip to be tested based on the test data;
and obtaining a verification result of the chip to be tested based on the received function coverage rate returned by the verification platform.
Optionally, the step of sending the target test case to a field programmable gate array FPGA testing apparatus to enable the FPGA testing apparatus to test a chip to be tested in the FPGA testing apparatus by using the target test case to obtain test data includes:
sending the target test case to a Field Programmable Gate Array (FPGA) testing device so that the FPGA testing device tests a chip to be tested in the FPGA testing device by using the target test case, collects the test data in the testing process and generates a test file by using the test data;
the step of obtaining the test data from the FPGA testing device includes:
and acquiring the test file from the FPGA test device, and extracting the test data from the test file.
Optionally, before the step of obtaining the test file from the FPGA testing device, the method further includes:
receiving feedback information sent by the FPGA testing device;
the step of obtaining the test data from the FPGA testing device includes:
and when the feedback information is that the test of the chip to be tested is successful, obtaining the test file from the FPGA test device.
Optionally, after the step of receiving the feedback information sent by the FPGA testing apparatus, the method further includes:
when the feedback information is that the test of the chip to be tested fails, obtaining test process information from the FPGA test device;
modifying the target verification plan by using the test process information to obtain a modified verification plan;
creating a new target test case by using the modified verification plan and the target test case;
and updating the target test case by using the new target test case, and returning to execute the step of sending the target test case to a Field Programmable Gate Array (FPGA) test device until the feedback information indicates that the test of the chip to be tested is successful, and continuing to execute the step of obtaining the test file from the FPGA test device.
In addition, in order to achieve the above object, the present invention further provides a chip verification method for verifying a platform, the method comprising the steps of:
receiving test data sent by terminal equipment, wherein the test data is obtained by the terminal equipment from a Field Programmable Gate Array (FPGA) test device, the test data is obtained by testing a chip to be tested in the FPGA test device by utilizing a target test case sent by the terminal equipment, and the target test case is created based on a target verification plan;
obtaining the functional coverage rate of the chip to be tested based on the test data;
and sending the function coverage rate to the terminal equipment so that the terminal equipment obtains a verification result of the chip to be tested based on the function coverage rate.
Optionally, the verification platform is an EDA verification platform; before the step of obtaining the functional coverage of the chip to be tested based on the test data, the method further includes:
creating a functional coverage model based on the target verification plan;
the step of obtaining the functional coverage rate of the chip to be tested based on the test data comprises the following steps:
and obtaining the functional coverage rate based on the test data and the functional coverage rate model.
Optionally, the step of obtaining the functional coverage based on the test data and the functional coverage model includes:
extracting the value of the real coverage point in the chip to be detected from the test data;
assigning a value to the simulation coverage point in the functional coverage rate model by using the value of the real coverage point;
and sampling the assigned simulation coverage points by using an objective function to obtain the functional coverage rate.
Optionally, the objective function is a sample function in the EAD verification platform.
In addition, to achieve the above object, the present invention further provides a terminal device, including: the chip verification method comprises a memory, a processor and a chip verification program stored on the memory and running on the processor, wherein the chip verification program realizes the steps of the chip verification method according to any one of the above items when being executed by the processor.
In addition, to achieve the above object, the present invention further provides a verification platform, including: the chip verification method comprises a memory, a processor and a chip verification program stored on the memory and running on the processor, wherein the chip verification program realizes the steps of the chip verification method according to any one of the above items when being executed by the processor.
Furthermore, to achieve the above object, the present invention further provides a computer-readable storage medium having a chip verification program stored thereon, wherein the chip verification program, when executed by a processor, implements the steps of the chip verification method according to any one of the above items.
The technical scheme of the invention provides a chip verification method for terminal equipment, which comprises the following steps: creating a target test case based on the target verification plan; sending the target test case to a Field Programmable Gate Array (FPGA) testing device so that the FPGA testing device tests a chip to be tested in the FPGA testing device by using the target test case to obtain test data; acquiring the test data from the FPGA test device; sending the test data to a verification platform so that the verification platform obtains the functional coverage rate of the chip to be tested based on the test data; and obtaining a verification result of the chip to be tested based on the received function coverage rate returned by the verification platform.
In the existing verification method, the FPGA testing device cannot obtain the functional coverage of the chip to be tested, and a technician needs to manually record the parameters in the verification process and manually analyze the recorded parameters to obtain the functional coverage, so that the operation of the chip verification process is complicated, and the chip verification efficiency is low. In the application, the terminal equipment automatically acquires the test data from the FPGA test device, and the test data is automatically analyzed by the verification platform to obtain the function coverage rate, so that a technician does not need to manually participate in the acquisition process of the function coverage rate, the operation of the chip verification process is simple, and the chip verification efficiency is high. Therefore, the chip verification method achieves the technical effect of improving the chip verification efficiency.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the structures shown in the drawings without creative efforts.
Fig. 1 is a schematic structural diagram of a terminal device in a hardware operating environment according to an embodiment of the present invention;
FIG. 2 is a schematic diagram of a verification platform structure of a hardware operating environment according to an embodiment of the present invention
FIG. 3 is a flowchart illustrating a first embodiment of a chip verification method according to the present invention;
FIG. 4 is a schematic structural diagram of a first embodiment of a chip to be tested according to the present invention;
FIG. 5 is a schematic structural diagram of a FPGA test apparatus according to a first embodiment of the present invention;
FIG. 6 is a flowchart illustrating a second embodiment of a chip verification method according to the present invention;
FIG. 7 is a block diagram of a first embodiment of a chip verification apparatus according to the present invention;
FIG. 8 is a block diagram of a second embodiment of a chip verification apparatus according to the present invention; .
The implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. 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.
Referring to fig. 1, fig. 1 is a schematic structural diagram of a terminal device in a hardware operating environment according to an embodiment of the present invention.
In general, a terminal device includes: at least one processor 301, a memory 302, and a chip verification program stored on the memory and executable on the processor, the chip verification program being configured to implement the steps of the chip verification method as described previously.
The processor 301 may include one or more processing cores, such as a 4-core processor, an 8-core processor, and so on. The processor 301 may be implemented in at least one hardware form of a DSP (Digital Signal Processing), an FPGA (Field-Programmable Gate Array), and a PLA (Programmable Logic Array). The processor 301 may also include a main processor and a coprocessor, where the main processor is a processor for processing data in an awake state, and is also called a Central Processing Unit (CPU); a coprocessor is a low power processor for processing data in a standby state. In some embodiments, the processor 301 may be integrated with a GPU (Graphics Processing Unit), which is responsible for rendering and drawing the content required to be displayed on the display screen. The processor 301 may further include an AI (Artificial Intelligence) processor for processing operations related to the chip verification method, so that the chip verification method model can be trained and learned autonomously, thereby improving efficiency and accuracy.
Memory 302 may include one or more computer-readable storage media, which may be non-transitory. Memory 302 may also include high speed random access memory, as well as non-volatile memory, such as one or more magnetic disk storage devices, flash memory storage devices. In some embodiments, a non-transitory computer readable storage medium in the memory 302 is used to store at least one instruction for execution by the processor 301 to implement the chip verification method provided by the method embodiments herein.
In some embodiments, the terminal may further include: a communication interface 303 and at least one peripheral device. The processor 301, the memory 302 and the communication interface 303 may be connected by a bus or signal lines. Various peripheral devices may be connected to communication interface 303 via a bus, signal line, or circuit board. Specifically, the peripheral device includes: at least one of radio frequency circuitry 304, a display screen 305, and a power source 306.
The communication interface 303 may be used to connect at least one peripheral device related to I/O (Input/Output) to the processor 301 and the memory 302. In some embodiments, processor 301, memory 302, and communication interface 303 are integrated on the same chip or circuit board; in some other embodiments, any one or two of the processor 301, the memory 302 and the communication interface 303 may be implemented on a single chip or circuit board, which is not limited in this embodiment.
The Radio Frequency circuit 304 is used for receiving and transmitting RF (Radio Frequency) signals, also called electromagnetic signals. The radio frequency circuitry 304 communicates with communication networks and other communication devices via electromagnetic signals. The rf circuit 304 converts an electrical signal into an electromagnetic signal to transmit, or converts a received electromagnetic signal into an electrical signal. Optionally, the radio frequency circuit 304 comprises: an antenna system, an RF transceiver, one or more amplifiers, a tuner, an oscillator, a digital signal processor, a codec chipset, a subscriber identity module card, and so forth. The radio frequency circuitry 304 may communicate with other terminals via at least one wireless communication protocol. The wireless communication protocols include, but are not limited to: metropolitan area networks, various generation mobile communication networks (2G, 3G, 4G, and 5G), Wireless local area networks, and/or WiFi (Wireless Fidelity) networks. In some embodiments, the rf circuit 304 may further include NFC (Near Field Communication) related circuits, which are not limited in this application.
The display screen 305 is used to display a UI (User Interface). The UI may include graphics, text, icons, video, and any combination thereof. When the display screen 305 is a touch display screen, the display screen 305 also has the ability to capture touch signals on or over the surface of the display screen 305. The touch signal may be input to the processor 301 as a control signal for processing. At this point, the display screen 305 may also be used to provide virtual buttons and/or a virtual keyboard, also referred to as soft buttons and/or a soft keyboard. In some embodiments, the display screen 305 may be one, the front panel of the electronic device; in other embodiments, the display screens 305 may be at least two, respectively disposed on different surfaces of the electronic device or in a folded design; in still other embodiments, the display screen 305 may be a flexible display screen disposed on a curved surface or a folded surface of the electronic device. Even further, the display screen 305 may be arranged in a non-rectangular irregular figure, i.e. a shaped screen. The Display screen 305 may be made of LCD (liquid crystal Display), OLED (Organic Light-Emitting Diode), and the like.
The power supply 306 is used to power various components in the electronic device. The power source 306 may be alternating current, direct current, disposable or rechargeable. When the power source 306 includes a rechargeable battery, the rechargeable battery may support wired or wireless charging. The rechargeable battery may also be used to support fast charge technology.
Those skilled in the art will appreciate that the configuration shown in fig. 1 does not constitute a limitation of the terminal device and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components.
Referring to fig. 2, fig. 2 is a schematic diagram of a verification platform structure of a hardware operating environment according to an embodiment of the present invention.
The authentication platform includes a Central Processing Unit (CPU)401, a system memory 404 including a Random Access Memory (RAM)402 and a Read Only Memory (ROM)403, and a system bus 405 connecting the system memory 404 and the central processing unit 401. The verification platform also includes a basic input/output system (I/O system) 406, which facilitates the transfer of information between various devices within the computer, and a mass storage device 407 for storing an operating system 413, application programs 414, and other program modules 415.
The basic input/output system 406 includes a display 408 for displaying information and an input device 409 such as a mouse, keyboard, etc. for user input of information. Wherein the display 408 and the input device 409 are connected to the central processing unit 401 through an input output controller 410 connected to the system bus 405. The basic input/output system 406 may also include an input/output controller 410 for receiving and processing input from a number of other devices, such as a keyboard, mouse, or electronic stylus. Similarly, input/output controller 410 may also provide output to a display screen, a printer, or other type of output device.
The mass storage device 407 is connected to the central processing unit 401 through a mass storage controller connected to the system bus 405. The mass storage device 407 and its associated computer-readable media provide non-volatile storage for the authentication platform. That is, the mass storage device 407 may include a computer-readable medium such as a hard disk or CD-ROM drive.
Without loss of generality, the computer-readable media may comprise computer storage media and communication media. Computer storage media includes volatile and nonvolatile, removable and non-removable media implemented in any method or technology for storage of information such as computer readable instructions, data structures, program modules or other data. Computer storage media includes RAM, ROM, EPROM, EEPROM, flash memory or other solid state memory technology, CD-ROM, DVD, or other optical storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices. Of course, those skilled in the art will appreciate that the computer storage media is not limited to the foregoing.
The system memory 404 and mass storage device 407 described above may be collectively referred to as memory.
According to various embodiments of the present application, the verification platform may also operate with a remote computer connected to a network via a network, such as the Internet. That is, the authentication platform may be connected to the network 412 through the network interface unit 411 connected to the system bus 405, or may be connected to other types of networks or remote computer systems using the network interface unit 411.
Furthermore, an embodiment of the present invention further provides a computer-readable storage medium, where a chip verification program is stored on the computer-readable storage medium, and the chip verification program, when executed by a processor, implements the steps of the chip verification method described above. Therefore, a detailed description thereof will be omitted. In addition, the beneficial effects of the same method are not described in detail. For technical details not disclosed in embodiments of the computer-readable storage medium referred to in the present application, reference is made to the description of embodiments of the method of the present application. Determining by way of example, the program instructions may be deployed to be executed on one terminal device and one verification platform, or on multiple terminal devices and multiple verification platforms located at one site, or on multiple terminal devices and multiple verification platforms distributed across multiple sites and interconnected by a communication network.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by a computer program, which can be stored in a computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. The computer-readable storage medium may be a magnetic disk, an optical disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), or the like.
Based on the hardware structure, the embodiment of the chip verification method is provided.
Referring to fig. 3, fig. 3 is a schematic flowchart of a first embodiment of a chip verification method according to the present invention, where the method is used for a terminal device, and the method includes the following steps:
step S11: and creating a target test case based on the target verification plan.
It should be noted that the execution main body of the present invention is a terminal device and a verification platform, the terminal device is installed with a corresponding chip verification program, and the verification platform is installed with a corresponding chip verification program. And when the terminal equipment and the verification platform respectively execute corresponding chip verification programs, the steps of the chip verification method are realized.
Specifically, a test case, i.e., the target test case, for verifying the chip to be tested may be created according to a verification plan set by the user, i.e., the target verification plan. The verification plans are different, the created test cases are possibly different, and a user can set the corresponding verification plan based on requirements to create the corresponding test case.
Step S12: and sending the target test case to a Field Programmable Gate Array (FPGA) testing device so that the FPGA testing device tests a chip to be tested in the FPGA testing device by using the target test case to obtain test data.
It should be noted that after the terminal device obtains the target test case, the target test case needs to be sent to the FPGA testing device, and the FPGA testing device executes the target test case, so as to test the chip to be tested.
Further, the step of sending the target test case to a field programmable gate array FPGA testing device to enable the FPGA testing device to test a chip to be tested in the FPGA testing device by using the target test case to obtain test data includes: and sending the target test case to a Field Programmable Gate Array (FPGA) testing device so that the FPGA testing device tests a chip to be tested in the FPGA testing device by using the target test case, collects the test data in the testing process and generates a test file by using the test data.
In the process that the chip to be tested is tested, the signal sampled from the signal source by the chip to be tested is the test data, and the chip to be tested stores the signal (test data) in a register in a file mode. Because the test platform and the FPGA test device cannot be directly butted, test data needs to be transmitted through a test file.
Wherein, the signal collected from the signal source has the following form:
1. and checking whether the test point under a certain configuration condition is covered according to the value of the register of the chip to be tested.
2. Certain fields in the message structure are excited within the chip or in the environment, such as the message type field in an ethernet message is sampled to check if an ARP type message is covered.
3. Certain signals of the on-chip bus/module, such as ARBURST signals within the AXI bus, are sampled to determine whether a FIXED type read operation is to be overridden.
4. Some data inside the reference model, such as ethernet frame FCS check result, is correct.
In an embodiment, the register is a register of a chip to be tested, the register of the chip to be tested is statically configured, that is, the register is configured first and then tested, dynamic configuration is not allowed in the testing process, otherwise, the function is wrong.
In another embodiment, the internal signal of the chip to be tested or the register requiring dynamic configuration is not easily changed by a simple method of reading the register, because the internal signal may change from time to time, the register may be read once to obtain a value only once, and the signal to be sampled may not be the register. When the chip to be tested is an SOC chip (system on chip), a collecting unit may be added to the chip to be tested, and a specific structure thereof refers to fig. 4, where fig. 4 is a schematic structural diagram of a first embodiment of the chip to be tested according to the present invention.
In fig. 4, a part of the DDR address space is partitioned to store test data during the test. The source unit of the signal source is connected to a collecting unit (the dotted line frame is the collecting unit), and the collecting unit samples the signal when appropriate and writes the data into the allocated DDR space according to a certain format.
Based on the structure of the previous embodiment, in order not to influence the verification of the chip, the function of the collecting unit is opened when the test data is required to be collected, and the function of the collecting unit is closed when the test data is not required to be collected, thereby avoiding the influence on the verification of the chip to be tested.
In addition, to avoid writing the DDR too much, control of the time period is added in the gather unit, e.g., writing the previous 100 cycles of data to the DDR, and the length of the further sample period can be configured by a register. Interval control may also be added, for example, writing data once every 1000 cycles, or writing DDR only when a change in signal occurs. Control when the allocated space is full, namely stopping the action of writing DDR (double data rate) of functional coverage data after the allocated space is full, can be added to prevent the written data from being covered. Information about the sequence of signal transitions may also be collected based on the need to collect test data, for example, to identify whether a signal has such a transition from 1 to 3.
In another embodiment, the chip design to be tested is not an SOC chip, that is, there is no CPU inside the chip, and a new structure may be adopted to design the testing device, referring to fig. 5, fig. 5 is a schematic structural diagram of the FPGA testing device according to the first embodiment of the present invention.
In fig. 5, a collection unit group (a portion within a dotted line frame) and a dedicated CPU are added (unlike the above-described embodiment, the collection unit is not hung on the original bus of the chip in this embodiment). The functions of the collection unit, DDR controller and DDR PHY and DDR granules are the same as in the above embodiment. Here a dedicated CPU and dedicated CPU interface is added. When the test data is written into the DDR, a read data operation can be initiated through the special CPU, the CPU interface module realizes the analysis of the special CPU time sequence and the command, and converts the command into the operation of the DDR controller to read the data in the DDR particles. The other processes are the same. The method has no influence on normal test and is a better method.
Step S13: and acquiring the test data from the FPGA test device.
Step S14: and sending the test data to a verification platform so that the verification platform obtains the coverage rate of the chip to be tested based on the test data.
Step S15: and obtaining a verification result of the chip to be tested based on the received function coverage rate returned by the verification platform.
Since the test data is transmitted in the form of a test file, the step of obtaining the test data from the FPGA testing device includes: and acquiring the test file from the FPGA test device, and extracting the test data from the test file. To send test data to the test platform. In another embodiment, the test file may be directly sent to the test platform, and the test platform extracts the test data from the test file.
In the above embodiments, the storage formats of the test files may be different, and the terminal device is required to obtain the test file from the register of the chip to be tested of the FPGA testing apparatus.
Further, before the step of obtaining the test data from the FPGA testing device, the method further includes: receiving feedback information sent by the FPGA testing device; the step of obtaining the test data from the FPGA testing device includes: when the feedback information is that the test of the chip to be tested is successful, obtaining the test data from the FPGA test device; or the like, or, alternatively,
when the feedback information is that the test of the chip to be tested fails, obtaining test process information from the FPGA test device; modifying the target verification plan by using the test process information to obtain a modified verification plan; creating a new target test case by using the modified verification plan and the target test case; and updating the target test case by using the new target test case, and returning to execute the step of sending the target test case to a Field Programmable Gate Array (FPGA) test device until the feedback information indicates that the test of the chip to be tested is successful, and continuing to execute the step of obtaining the test data from the FPGA test device.
The terminal device needs to determine whether the testing process of the chip to be tested is successfully completed, that is, whether the target test case is successfully executed, and only when the target test case is successfully executed (the chip to be tested is successfully tested), the obtained test data in the test file has reference significance, and if the target test case is not successfully executed, the obtained test data in the test file has no significance. Whether the target test case is successfully executed or not can be determined based on the feedback information (the feedback information is that the test of the chip to be tested fails or the test of the chip to be tested succeeds) by receiving the feedback information of the FPGA test device. In another embodiment, a simple communication signal may also be sent by the terminal device and the FPGA testing apparatus to determine whether the chip to be tested is successfully tested.
When the target test case is not successfully executed, namely the test of the chip to be tested fails, the target verification plan needs to be modified so as to obtain a modified verification plan; and creating a new target test case by using the modified verification plan and the target test case, so as to update the target test case by using the new target test case, and returning to execute the step of sending the target test case to a Field Programmable Gate Array (FPGA) test device, and obtaining a meaningful test file and further obtaining meaningful test data until the feedback information is that the test of the chip to be tested is successful.
It should be noted that the test process information may be a signal of the chip to be tested in the test process, which is obtained when the chip to be tested fails in the test, and is used to determine a specific reason of the test failure.
And after the functional coverage rate is obtained, obtaining a verification result of the chip to be tested based on the functional coverage rate.
The technical scheme of the invention provides a chip verification method for terminal equipment, which comprises the following steps: creating a target test case based on the target verification plan; sending the target test case to a Field Programmable Gate Array (FPGA) testing device so that the FPGA testing device tests a chip to be tested in the FPGA testing device by using the target test case to obtain test data; acquiring the test data from the FPGA test device; sending the test data to a verification platform so that the verification platform obtains the functional coverage rate of the chip to be tested based on the test data; and obtaining a verification result of the chip to be tested based on the received function coverage rate returned by the verification platform.
In the existing verification method, the FPGA testing device cannot obtain the functional coverage of the chip to be tested, and a technician needs to manually record the parameters in the verification process and manually analyze the recorded parameters to obtain the functional coverage, so that the operation of the chip verification process is complicated, and the chip verification efficiency is low. In the application, the terminal equipment automatically acquires the test data from the FPGA test device, and the test data is automatically analyzed by the verification platform to obtain the function coverage rate, so that a technician does not need to manually participate in the acquisition process of the function coverage rate, the operation of the chip verification process is simple, and the chip verification efficiency is high. Therefore, the chip verification method achieves the technical effect of improving the chip verification efficiency.
Referring to fig. 6, fig. 6 is a schematic flowchart of a second embodiment of the chip verification method of the present invention, where the method is used for verifying a platform, and the method includes the following steps:
step S21: the method comprises the steps of receiving test data sent by terminal equipment, wherein the test data are obtained by the terminal equipment from a Field Programmable Gate Array (FPGA) test device, the test data are obtained by testing a chip to be tested in the FPGA test device by utilizing a target test case sent by the terminal equipment, and the target test case is created based on a target verification plan.
Step S22: and obtaining the coverage rate of the chip to be tested based on the test data.
Step S23: and sending the coverage rate to the terminal equipment so that the terminal equipment obtains a verification result of the chip to be tested based on the functional coverage rate.
With reference to the above description of the terminal device, further description is omitted here.
Further, the verification platform is an EDA verification platform; before the step of obtaining the coverage rate of the chip to be tested based on the test data, the method further includes: creating a functional coverage model based on the target verification plan; correspondingly, the step of obtaining the coverage rate of the chip to be tested based on the test data comprises: obtaining the coverage rate based on the test data and the functional coverage rate model.
It should be noted that the EDA verification platform of the present application is written in the systemveilog language and needs to be simulated by a simulator such as VCS, and its function is only to obtain the coverage (functional coverage), and does not need to do the functions of reference model, Driver, Monitor and Scoreboard in the conventional EDA verification platform. The function coverage rate model is the same as that in the conventional EDA verification platform, except that in the application, the terminal device acquires the test data from the FPGA testing apparatus when the EDA verification platform acquires the test data.
Specifically, the step of obtaining the coverage rate based on the test data and the functional coverage rate model includes: extracting the value of the real coverage point in the chip to be detected from the test data; assigning a value to the simulation coverage point in the functional coverage rate model by using the value of the real coverage point; and sampling the assigned simulation coverage points by using an objective function to obtain the coverage rate. Wherein, the simulation coverage point is a point in the functional coverage rate model which has a correlation relation with the real coverage point.
The objective function may be a sample function in the EDA verification platform, by which the assigned simulated coverage points are sampled to obtain the coverage.
Referring to fig. 7, fig. 7 is a block diagram of a first embodiment of a chip verification apparatus according to the present invention, where the apparatus is used in a terminal device, and the apparatus includes:
a creating module 10, configured to create a target test case based on a target verification plan;
the first sending module 20 is configured to send the target test case to a field programmable gate array FPGA testing apparatus, so that the FPGA testing apparatus tests a chip to be tested in the FPGA testing apparatus by using the target test case to obtain test data;
an obtaining module 30, configured to obtain the test data from the FPGA testing apparatus;
the second sending module 40 is configured to send the test data to a verification platform, so that the verification platform obtains the coverage rate of the chip to be tested based on the test data;
a first receiving module 50, configured to obtain a verification result of the chip to be tested based on the received function coverage returned by the verification platform.
Referring to fig. 8, fig. 8 is a block diagram of a first embodiment of a chip verification apparatus according to the present invention, the apparatus is used for a verification platform, and the apparatus includes:
the second receiving module 60 is configured to receive test data sent by a terminal device, where the test data is obtained by the terminal device from a Field Programmable Gate Array (FPGA) testing apparatus, the test data is obtained by the FPGA testing apparatus testing a chip to be tested in the FPGA testing apparatus by using a target test case sent by the terminal device, and the target test case is created based on a target verification plan;
an obtaining module 70, configured to obtain a coverage rate of the chip to be tested based on the test data;
a third sending module 80, configured to send the coverage rate to the terminal device, so that the terminal device obtains a verification result of the chip to be tested based on the functional coverage rate.
The above description is only an alternative embodiment of the present invention, and not intended to limit the scope of the present invention, and all modifications and equivalents of the present invention, which are made by the contents of the present specification and the accompanying drawings, or directly/indirectly applied to other related technical fields, are included in the scope of the present invention.