Chip testing method and device based on FPGA (Field Programmable Gate Array)
By constructing position constraints and circuit correlation of the module to be tested, the problem of unfixed TPG and ORA circuit positions in BIST tests is solved, the position solidification and efficient debugging of the hardware platform are realized, the simulation process is simplified, and it is suitable for a variety of compilation tools. .
Patent Information
- Application Number
- CN202411041956.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-31
- Publication Date
- 2024-11-15
AI Technical Summary
The position of TPG and ORA circuits in the existing BIST testing devices is not fixed, which leads to difficulty in timing convergence and increases the difficulty of simulation debugging, especially when cross-device transplantation.
By constraining the module to be tested, a test case generation circuit and a test result analysis circuit are built, and connected to the target circuit to be tested, ensuring the correlation and position solidification of the circuit, breaking away from the comprehensive scope of the compilation tool, and directly mapping the underlying circuit to Determine the circuit position and realize the position solidification and debugging of the hardware platform.
Improves timing convergence efficiency, simplifies simulation debugging, ensures the position consistency of test case generation circuits and test result analysis circuits, is suitable for a variety of software compilation tools, reduces the links of tool synthesis and timing analysis, and improves development and debugging efficiency. .
Smart Images

Figure CN118962398A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of chip testing technology, and in particular to a chip testing method and device based on FPGA. Background Art
[0002] Currently in the semiconductor industry, BIST (Built-in Self-Test) is a widely used test technology, applicable to almost all circuits. Existing BIST test devices usually include TPG (Test Pattern Generator), DUT (Device Under Test) and ORA (Output Response Analyzer). By constructing TPG, the test vector is generated in the chip according to the instantiated target test resource circuit and imported into the DUT. By constructing ORA to collect the output data generated by the DUT and process and analyze whether it meets expectations, the functional test of the DUT is realized.
[0003] However, the construction of TPG and ORA in the BIST test device is often completed with the help of high-level hardware description languages such as Verilog and VHDL and the compiler tools provided by FPGA (Field Programmable Gate Array) chip manufacturers. These compiler tools independently construct TPG circuits and ORA circuits, so that the positions of TPG circuits and ORA circuits are not fixed, and TPG circuits and ORA circuits are not associated with DUT circuits. Even for the same DUT circuit, the TPG circuits and ORA circuits generated twice will be different from each other, and the positions of TPG circuits and ORA circuits generated by different software tools will also be different. In other words, when performing cross-device transplantation for the same DUT, the circuit positions of TPG and ORA before and after transplantation are prone to deviation, which increases the difficulty of simulation debugging. Summary of the invention
[0004] The purpose of the present invention is to provide a chip testing method and device based on FPGA, so as to solve the problem in the prior art that when the BIST test method is used for the FPGA chip, the positions of the TPG circuit and the ORA circuit generated by the compilation tool for the same DUT are not fixed, which makes the timing convergence difficult and increases the difficulty of simulation debugging.
[0005] The FPGA-based chip testing method and device provided in this application adopt the following technical solutions:
[0006] A chip testing method based on FPGA, the method comprising:
[0007] Performing position constraints on the module to be tested to obtain a target circuit to be tested;
[0008] Constructing a corresponding test case generation circuit and a test result analysis circuit according to the module to be tested;
[0009] Connecting the test case generation circuit, the test result analysis circuit and the target circuit to be tested to obtain an overall test circuit;
[0010] The test case generation circuit and the test result analysis circuit are debugged according to the test analysis result output by the overall test circuit until the test analysis result meets a preset debugging pass condition.
[0011] By adopting the above technical scheme, the module to be tested is first subjected to position constraints to obtain the target circuit to be tested, so as to realize the position solidification of the hardware platform. Subsequently, the corresponding test case generation circuit and test result analysis circuit are constructed according to the module to be tested. When constructing the test case generation circuit and the test result analysis circuit, the position of the target circuit to be tested corresponding to the module to be tested is fully considered to ensure the relevance between the target circuit to be tested and the test case generation circuit and the test result analysis circuit. Then, after determining the target circuit to be tested, the test case generation circuit and the test result analysis circuit, the target circuit to be tested, the test case generation circuit and the test result analysis circuit are connected to obtain the overall test circuit. The test case generation circuit is used to input the test case to the target circuit to be tested, and the test result analysis circuit analyzes the output of the target circuit to be tested to obtain the test analysis result. The test case generation circuit and the test result analysis circuit are debugged according to the test analysis result output by the overall test circuit to realize chip test debugging under hardware conditions.
[0012] Optionally, the method further includes:
[0013] The test analysis results meet the preset debugging pass conditions, and the configuration file of the overall test circuit is stored in the configuration library for other modules to be tested that meet the preset requirements to construct corresponding test case generation circuits and test result analysis circuits. The preset requirements are associated with the modules to be tested.
[0014] By adopting the above technical solution, when the test analysis result meets the preset debugging pass condition, the configuration file of the overall test circuit is stored in the configuration library, so that when other modules to be tested that meet the preset requirements are tested for chip testing, the configuration file can be directly called to quickly generate a test case generation circuit and a test result analysis circuit, thereby realizing the "IP" detection of BIST test results, so that it can be directly called when developing engineering files, thereby improving the overall development and subsequent debugging efficiency.
[0015] Optionally, the step of constructing a corresponding test case generation circuit and a test result analysis circuit according to the module to be tested includes:
[0016] Obtain a test case generation module and a test result analysis module corresponding to the module to be tested;
[0017] A test case generation circuit and a test result analysis circuit are constructed according to the module to be tested by mapping the underlying circuit.
[0018] By adopting the above technical solution, the test case generation module and test result analysis module, which were originally handed over to the compilation tool for synthesis, are determined to correspond to the test case generation circuit and the test result analysis circuit by directly mapping the underlying circuit. This solution is set out of the scope determined by tool synthesis. The target circuit to be tested, the test case generation circuit and the test result analysis circuit of the module to be tested are all confirmed on the hardware platform, which saves the link and time of tool synthesis and timing analysis convergence.
[0019] Optionally, the step of constructing a corresponding test case generation circuit and a test result analysis circuit according to the module to be tested includes:
[0020] When the module to be tested meets the preset requirement, reading the configuration file corresponding to the preset requirement in the configuration library;
[0021] A test case generation circuit and a test result analysis circuit are constructed according to the configuration file.
[0022] By adopting the above technical solution, when the chip test is performed on the module B0 to be tested, the test analysis result meets the preset debugging pass condition, the configuration file C0 of the overall test circuit is stored in the configuration library, and the module to be tested that calls the configuration file C0 is set to meet the preset requirements corresponding to the module B0 to be tested.
[0023] When the module to be tested B1 that meets the preset requirements builds a test case generation circuit and a test result analysis circuit, it can read the configuration file C0 in the configuration library, and directly build the test case generation circuit and the test result analysis circuit according to the configuration file C0. When developing engineering files, when facing modules to be tested with the same characteristics (meeting the preset requirements), the configuration file corresponding to the module to be tested that has been debugged can be directly called to improve the overall development efficiency and subsequent debugging efficiency.
[0024] Optionally, the step of connecting the test case generation circuit, the test result analysis circuit and the target circuit to be tested to obtain an overall test circuit includes:
[0025] The output end of the test case generation circuit is connected to the input end of the target circuit to be tested, and the output end of the target circuit to be tested is connected to the input end of the test result analysis circuit to obtain the overall test circuit; the test case generation circuit is used to generate test case stimuli, the target circuit to be tested is used to generate test data according to the test case stimuli, and the test result analysis circuit is used to generate test analysis results according to the test data.
[0026] By adopting the above technical solution, the target circuit to be tested generates test data according to the test case from the test case generation circuit; the test result analysis circuit outputs the test analysis result according to the test data. Then, the test case generation circuit and the test result analysis circuit are debugged according to the test analysis result until the test result meets the preset debugging pass condition.
[0027] Optionally, the configuration file of the test circuit includes electronic components of the overall test circuit, positions of the electronic components, and pin connection relationships between the electronic components.
[0028] Optionally, the other modules to be tested that meet the preset requirements construct corresponding test case generation circuits and test result analysis circuits, including:
[0029] When the current module under test meets the preset requirements corresponding to the target module under test, a test case generation circuit and a test result analysis circuit corresponding to the current module under test are generated according to the configuration file of the target module under test.
[0030] Optionally, when the test analysis result meets a preset debugging pass condition, the configuration file of the overall test circuit is stored in a configuration library, including:
[0031] According to the debugging pass instruction from the user, the configuration file of the overall test circuit is solidified, packaged and stored in the configuration library.
[0032] The present invention also provides a chip testing device based on FPGA, including a designated module to be tested, a constraint module to be tested, a test case generation module, a test result analysis module, a test connection module and a debugging module;
[0033] The designated module to be tested is used to specify the module to be tested;
[0034] The constraint module to be tested is used to constrain the position of the module to be tested to obtain a target circuit to be tested;
[0035] The test case generation module is used to construct a corresponding test case generation circuit according to the module to be tested;
[0036] The test result analysis module is used to construct a corresponding test result analysis circuit according to the module to be tested;
[0037] The test connection module is used to sequentially connect the test case generation circuit, the target circuit to be tested, and the test result analysis circuit in series to obtain an overall test circuit;
[0038] The debugging module is connected to the overall test circuit and is used to debug the test case generation circuit and the test result analysis circuit according to the test analysis result output by the overall test circuit until the test analysis result meets the preset debugging pass condition.
[0039] By adopting the above technical scheme, the module to be tested is first subjected to position constraints to obtain the target circuit to be tested, so as to realize the position solidification of the hardware platform. Subsequently, the corresponding test case generation circuit and test result analysis circuit are constructed according to the module to be tested. When constructing the test case generation circuit and the test result analysis circuit, the position of the target circuit to be tested corresponding to the module to be tested is fully considered to ensure the relevance between the target circuit to be tested and the test case generation circuit and the test result analysis circuit. Then, after determining the target circuit to be tested, the test case generation circuit and the test result analysis circuit, the target circuit to be tested, the test case generation circuit and the test result analysis circuit are connected to obtain the overall test circuit. The test case generation circuit is used to input the test case to the target circuit to be tested, and the test result analysis circuit analyzes the output of the target circuit to be tested to obtain the test result. The test case generation circuit and the test result analysis circuit are debugged according to the test analysis result output by the overall test circuit to realize chip test debugging under hardware conditions.
[0040] Optionally, the chip testing device further includes a configuration library, a configuration reading module, and a configuration calling module;
[0041] The configuration reading module is connected to the debugging module, and is used to obtain the configuration file of the overall test circuit by using a preset synthesis tool, and when the test analysis result meets the preset debugging pass condition, store the configuration file in the configuration library;
[0042] The configuration calling module is connected to the module to be tested, the test case generating module and the test result analyzing module, and is used for calling the configuration file corresponding to the preset requirements from the configuration library when the module to be tested meets the preset requirements, and sending the configuration file to the test case generating module and the test result analyzing module, so that the test case generating module generates the test case generating circuit, and the test result analyzing module generates the test result analyzing circuit.
[0043] By adopting the above technical solution, when the test analysis result meets the preset debugging pass condition, the configuration file is recorded so that when the chip test is performed on the module to be tested that meets the preset requirements in the future, the configuration file can be directly called to quickly generate the test case generation circuit and the test result analysis circuit.
[0044] In summary, the present application includes at least one of the following beneficial technical effects:
[0045] 1. In constructing the test case generation circuit and the test result analysis circuit, this case fully considers the position of the target circuit under test corresponding to the module under test, ensures that the test case generation circuit and the test result analysis circuit generated by the same module under test are associated, ensures the position of the test case generation circuit and the test result analysis circuit, improves the timing convergence efficiency, and simplifies simulation debugging.
[0046] 2. This case is mainly tested and analyzed in a hardware environment and is suitable for a variety of different software compilation tools. This avoids the situation where the test case generation circuits and test result analysis circuits generated by different software compilation tools are in different positions, causing deviations that affect the debugging effect.
[0047] 3. In this case, when the test analysis results meet the preset debugging pass conditions, the configuration file is recorded so that when the chip test is carried out on the module to be tested that meets the preset requirements, the configuration file can be directly called to quickly generate the test case generation circuit and the test result analysis circuit, so as to realize the "IP" detection of the BIST test results, so as to facilitate direct calling when developing engineering files, thereby improving the overall development and subsequent debugging efficiency.
[0048] 4. In this case, the test case generation module and test result analysis module, which were originally synthesized by the compilation tool, were determined to have the corresponding test case generation circuit and test result analysis circuit by directly mapping the underlying circuit. It is out of the scope determined by the tool synthesis. The target circuit to be tested, the test case generation circuit and the test result analysis circuit of the module to be tested are all confirmed on the hardware platform, which saves the link and time of tool synthesis and timing analysis convergence. BRIEF DESCRIPTION OF THE DRAWINGS
[0049] Figure 1 It is a flowchart of a chip testing method based on FPGA in the first embodiment of the present invention;
[0050] Figure 2 is a schematic diagram of a flow chart of a chip testing device based on FPGA in a second embodiment of the present invention;
[0051] Description of reference numerals:
[0052] DUT, module to be tested; 101, target circuit to be tested; TPG, test case generation module; 102, test case generation circuit; ORA, test result analysis module; 103, test result analysis circuit; 10, overall test circuit; 201, specified module to be tested; 202, constraint module to be tested; 203, test connection module; 204, debugging module; 205, configuration library; 206, configuration reading module; 207, configuration calling module. DETAILED DESCRIPTION
[0053] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention. Unless otherwise defined, the technical terms or scientific terms used herein should be understood by people with general skills in the field to which the present invention belongs. "Including" and similar words used in this article mean that the elements or objects appearing before the word include the elements or objects listed after the word and their equivalents, without excluding other elements or objects.
[0054] First embodiment:
[0055] The first embodiment of the present invention provides a chip testing method based on FPGA, including: performing position constraints on the module under test DUT to obtain a target circuit under test 101; constructing a corresponding test case generation circuit 102 and a test result analysis circuit 103 according to the module under test DUT; connecting the test case generation circuit 102, the test result analysis circuit 103 and the target circuit under test 101 to obtain an overall test circuit 10, and debugging the test case generation circuit 102 and the test result analysis circuit 102 according to the test analysis result output by the overall test circuit 10 until the test result meets a preset debugging pass condition.
[0056] First, the position constraint of the module under test DUT is performed to obtain the target circuit under test 101 to realize the position solidification of the hardware platform. Subsequently, the corresponding test case generation circuit 102 and the test result analysis circuit 103 are constructed according to the module under test DUT. When constructing the test case generation circuit 102 and the test result analysis circuit 103, the position of the module under test DUT corresponding to the target circuit under test 101 is fully considered. Then, after determining the target circuit under test 101, the test case generation circuit 102 and the test result analysis circuit 103, the target circuit under test 101, the test case generation circuit 102 and the test result analysis circuit 103 are connected to obtain the overall test circuit 10, the test case generation circuit 102 is used to input the test case to the target circuit under test 101, and the test result analysis circuit 103 analyzes the output of the target circuit under test 101 to obtain the test analysis result. The test case generation circuit 102 and the test result analysis circuit 103 are debugged according to the test analysis result output by the overall test circuit 10 to realize chip test debugging under hardware conditions.
[0057] The following is a detailed description of the implementation details of the FPGA-based chip testing method of this embodiment. The following content is only for the convenience of understanding the implementation details provided, and is not necessary for the implementation of this solution. The specific process of this embodiment is as follows: Figure 1 As shown, the following steps are included:
[0058] Step S1, performing position constraints on the module to be tested to obtain a target circuit to be tested.
[0059] Specifically, the module DUT to be tested is specified by the staff based on the already defined functions, that is, the target function is first defined, and then the module DUT to be tested is specified based on the target function. Subsequently, the module DUT to be tested is positionally constrained to limit the physical position of the target circuit to be tested on the FPGA chip, to achieve fixation during the layout and routing process, and to ensure that the target circuit to be tested 101 is solidified. Usually, the position constraint can be specified by the LOC statement to specify the specific position (including range, area, pin, etc.) on the FPGA chip.
[0060] Step S2, constructing a corresponding test case generation circuit and a test result analysis circuit according to the module to be tested.
[0061] Specifically, obtain the test case generation module TPG and the test result analysis module ORA corresponding to the module under test DUT, obtain the test case generation circuit 102 through the underlying mapping method according to the test case generation module TPG, and obtain the test result analysis circuit through the underlying mapping method according to the test result analysis module ORA.
[0062] In this case, the test case generation module TPG and the test result analysis module ORA, which were originally handed over to the compilation tool for synthesis, were determined to correspond to the test case generation circuit 102 and the test result analysis circuit 103 by directly mapping the underlying circuit, realizing the direct call of the underlying physical resources inside the FPGA, eliminating the tool synthesis layout process, and improving the test case generation efficiency. According to the module to be tested DUT, the position of the test case generation module TPG and the test result analysis module ORA are directly optimized, which is out of the scope determined by the tool synthesis. The target circuit to be tested 101, the test case generation circuit 102 and the test result analysis circuit 103 of the module to be tested DUT are all confirmed on the hardware platform, eliminating the link and time of tool synthesis and timing analysis convergence, and shortening the timing convergence cycle.
[0063] In some examples, when the module under test DUT meets the preset requirements, a configuration file corresponding to the preset requirements in the configuration library 205 is read; and a test case generation circuit 102 and a test result analysis circuit 103 are constructed according to the configuration file.
[0064] In this example, the configuration requirements are usually set when the configuration library 205 enters the configuration file. When other modules to be tested that meet the preset requirements are tested for chip testing, the configuration file is directly called to quickly generate the test case generation circuit 102 and the test result analysis circuit 103, and is directly called when developing the project file, thereby improving the overall development and subsequent debugging efficiency.
[0065] For example, when constructing the test case generation circuit 102 and the test result analysis circuit 103 of the module under test DUT-B1 that meets the preset requirements, it is possible to read the configuration file C0 corresponding to the preset requirements in the configuration library 205, and directly build the test case generation circuit 102 and the test result analysis circuit 103 according to the configuration file C0.
[0066] In some examples, the implementation of step S2 includes:
[0067] S2-1, determine whether the module under test DUT meets one of the existing preset requirements. If none of them are met, execute S2-2. If a preset requirement is met, execute S2-3.
[0068] S2-2, including: S2-2-1, obtaining the test case generation module TPG and the test result analysis module ORA corresponding to the module to be tested DUT; S2-2-2, building the test case generation circuit 102 and the test result analysis circuit 103 according to the module to be tested DUT by mapping the underlying circuit;
[0069] S2-3, including: S2-3-1, when the module under test DUT meets the preset requirements, read the configuration file corresponding to the preset requirements in the configuration library 205; S2-3-2, build a test case generation circuit 102 and a test result analysis circuit 103 according to the configuration file.
[0070] In this example, there are two execution modes for the process of constructing the corresponding test case generation circuit 102 and test result analysis circuit 103 according to the module to be tested DUT: one is to directly generate the test case generation circuit 102 and the test result analysis circuit 103 by the bottom layer mapping method (i.e. S2-2) according to the test case generation module TPG and the test result analysis module ORA read by the module to be tested DUT, which has universal applicability, but the working process is cumbersome and requires repeated calls and mapping; the second is to directly read the configuration file corresponding to the preset requirements met by the module to be tested DUT, and directly generate the test case generation circuit 102 and the test result analysis circuit 103 according to the configuration file, which has higher work efficiency. This example integrates the two execution modes. When the module to be tested DUT does not meet any preset requirements, S2-2 is used for execution, and when the module to be tested DUT meets the preset requirements, S2-3 is used for execution, so as to ensure that the corresponding test case generation circuit 102 and the test result analysis circuit 103 can be quickly constructed according to the module to be tested DUT.
[0071] In this step 102, a corresponding test case generation circuit 102 and a test result analysis circuit 103 are constructed according to the module under test DUT. When constructing the test case generation circuit 102 and the test result analysis circuit 103, the position of the module under test DUT corresponding to the target circuit under test 101 is fully considered to ensure the correlation between the module under test DUT and the test case generation circuit 102 and the test result analysis circuit 103.
[0072] In this case, for the same module under test DUT, the same test case generation circuit 102 and test result analysis circuit 103 are specified by using multiple different compilation software, ensuring the applicability of multiple compilation software. In addition, when the module under test DUT is transplanted across devices, the test case generation circuit 102 and test result analysis circuit 103 with fixed relative positions will also make simulation debugging easier.
[0073] Step S3, connecting the test case generation circuit, the test result analysis circuit and the target circuit to be tested to obtain an overall test circuit.
[0074] Specifically, the output end of the test case generation circuit 102 is connected to the input end of the target circuit to be tested 101, and the output end of the target circuit to be tested 101 is connected to the input end of the test result analysis circuit 103, so as to obtain the overall test circuit 10. The test case generation circuit 102 is used to generate test case stimuli, the target circuit to be tested 101 is used to generate test data according to the test case stimuli from the test case generation circuit 102, and the test result analysis circuit 103 is used to generate test analysis results according to the test data from the target circuit to be tested 101.
[0075] Step S4, according to the test analysis result output by the overall test circuit, debug the test case generation circuit and the test result analysis circuit until the test analysis result meets the preset debugging pass condition.
[0076] Specifically, the staff debugs the test case generation circuit 102 and the test result analysis circuit 103 according to the test analysis result of the test result analysis circuit 103, until the test analysis result output by the test result analysis circuit 103 meets the debugging pass condition. Here, the debugging pass condition is the expected range pre-set by the staff. When the test analysis result is within the expected range, it is determined that the overall test circuit 10 corresponding to the test analysis result has been debugged, that is, the test case generation circuit 102 and the test result analysis circuit 103 used to detect the target circuit under test 11 corresponding to the module under test DUT do not need to be modified, and all target circuits under test 101 corresponding to the module under test DUT can be detected.
[0077] Step S5, the configuration file of the overall test circuit is stored in a configuration library for other modules to be tested that meet preset requirements to construct corresponding test case generation circuits and test result analysis circuits, and the preset requirements are associated with the modules to be tested.
[0078] Specifically, the execution of step S5 is triggered after the test result in S4 meets the preset debugging pass condition. When the overall test circuit 10 is debugged, the configuration file of the overall test circuit 10 is stored in the configuration library 205, so that other modules under test DUT that meet the preset requirements can construct corresponding test case generation circuits 102 and test result analysis circuits 103, and the preset requirements are associated with the modules under test DUT.
[0079] Among them, other modules under test DUT that meet the preset requirements construct corresponding test case generation circuits 102 and test result analysis circuits 103, including: when the current module under test DUT meets the corresponding preset requirements of the target module under test DUT, the test case generation circuit 102 and test result analysis circuit 103 corresponding to the current module under test DUT are generated according to the configuration file of the target module under test DUT.
[0080] In this example, the preset requirements of the module to be tested B0 are pre-set, and then the chip test is performed on the module to be tested B0, the position constraint of the module to be tested B0 is performed to obtain the target circuit to be tested B0', and a test case generation circuit and a test result analysis circuit are constructed. The target circuit to be tested B0', the test case generation circuit and the test result analysis circuit constitute an overall test circuit, and the test case generation circuit and the test result analysis circuit are debugged according to the test analysis result output by the overall test circuit until the test analysis result meets the preset debugging pass condition. At this time, it is determined that the overall test circuit test of the module to be tested B0 is completed, that is, the overall test circuit can be used to test the module to be tested B0, and the module units to be tested with the same characteristics as the module to be tested B0 (that is, other test modules that meet the preset requirements).
[0081] When the test analysis result output by the overall test circuit meets the preset debugging pass condition, the configuration file C0 of the overall test circuit is extracted, and the configuration file C0 includes the preset requirements corresponding to the test module B0, the configuration of the test case generation circuit, and the configuration of the test result analysis circuit. The configuration file C0 is stored in the configuration library.
[0082] When the module to be tested B1 that meets the preset requirements builds a test case generation circuit and a test result analysis circuit, it can read the configuration file C0 in the configuration library, and directly build the test case generation circuit and the test result analysis circuit according to the configuration file C0. When developing engineering files, when facing modules to be tested with the same characteristics (meeting the preset requirements), the configuration file corresponding to the module to be tested that has been debugged can be directly called to improve the overall development efficiency and subsequent debugging efficiency.
[0083] Among them, the configuration file of the overall test circuit 10 is usually obtained by extracting the electronic components, the positions of the electronic components, and the pin connection relationship between the electronic components of the test case generation circuit 102 and the test result analysis circuit 103 in the overall test circuit 10 through a preset comprehensive tool, and solidifying the package to generate the configuration file TPG0-IP / ORA0-IP. That is, TPG / ORA is solidified into TPG0-IP / ORA0-IP.
[0084] The configuration file of the overall test circuit 10 is obtained either when the overall test circuit 10 is obtained (the connection between the test case generation circuit 102 - the target circuit to be tested 101 - the test result analysis circuit 103 is completed), or when the debugging of the overall test circuit 10 is completed in step S4.
[0085] The step division of the above-mentioned methods is only for the purpose of clear description. When implemented, they can be combined into one step or some steps can be split and decomposed into multiple steps. As long as they include the same logical relationship, they are all within the scope of protection of this patent. Adding insignificant modifications or introducing insignificant designs to the algorithm or process without changing the core design of the algorithm and process are all within the scope of protection of this patent.
[0086] Second implementation method:
[0087] The second embodiment of the present invention provides a chip testing device 200 based on FPGA, such as Figure 2 As shown, it includes a test designation module 201 , a test constraint module 202 , a test case generation module TPG, a test result analysis module ORA, a test connection module 203 and a debugging module 204 .
[0088] The designated module to be tested 201 is used to designate the module to be tested DUT;
[0089] The constraint module 202 is connected to the specified module 201 and is used to constrain the position of the module DUT to obtain the target circuit 101.
[0090] The test case generation module TPG is connected to the designated module to be tested 201 and is used to construct a corresponding test case generation circuit 102 according to the module to be tested DUT;
[0091] The test result analysis module ORA is connected to the designated module to be tested 201, and is used to construct a corresponding test result analysis circuit 103 according to the module to be tested DUT;
[0092] The test connection module 203 is used to sequentially connect the test case generation circuit 102, the target circuit to be tested 101, and the test result analysis circuit 103 to obtain the overall test circuit 10;
[0093] The debugging module 204 is connected to the overall test circuit 10, and is used to debug the test case generation circuit 102 and the test result analysis circuit 103 according to the test analysis result output by the overall test circuit 10, and the test analysis result meets the preset debugging pass condition (preset expected range).
[0094] In some examples, the chip testing device further includes a configuration library 205 , a configuration reading module 206 , and a configuration calling module 207 .
[0095] The configuration reading module 206 is connected to the debugging module 204, and is used to obtain the configuration file of the overall test circuit 10 by using a preset synthesis tool, and when the test analysis result output by the overall test circuit 10 meets the preset debugging pass condition, the configuration file is stored in the configuration library 205;
[0096] The configuration calling module 207 is connected to the module under test DUT, the test case generation module TPG and the test result analysis module ORA, and is used to call the configuration file corresponding to the preset requirements from the configuration library when the module under test DUT meets the preset requirements, and send the configuration file to the test case generation module TPG and the test result analysis module ORA to generate the test case generation circuit 102 and the test result analysis circuit 103.
[0097] The module under test DUT is subjected to position constraint to obtain the target circuit under test 101 to realize the position solidification of the hardware platform, and the corresponding test case generation circuit 102 and test result analysis circuit 103 are constructed according to the module under test DUT. When constructing the test case generation circuit 102 and the test result analysis circuit 103, the position of the module under test DUT is fully considered to ensure the correlation between the module under test DUT and the test case generation circuit 102 and the test result analysis circuit 103. The test case generation circuit 102 is used to input the test case to the target circuit under test 101, and the test result analysis circuit 103 analyzes the output of the target circuit under test 101 to obtain the test result. The debugging is carried out according to the test result output by the overall test circuit 10, so as to realize the chip test debugging under hardware conditions. When the overall test circuit 10 is debugged, the configuration file is recorded so that when the same module under test DUT is tested for chip testing in the future, the configuration file is directly called to quickly generate the test case generation circuit 102 and the test result analysis circuit 103.
[0098] Other implementation details and working methods of the FPGA-based chip testing device 200 disclosed in the present application are the same or similar to the FPGA-based chip testing method described above and will not be repeated here.
[0099] Although the embodiments of the present invention are described in detail above, it is obvious to those skilled in the art that various modifications and variations can be made to these embodiments. However, it should be understood that such modifications and variations are within the scope and spirit of the present invention as described in the claims. Moreover, the present invention described herein may have other embodiments and may be implemented or realized in a variety of ways.
Claims
1. A chip testing method based on FPGA, characterized in that: The method comprises: Performing position constraints on the module to be tested to obtain a target circuit to be tested; Constructing a corresponding test case generation circuit and a test result analysis circuit according to the module to be tested; Connecting the test case generation circuit, the test result analysis circuit and the target circuit to be tested to obtain an overall test circuit; According to the test analysis result output by the overall test circuit, the test case generation circuit and the test result analysis circuit are debugged until the test analysis result meets a preset debugging pass condition.
2. The FPGA-based chip testing method according to claim 1, characterized in that: The method further comprises: When the test analysis results meet the preset debugging pass conditions, the configuration file of the overall test circuit is stored in the configuration library for other modules to be tested that meet the preset requirements to construct corresponding test case generation circuits and test result analysis circuits, and the preset requirements are associated with the modules to be tested.
3. The FPGA-based chip testing method according to claim 1, characterized in that: The method of constructing a corresponding test case generation circuit and a test result analysis circuit according to the module to be tested includes: Obtain a test case generation module and a test result analysis module corresponding to the module to be tested; A test case generation circuit and a test result analysis circuit are constructed according to the module to be tested by mapping the underlying circuit.
4. The FPGA-based chip testing method according to claim 2, characterized in that: The method of constructing a corresponding test case generation circuit and a test result analysis circuit according to the module to be tested includes: When the module to be tested meets the preset requirement, reading the configuration file corresponding to the preset requirement in the configuration library; A test case generation circuit and a test result analysis circuit are constructed according to the configuration file.
5. The FPGA-based chip testing method according to claim 1, characterized in that: The step of connecting the test case generation circuit, the test result analysis circuit and the target circuit to be tested to obtain an overall test circuit includes: The output end of the test case generation circuit is connected to the input end of the target circuit to be tested, and the output end of the target circuit to be tested is connected to the input end of the test result analysis circuit to obtain the overall test circuit; the test case generation circuit is used to generate test case stimuli, the target circuit to be tested is used to generate test data according to the test case stimuli, and the test result analysis circuit is used to generate test analysis results according to the test data.
6. The FPGA-based chip testing method according to claim 2, characterized in that: The configuration file of the test circuit includes the electronic components of the overall test circuit, the positions of the electronic components, and the pin connection relationships between the various electronic components.
7. The FPGA-based chip testing method according to claim 2, characterized in that: The other modules to be tested that meet the preset requirements construct corresponding test case generation circuits and test result analysis circuits, including: When the current module under test meets the preset requirements corresponding to the target module under test, a test case generation circuit and a test result analysis circuit corresponding to the current module under test are generated according to the configuration file of the target module under test.
8. The FPGA-based chip testing method according to claim 2, characterized in that: When the test analysis result meets the preset debugging pass condition, the configuration file of the overall test circuit is stored in a configuration library, including: According to the debugging pass instruction from the user, the configuration file of the overall test circuit is solidified, packaged and stored in the configuration library.
9. A chip testing device based on FPGA, characterized in that: It includes a designated module to be tested, a constraint module to be tested, a test case generation module, a test result analysis module, a test connection module and a debugging module; The designated module to be tested is used to specify the module to be tested; The constraint module to be tested is connected to the designated module to be tested, and is used to constrain the position of the module to be tested to obtain a target circuit to be tested; The test case generation module is used to construct a corresponding test case generation circuit according to the module to be tested; The test result analysis module is used to construct a corresponding test result analysis circuit according to the module to be tested; The test connection module is used to sequentially connect the test case generation circuit, the target circuit to be tested, and the test result analysis circuit in series to obtain an overall test circuit; The debugging module is connected to the overall test circuit and is used to debug the test case generation circuit and the test result analysis circuit according to the test analysis result output by the overall test circuit until the test analysis result meets the preset debugging pass condition.
10. The FPGA-based chip testing device according to claim 9, characterized in that: The chip testing device also includes a configuration library, a configuration reading module, and a configuration calling module; The configuration reading module is connected to the debugging module, and is used to obtain the configuration file of the overall test circuit by using a preset synthesis tool, and when the test analysis result meets the preset debugging pass condition, store the configuration file in the configuration library; The configuration calling module is connected to the module to be tested, the test case generating module and the test result analyzing module, and is used for calling the configuration file corresponding to the preset requirements from the configuration library when the module to be tested meets the preset requirements, and sending the configuration file to the test case generating module and the test result analyzing module, so that the test case generating module generates the test case generating circuit, and the test result analyzing module generates the test result analyzing circuit.
