Network-on-chip test platform generation method and device, electronic equipment and medium

By automatically generating an on-chip network test platform and using architecture information files to fill the test platform template, the problem of low test efficiency due to the diversity and scale expansion of on-chip network interfaces is solved, and efficient test platform generation and verification are achieved.

CN118646689APending Publication Date: 2024-09-13SHANDONG YUNHAI GUOCHUANG CLOUD COMPUTING EQUIP IND INNOVATION CENT CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202410741296.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-07
Publication Date
2024-09-13

AI Technical Summary

Technical Problem

As the size of chips and the number of modules increase, the number of interfaces and protocols of on-chip networks are diverse, resulting in inefficiency in manually setting up network-on-chip test platforms and inability to meet test needs.

Method used

By obtaining the architecture information file of the on-chip network, the test platform is automatically generated, including obtaining the design file to be tested, clock signal and reset signal information, filling in the test platform template file, generating the test platform configuration file and instantiation file, and forming a test platform to avoid manual work. generate.

Benefits of technology

It improves the generation efficiency of the test platform, ensures complete testing of the on-chip network, and reduces the workload of manual intervention and repeated work.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118646689A
    Figure CN118646689A
Patent Text Reader

Abstract

The invention provides a method and a device for generating a network-on-chip test platform, electronic equipment and a medium, relates to the field of network-on-chip, and can automatically fill a template according to a complete architecture information file of the network-on-chip. Obtaining a test platform file capable of covering network interface unit information, verifying an access constraint relationship between the intellectual property core host and the intellectual property core slave, and verifying intellectual property core configuration information; signals of each network interface unit in the to-be-tested design file can be in signal connection with the verification intellectual property core according to the architecture information, and a clock signal and a reset signal are set for the to-be-tested design file according to the clock signal information and the reset signal information, so that an instantiated file is obtained; therefore, the test platform configuration file and the instantiation file can form the test platform, so that the effect of automatically generating the test platform according to the network-on-chip architecture information file is achieved, manual generation is avoided, and the generation efficiency of the test platform can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of network on chip, and in particular to a method, device, electronic equipment and medium for generating a network on chip test platform. Background Art

[0002] Network on Chip (NoC) is a common bus interconnection structure in chips. In related technologies, with the increase in chip size and the number of modules in the chip, the number of NoCs in the chip and the number of interfaces in each NoC have greatly increased, which has led to the fact that the means of manually setting up NoC test platforms can no longer meet the testing needs of NoCs. Summary of the invention

[0003] The purpose of the present invention is to provide a method, device, electronic device and medium for generating a network on chip test platform, which can automatically generate a test platform according to a network on chip architecture information file, avoid manual generation, and thus improve the generation efficiency of the test platform.

[0004] In order to solve the above technical problems, the present invention provides a method for generating an on-chip network test platform, comprising:

[0005] Acquire an architecture information file of the network on chip; wherein the architecture information file includes design file information to be tested, clock signal information, reset signal information of the network on chip, and network interface unit information corresponding to each network interface unit in the network on chip, wherein the network interface unit is used to connect to a host or a slave, and both the host and the slave belong to the verification intellectual property core;

[0006] Acquire a test platform template file, and fill the test platform template file according to the network interface unit information to obtain a test platform configuration file; wherein the test platform configuration file includes an on-chip network definition file, an access constraint file and an intellectual property core configuration file, the on-chip network definition file contains the network interface unit information, the access constraint file contains the access constraint relationship between the host and the slave, and the intellectual property core configuration file records all the configuration information of the verification intellectual property core;

[0007] Acquire the design file to be tested of the network on chip according to the design file to be tested information, connect the signals of each network interface unit in the design file to be tested with the verification intellectual property core, and set the clock signal and reset signal for the design file to be tested according to the clock signal information and the reset signal information to obtain an instantiation file;

[0008] The test platform configuration file and the instantiation file form a test platform.

[0009] Optionally, the network interface unit information includes input network interface unit information and output network interface unit information;

[0010] The input network interface unit information includes the bus protocol, clock domain, reset domain, host serial number, input signal prefix, host communication information, stimulus generation information and host routing information of the input network interface unit;

[0011] The output network interface unit information includes the bus protocol, clock domain, reset domain, slave serial number, output signal prefix, slave communication information, stimulus generation information and slave routing information of the output network interface unit.

[0012] Optionally, the acquiring of the test platform template file, filling the test platform template file according to the network interface unit information, and obtaining the test platform configuration file includes:

[0013] Obtaining a network-on-chip definition template file, an access constraint template file, and an intellectual property core configuration template file;

[0014] Filling the network interface unit information into the on-chip network definition template file, and compiling the filled on-chip network definition template file to obtain the on-chip network definition file;

[0015] Determine the access constraint relationship between the host and the slave according to the stimulus generation information of the input network interface unit, the host routing information and the stimulus generation information of the output network interface unit, the slave routing information, and fill the access constraint relationship into the access constraint template file to obtain the access constraint file;

[0016] The configuration information of the host and the slave is determined respectively according to the host communication information and the slave communication information, and the configuration information is filled into the intellectual property core configuration template file to obtain the intellectual property core configuration file.

[0017] Optionally, it also includes:

[0018] According to the preset hierarchical structure among the on-chip network definition file, the access constraint file, the intellectual property core configuration file and the instantiation file, create folders corresponding to each level;

[0019] The on-chip network definition file, the access constraint file, the intellectual property core configuration file and the instantiation file are stored in folders of corresponding levels.

[0020] Optionally, the signal connection of the signals of each network interface unit in the design file to be tested with the verification intellectual property core, and setting a clock signal and a reset signal for the design file to be tested according to the clock signal information and the reset signal information, comprises:

[0021] Acquire a boundary signal to be matched from the design file to be tested, and determine whether the boundary signal belongs to a bus protocol signal;

[0022] If the boundary signal belongs to the bus protocol signal, matching the signal prefix of the boundary signal with the input signal prefix in the input network interface unit information or the output signal prefix in the output network interface unit information;

[0023] If the signal prefix matches the input signal prefix, determining the host corresponding to the boundary signal according to the host serial number in the input network interface unit information, and performing signal connection between the boundary signal and the corresponding host according to the host communication information in the input network interface unit information;

[0024] If the signal prefix matches the output signal prefix, determining the slave corresponding to the boundary signal according to the slave serial number in the output network interface unit information, and performing signal connection between the boundary signal and the corresponding slave according to the slave communication information in the output network interface unit information;

[0025] If the boundary signal does not belong to the bus protocol signal, determining whether the boundary signal belongs to an input signal;

[0026] If the boundary signal belongs to the input signal, determining whether the boundary signal is a clock signal or a reset signal;

[0027] If the boundary signal is a clock signal, determining a target clock signal corresponding to the boundary signal according to a signal prefix of the boundary signal and the clock signal information, creating the target clock signal according to the clock signal information of the target clock signal, and matching and connecting the boundary signal with the target clock signal;

[0028] If the boundary signal is the reset signal, determining a target reset signal corresponding to the boundary signal according to a signal prefix of the boundary signal and the reset signal information, creating the target reset signal according to the reset signal information of the target reset signal, and matching and connecting the boundary signal with the target reset signal;

[0029] If the boundary signal is not the clock signal and is not the reset signal, then it is not the boundary signal matching signal;

[0030] If the boundary signal does not belong to the input signal, a corresponding intermediate variable is created for the boundary signal, and the boundary signal is matched with the intermediate variable.

[0031] Optionally, determining whether the boundary signal belongs to a bus protocol signal includes:

[0032] Determining whether the boundary signal belongs to a bus protocol signal according to the signal name of the boundary signal;

[0033] The determining whether the boundary signal is a clock signal or a reset signal comprises:

[0034] It is determined whether the boundary signal is a clock signal or a reset signal according to the signal name of the boundary signal.

[0035] Optionally, the acquiring the boundary signal to be matched from the design file to be tested includes:

[0036] Traversing the design file to be tested, obtaining signal prefixes and bit widths of all boundary signals in the design file to be tested, and saving the signal prefixes and bit widths to a boundary signal list;

[0037] The boundary signal to be matched is obtained from the boundary signal list.

[0038] Optionally, it also includes:

[0039] Obtain a test case, and determine the expected result corresponding to the test case according to the access constraint file;

[0040] Using the test case to test the design file to be tested in the test platform to obtain the test result;

[0041] Confirm whether the test is successful based on the expected result and the test result.

[0042] The present invention also provides a device for generating an on-chip network test platform, comprising:

[0043] an acquisition module, configured to acquire an architecture information file of the on-chip network; wherein the architecture information file includes design file information to be tested, clock signal information, reset signal information of the on-chip network, and network interface unit information corresponding to each network interface unit in the on-chip network, wherein the network interface unit is used to connect to a host or a slave, and both the host and the slave belong to a verification intellectual property core;

[0044] A configuration file generation module, used to obtain a test platform template file, and fill the test platform template file according to the network interface unit information to obtain a test platform configuration file; wherein the test platform configuration file includes an on-chip network definition file, an access constraint file and an intellectual property core configuration file, the on-chip network definition file contains the network interface unit information, the access constraint file contains the access constraint relationship between the host and the slave, and the intellectual property core configuration file records all the configuration information of the verification intellectual property core;

[0045] an instantiation file generation module, configured to obtain a design file to be tested of the network on chip according to the design file to be tested information, connect the signals of each network interface unit in the design file to be tested with the verification intellectual property core, and set a clock signal and a reset signal for the design file to be tested according to the clock signal information and the reset signal information, so as to obtain an instantiation file;

[0046] A test platform generation module is used to combine the test platform configuration file and the instantiation file into a test platform.

[0047] The present invention also provides an electronic device, comprising:

[0048] Memory for storing computer programs;

[0049] A processor is used to implement the method for generating an on-chip network test platform as described above when executing the computer program.

[0050] The present invention also provides a computer-readable storage medium, in which computer-executable instructions are stored. When the computer-executable instructions are loaded and executed by a processor, the method for generating an on-chip network test platform as described above is implemented.

[0051] The present invention provides a method for generating an on-chip network test platform, comprising: obtaining an architecture information file of an on-chip network; wherein the architecture information file contains design file information to be tested, clock signal information, reset signal information of the on-chip network and network interface unit information corresponding to each network interface unit in the on-chip network, wherein the network interface unit is used to connect to a host or a slave, and both the host and the slave belong to a verification intellectual property core; obtaining a test platform template file, and filling the test platform template file according to the network interface unit information to obtain a test platform configuration file; wherein the test platform configuration file includes an on-chip network definition file, an access constraint file and an intellectual property core. Configuration file, the on-chip network definition file includes the network interface unit information, the access constraint file includes the access constraint relationship between the host and the slave, and the intellectual property core configuration file records the configuration information of all the verification intellectual property cores; according to the information of the design file to be tested, the design file to be tested of the on-chip network is obtained, the signal of each network interface unit in the design file to be tested is connected with the verification intellectual property core, and the clock signal and reset signal are set for the design file to be tested according to the clock signal information and the reset signal information to obtain an instantiation file; the test platform configuration file and the instantiation file form a test platform.

[0052] It can be seen that the present invention can first obtain the architecture information file of the on-chip network, which can include the design file information to be tested, clock signal information, reset signal information and network interface unit information corresponding to each network interface unit in the on-chip network; then, the present invention can obtain the test platform template file, and fill the test platform template file according to the network interface unit information to obtain the test platform configuration file, that is, it can automatically generate the test platform configuration file by template filling. Among them, the test platform configuration file includes the on-chip network definition file, the access constraint file and the intellectual property core configuration file. The on-chip network definition file contains the network interface unit information, the access constraint file contains the access constraint relationship between the host and the slave, and the intellectual property core configuration file records all configuration information for verifying the intellectual property core. By setting the above-mentioned test platform configuration file, it can be ensured that the on-chip network is fully tested. Subsequently, the present invention can also obtain the design file to be tested of the network on chip according to the information of the design file to be tested, connect the signals of each network interface unit in the design file to be tested with the verification intellectual property core, and set the clock signal and reset signal for the design file to be tested according to the clock signal information and the reset signal information, and obtain an instantiation file, that is, it can automatically connect the design file to be tested of the network on chip with the verification intellectual property core according to the architecture information file, and automatically set the required clock signal and reset signal for the design file to be tested. Finally, the present invention can combine the test platform configuration file and the instantiation file into a test platform, and can automatically generate the test platform of the network on chip according to the architecture information file in a computer-automatic generation manner, avoiding manual generation, thereby improving the generation efficiency of the test platform. The present invention also provides a generation device, electronic device and computer-readable storage medium for a network on chip test platform, which have the above-mentioned beneficial effects. BRIEF DESCRIPTION OF THE DRAWINGS

[0053] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying creative work.

[0054] Figure 1 A flowchart of a method for generating an on-chip network test platform provided by an embodiment of the present invention;

[0055] Figure 2 A schematic diagram of the structure of a test platform provided by an embodiment of the present invention;

[0056] Figure 3 A flow chart for constructing a test platform provided by an embodiment of the present invention;

[0057] Figure 4 A schematic diagram of a test platform generation tool provided by an embodiment of the present invention;

[0058] Figure 5 A structural block diagram of a device for generating a network-on-chip test platform provided by an embodiment of the present invention;

[0059] Figure 6 The present invention provides a structural block diagram of an electronic device. DETAILED DESCRIPTION

[0060] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. 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.

[0061] Network on chip (NoC) is a common bus interconnection structure in chips. In related technologies, with the increase in chip scale and the number of modules in the chip, the number of NoCs in the chip and the number of interfaces in each NoC have greatly increased, which brings great difficulty to the testing and verification of NoCs. Specifically, the challenges currently faced in verifying NoCs are: 1. There are many NoC interfaces and many types of protocols supported. A NoC can connect multiple hosts and slaves, and each host / slave can use different interface protocols, such as AXI (Advanced Extensible Interface), AHB (Advanced High Performance Bus), APB (Advanced Peripheral Bus), NSP (NoC socket protocol, NoC network interface protocol) protocol, etc. Each protocol supports a variety of parameters, which will affect the test platform and stimulus. For example, the AXI protocol supports three types of bursts: FIXED (fixed burst), INCR (incremental burst), and WRAP (wrapped burst). For two hosts whose interface protocols are AXI, if host 1 supports FIXED and host 2 does not support FIXED, host 2 cannot issue a FIXED access. During verification, verification should be performed according to the protocol type and parameters of each interface to ensure the completeness of the verification. 2. There are many on-chip networks. There are often multiple different on-chip networks in a SoC (System on Chip), and multiple different NoCs will be used for different projects. If each one needs to build a test platform separately and develop test stimuli for verification, the workload is undoubtedly huge and there is repetitiveness. Therefore, in the face of the continuous growth in the number and scale of on-chip networks, the means of manually setting up an on-chip network test platform can no longer meet the testing needs of the on-chip network. In view of this, the present invention can provide a method for generating an on-chip network test platform, which can automatically generate a test platform according to an on-chip network architecture information file, avoid manual generation, and thus improve the generation efficiency of the test platform.

[0062] It should be noted that the embodiment of the present invention does not limit the hardware device for executing the method, and can be set according to actual application requirements, such as a personal computer, a server, etc.

[0063] For easier understanding, please refer to Figure 1 , Figure 1 A flowchart of a method for generating an on-chip network test platform provided by an embodiment of the present invention, the method may include:

[0064] S101. Obtain an architecture information file of the on-chip network; wherein the architecture information file includes the on-chip design file information to be tested, clock signal information, reset signal information, and network interface unit information corresponding to each network interface unit in the on-chip network, the network interface unit is used to connect to a host or a slave, and both the host and the slave belong to the verification intellectual property core.

[0065] In an embodiment of the present invention, the architecture information file is filled in by the tester to fully describe the communication details of each interface in the on-chip network, and can be used as the basis for generating the test platform. The content contained in the architecture information file needs to be rich enough to reliably connect the on-chip network with the host and the slave, and to set necessary signals such as clock signals and reset signals for the on-chip network. The embodiment of the present invention does not limit the specific content that the architecture information file can contain, and can be set according to actual application requirements. For example, the architecture information file can include the design file information to be tested (DUT information, Design Under Test, design to be tested) of the on-chip network, clock signal information (CLK, Clock), reset signal information (RESET) and network interface unit information of each network interface unit in the on-chip network. As mentioned above, since different network interface units can use different communication protocols, the network interface unit information needs to cover various types of bus protocols that can be used by each network interface unit, such as AXI, AHB, APB, NSP, etc. Furthermore, the network interface unit information can be divided into the input network interface unit information of the input network interface unit (Initiator NIU) and the output network interface unit information of the output network interface unit (Target NIU). The input network interface unit is connected to the host, and the output network interface unit is connected to the slave. When performing on-chip network testing, both the host and the slave belong to the verification intellectual property core (verification IP core, intellectual property). For ease of understanding, the following table shows a possible form of the architecture information file:

[0066] Table 1 Architecture information file

[0067]

[0068]

[0069] Among them, the name in the design file information to be tested (DUT) is the file name, and the path is the file path. The frequency in the clock signal information (CLK) refers to the clock frequency, and different clock signals may correspond to different clock frequencies. The name in the input network interface unit information (Initiator NIU) represents the input signal prefix, and the parameters represent various parameters of the input signal. The name in the output network interface unit information (Target NIU) represents the output signal prefix, and the parameters represent various parameters of the output signal. In order to cover various communication situations of the host and the slave, the input network interface unit information in the embodiment of the present invention may include the bus protocol, clock domain, reset domain, host serial number, input signal prefix, host communication information, stimulus generation information and host routing information of the input network interface unit; and the output network interface unit information may include the bus protocol, clock domain, reset domain, slave serial number, output signal prefix, slave communication information, stimulus generation information and slave routing information of the output network interface unit. It is understandable that the information types included in the input network interface unit information and the output network interface unit information corresponding to different bus protocols may be different, and in particular, the types of stimulus generation information that may be included in the input network interface unit information may be different.

[0070] The following is an introduction to the contents of the input network interface unit information based on the specific bus protocol:

[0071] 1. AXI input network interface unit:

[0072] If the bus protocol used by the input network interface unit is AXI, the input network interface unit information corresponding to the unit may include the clock domain (clk_domain) where the input network interface unit is located, the reset domain (rst_domain) where the unit is located, the connected AXI Master VIP serial number (init_id), the signal prefix (signal_prefix) of the input network interface unit in the on-chip network design, the data bit width (wdata), the address bit width (waddr), the ID bit width (wid), whether writing is supported (enwr), whether reading is supported (enrd), whether Narrow transmission is supported (narrowband transmission, IsNarrow), the minimum size of Narrow transmission (MinNarrowSize), whether Fixed burst is supported (IsFixed), whether Wrapper burst is supported (IsWrapper), the maximum burst length (MaxBurstLen), which AXI Slaves can be accessed (AxiTarg_AccArray), which AHBSlave can be accessed (AhbTarg_AccArray), and which APB can be accessed Slave (ApbTarg_AccArray), which NSPSlave (NspTarg_AccArray) can be accessed. It should be pointed out that the data bit width, address bit width, and ID bit width belong to the host communication information; whether writing is supported, whether reading is supported, whether Narrow transmission is supported, the minimum size of Narrow transmission, whether Fixed burst is supported, whether Wrapper burst is supported, and the maximum burst length belong to the stimulus generation information; which AXI slaves can be accessed, which AHB slaves can be accessed, which APB slaves can be accessed, and which NSP slaves can be accessed belong to the host routing information. In the subsequent introduction of the input network interface unit information, the categories to which each information belongs are similar to here, and will not be repeated later. A possible AXI input network interface unit information is shown in the following table:

[0073] Table 2 AXI input network interface unit information

[0074]

[0075]

[0076] 2. AHB input network interface unit:

[0077] If the bus protocol used by the input network interface unit is AHB, the input network interface unit information corresponding to the unit may include the clock domain (clk_domain) where the input network interface unit is located, the reset domain (rst_domain) where the input network interface unit is located, the connected AHB Master VIP serial number (init_id), the signal prefix (signal_prefix) of the input network interface unit in the on-chip network design, the data bit width (wdata), the address bit width (waddr), whether writing is supported (enwr), whether reading is supported (enrd), whether Narrow transmission is supported (IsNarrow), the minimum size of Narrow transmission (MinNarrowSize), whether Single burst is supported (IsSingle), whether INCR burst is supported (IsIncr), whether Wrapper burst is supported (IsWrapper), the maximum burst length (MaxBurstLen), which AXI Slaves can be accessed (AxiTarg_AccArray), which AHB Slaves can be accessed (AhbTarg_AccArray), which APB Slaves can be accessed (ApbTarg_AccArray), and which NSPs can be accessed Slave (NspTarg_AccArray). A possible AHB input network interface unit information is shown in the following table:

[0078] Table 3 AHB input network interface unit information

[0079]

[0080]

[0081] 3. APB input network interface unit:

[0082] If the bus protocol used by the input network interface unit is APB, the input network interface unit information corresponding to the unit may include the clock domain (clk_domain) where the input network interface unit is located, the reset domain (rst_domain) where the input network interface unit is located, the VIP serial number (init_id) of the connected APB Master, the signal prefix (signal_prefix) of the input network interface unit in the on-chip network design, the data bit width (wdata), the address bit width (waddr), whether writing is supported, whether writing is supported (enwr), whether reading is supported (enrd), which AHB Slave can be accessed (AhbTarg_AccArray), which APB Slave can be accessed (ApbTarg_AccArray), and which NSP Slave can be accessed (NspTarg_AccArray). A possible APB input network interface unit information is shown in the following table:

[0083] Table 4 APB input network interface unit information

[0084]

[0085] 4. NSP input network interface unit:

[0086] If the bus protocol used by the input network interface unit is NSP, the input network interface unit information corresponding to the unit may include the clock domain (clk_domain) where the input network interface unit is located, the reset domain (rst_domain) where it is located, the connected NSP Master VIP serial number (init_id), the signal prefix (signal_prefix) of the input network interface unit in the on-chip network design, the data bit width (wdata), the address bit width (waddr), the sequence ID bit width (wSeqId), whether writing is supported (enwr), whether reading is supported (enrd), the maximum number of pending transactions (nPendingTrans), the maximum burst length (in bytes) (MaxBurstLenB), whether Fixed burst is supported (IsFixed), the maximum number of transferts in a transaction (MaxNbTransTerts), which AXI Slaves can be accessed (AxiTarg_AccArray), which AHB Slaves can be accessed (AhbTarg_AccArray), and which APBs can be accessed Slave (ApbTarg_AccArray), which NSP Slave can access (NspTarg_AccArray). A possible NSP input network interface unit information is shown in the following table:

[0087] Table 5 NSP input network interface unit information

[0088]

[0089] The following is an introduction to the content that can be covered by the output network interface unit information based on the specific bus protocol. The parameters corresponding to the four protocols AXI, AHB, APB, and NSP in the output network interface unit information are the same, which can include the clock domain (clk_domain) where the output network interface unit is located, the reset domain (rst_domain), the connected AXI / AHB / APB / NSPSlave VIP serial number (targ_id), the signal prefix (signal_prefix) of the output network interface unit in the on-chip network design, the data bit width (wdata), the address bit width (waddr), whether it supports writing (enwr), whether it supports reading (enrd), whether it supports Fixed mode (IsFixed), the address range initiated by the Master side (InitAddrRegion), and the address range received by the Slave side (TargAddrRegion). It should be pointed out that the data bit width, address bit width, and ID bit width belong to the slave communication information; whether to support writing, whether to support reading, whether to support Narrow transmission, the minimum size of Narrow transmission, whether to support Fixed burst, whether to support Wrapper burst, and the maximum burst length belong to the stimulus generation information; the address range initiated by the Master side and the address range received by the Slave side belong to the slave routing information. A possible AXI output network interface unit information is shown in the following table:

[0090] Table 6 AXI output network interface unit information

[0091]

[0092] It can be seen that the architecture information file provided by the embodiment of the present invention can cover the parameters of various bus protocols that can be used by the network interface unit, and thus can effectively cover various scenarios that need to be tested by the on-chip network.

[0093] S102. Obtain a test platform template file, and fill in the test platform template file according to the network interface unit information to obtain a test platform configuration file; wherein, the test platform configuration file includes an on-chip network definition file, an access constraint file, and an intellectual property core configuration file, the on-chip network definition file contains the network interface unit information, the access constraint file contains the access constraint relationship between the host and the slave, and the intellectual property core configuration file records all configuration information for verifying the intellectual property core.

[0094] After obtaining the architecture information file, the embodiment of the present invention can also obtain the test platform template file, and fill the test platform template file according to the network interface unit information in the architecture information file to obtain the test platform configuration file. In order to improve the completeness of the on-chip network test, the test platform configuration file provided by the embodiment of the present invention may include an on-chip network definition file (NoC Defination Package), an access constraint file (datapath constraint) and an intellectual property core configuration file (configuration). Among them, the on-chip network definition file contains all network interface unit information, and the components and objects in the entire test platform can directly obtain the network interface unit information in the file. The constraint access file contains the access constraint relationship between the host and the slave. It can be understood that different hosts can access different slaves through the on-chip network to be tested, and different hosts access different slaves. That is, the on-chip network constrains the way the host accesses the slave. Verifying that the host can access the slave according to the expected constraints and the slave can respond to the host according to the expected constraints is an important content of the on-chip network test verification, so the embodiment of the present invention also provides the above-mentioned access constraint file. The intellectual property core configuration file records all configuration information of the intellectual property core verification, and the configuration information determines how the host and the slave access the corresponding network interface unit.

[0095] It is understandable that the above-mentioned network on chip definition file, access constraint file and intellectual property core configuration file are all provided with corresponding template files, and each template file needs to be filled in a corresponding manner. The embodiment of the present invention does not limit the specific template file and the template file filling method, but only needs to ensure that the required information is recorded in each test platform configuration file.

[0096] Based on this, a test platform template file is obtained, and the test platform template file is filled according to the network interface unit information to obtain a test platform configuration file, which may include:

[0097] Step 11: Obtain the on-chip network definition template file, access constraint template file, and intellectual property core configuration template file;

[0098] Step 12: Fill the network interface unit information into the on-chip network definition template file, and compile the filled on-chip network definition template file to obtain the on-chip network definition file;

[0099] Step 13: Determine the access constraint relationship between the host and the slave according to the stimulus generation information of the input network interface unit, the host routing information and the stimulus generation information of the output network interface unit, the slave routing information, and fill the access constraint relationship into the access constraint template file to obtain the access constraint file;

[0100] Step 14: Determine the configuration information of the host and the slave respectively according to the host communication information and the slave communication information, and fill the configuration information into the intellectual property core configuration template file to obtain the intellectual property core configuration file.

[0101] For ease of understanding, the following is an implementation of template filling. Taking the modification of the number of intellectual property cores required for verification as an example, the following is a part of the template file:

[0102] / / Modify the number of AXI host VIPs

[0103] {%if(info["AXI"]["master"]|length)>0%}

[0104] int AxiMstNb={{info["AXI"]["master"]|length}};

[0105] {% endif %}

[0106] / / Modify the number of AXI slave VIPs

[0107] {%if(info["AXI"]["slave"]|length)>0%}

[0108] int AxiSlvNb={{info["AXI"]["slave"]|length}};

[0109] {% endif %}

[0110] / / Modify the number of AHB host VIPs

[0111] {%if(info["AHB"]["master"]|length)>0%}

[0112] int AhbMstNb={{info["AHB"]["master"]|length}};

[0113] {% endif %}

[0114] / Modify the number of AHB slave VIPs

[0115] {%if(info["AHB"]["slave"]|length)>0%}

[0116] int AhbSlvNb={{info["AHB"]["slave"]|length}};

[0117] {% endif %}

[0118] …

[0119] The code logic of the above template can be briefly described as follows: the network interface unit information is stored in the info structure, the number of AXI hosts in the info structure is determined, if it is greater than 0, AxiMstNb is defined as the number of AXI hosts; the number of AXI slaves in the info structure is determined, if it is greater than 0, AxiSlvNb is defined as the number of AXI slaves; the number of AHB hosts in the info structure is determined, if it is greater than 0, AhbMstNb is defined as the number of AHB hosts; the number of AHB slaves in the info structure is determined, if it is greater than 0, AhbMstNb is defined as the number of AHB slaves. The setting method of the number of APB host / slave VIP and NSP host / slave VIP is similar to this. It can be seen that each test platform template file is provided with a corresponding template filling logic, and the computer can execute the logic to fill the information in the architecture information file into the test platform template file to obtain the test platform configuration file.

[0120] S103, obtaining the design file to be tested of the on-chip network according to the information of the design file to be tested, connecting the signals of each network interface unit in the design file to be tested with the verification intellectual property core, and setting the clock signal and reset signal for the design file to be tested according to the clock signal information and reset signal information to obtain an instantiation file.

[0121] In the embodiment of the present invention, in addition to generating a test platform configuration file, more importantly, the boundary signals contained in the design file to be tested of the on-chip network can be automatically connected to the host and slave according to the architecture information file, and the necessary clock signals and reset signals can be automatically set for the design file to be tested. In this way, after completing the on-chip network design, the tester does not need to manually connect it to the corresponding host and slave, but only needs to let the computer automatically connect it, thereby improving the generation efficiency of the test platform. The specific process of signal connection will be introduced below.

[0122] Based on this, connecting the signals of each network interface unit in the design file to be tested with the verification intellectual property core, and setting the clock signal and reset signal for the design file to be tested according to the clock signal information and the reset signal information may include:

[0123] Step 21: Obtain the boundary signal to be matched from the design file to be tested, and determine whether the boundary signal belongs to the bus protocol signal; if so, proceed to step 22; if not, proceed to step 25.

[0124] In an embodiment of the present invention, signals that need to be input from the outside and that need to be output to the outside in the design file to be tested are called boundary signals. The interfaces corresponding to these boundary signals need to be connected to the host, slave, clock signal source, reset signal source, or need to be assigned a sideband input source or a sideband output object. Among them, the sideband input source and the sideband output object are different from the host and the slave, and need to be set up additionally. The embodiment of the present invention does not limit how to obtain the boundary signal from the design file to be tested. For example, it can be determined according to the variable type of the signal (such as input input, output output), and the relevant technology of DUT can be referred to. In addition, in order to facilitate the acquisition of boundary signals and improve the matching efficiency of boundary signals, the embodiment of the present invention can also pre-set a boundary signal list, and save the signal prefixes and bit widths of all boundary signals obtained by traversing the design file to be tested into the boundary signal list, so that the boundary signal to be matched can be obtained from the list.

[0125] Based on this, obtaining the boundary signal to be matched from the design file to be tested may include:

[0126] Step 1: traverse the design file to be tested, obtain the signal prefix and bit width of all boundary signals in the design file to be tested, and save the signal prefix and bit width to the boundary signal list;

[0127] Step 2: Get the boundary signal to be matched from the boundary signal list.

[0128] Furthermore, after obtaining the boundary signal to be matched, the embodiment of the present invention can first determine whether the boundary signal belongs to the bus protocol signal. If it is determined that it belongs to the bus protocol signal, it can be connected to the host and the slave by signal; conversely, if it is determined that it does not belong to the bus protocol signal, it can be matched with the clock signal, reset signal or other sideband input source and sideband output object. For easy identification, the bus protocol signal in the design file to be tested can be set with a special signal name. Furthermore, it can be determined whether the boundary signal belongs to the bus protocol signal based on the signal name of the boundary signal to be matched.

[0129] Step 22: If the boundary signal belongs to the bus protocol signal, match the signal prefix of the boundary signal with the input signal prefix in the input network interface unit information or the output signal prefix in the output network interface unit information; if the signal prefix matches the input signal prefix, proceed to step 23; if the signal prefix matches the output signal prefix, proceed to step 24.

[0130] If it is determined that the boundary signal is a bus protocol signal, the embodiment of the present invention can further compare the signal prefix of the boundary signal with the input signal prefix in the input network interface unit information or the output signal prefix in the output network interface unit information to determine the host or slave corresponding to the boundary signal.

[0131] Step 23: If the signal prefix matches the input signal prefix, the host corresponding to the boundary signal is determined according to the host serial number in the input network interface unit information, and the boundary signal is connected to the corresponding host according to the host communication information in the input network interface unit information.

[0132] When it is determined that the signal prefix of the boundary signal matches the input signal prefix in a group of input network interface unit information, the host corresponding to the boundary signal can be determined according to the host serial number in the group of input network interface unit information, and the boundary signal can be connected with the host according to the host communication information (data bit width, address bit width, id bit width of AXI protocol) in the group of input network interface unit information.

[0133] Step 24: If the signal prefix matches the output signal prefix, the slave corresponding to the boundary signal is determined according to the slave serial number in the output network interface unit information, and the boundary signal is connected to the corresponding slave according to the slave communication information in the output network interface unit information.

[0134] When it is determined that the signal prefix of the boundary signal matches the input signal prefix in a group of output network interface unit information, the slave corresponding to the boundary signal can be determined according to the slave serial number in the group of output network interface unit information, and the boundary signal can be connected with the slave according to the slave communication information (data bit width, address bit width) in the group of output network interface unit information.

[0135] Step 25: If the boundary signal does not belong to the bus protocol signal, determine whether the boundary signal belongs to the input signal; if it does, proceed to step 26; if not, proceed to step 30.

[0136] If it is determined that the boundary signal does not belong to the bus protocol signal, this step needs to determine whether the boundary signal belongs to the input signal. This is because the clock signal, reset signal, and sideband input signal are all input signals, and only the sideband output signal is an output signal. Therefore, this step can quickly separate the clock signal, reset signal, sideband input signal and sideband output signal.

[0137] It should be pointed out that whether the boundary signal belongs to the input signal can be determined here according to the variable type of the signal (input, output).

[0138] Step 26: If the boundary signal belongs to the input signal, determine whether the boundary signal is a clock signal or a reset signal; if it is a clock signal, go to step 27; if it is a reset signal, go to step 28; if it is neither a clock signal nor a reset signal, go to step 29.

[0139] If it is determined that the boundary signal belongs to an input signal, the embodiment of the present invention can further determine whether it belongs to a clock signal or a reset signal. For easy identification, the clock signal and reset signal in the design file to be tested can be set with special signal names, and different clock signals and reset signals are set with different signal names. Furthermore, it can be determined whether the boundary signal is a clock signal or a reset signal based on the signal name of the boundary signal.

[0140] Step 27: If the boundary signal is a clock signal, determine the target clock signal corresponding to the boundary signal according to the signal prefix and clock signal information of the boundary signal, create the target clock signal according to the clock signal information of the target clock signal, and match and connect the boundary signal with the target clock signal.

[0141] When it is determined that the boundary signal belongs to a clock signal, the target clock signal corresponding to the boundary signal can be determined based on the signal prefix and clock signal information of the boundary signal, the target clock signal can be created based on the clock signal information (such as clock frequency) of the target clock signal, and the boundary signal can be matched and connected with the target clock signal.

[0142] Step 28: If the boundary signal is a reset signal, determine the target reset signal corresponding to the boundary signal according to the signal prefix of the boundary signal and the reset signal information, create the target reset signal according to the reset signal information of the target reset signal, and match and connect the boundary signal with the target reset signal.

[0143] When it is determined that the boundary signal belongs to a reset signal, a corresponding reset signal may be set for the boundary signal.

[0144] Step 29: If the boundary signal is neither a clock signal nor a reset signal, it is not a boundary signal matching signal.

[0145] If it is determined that the input boundary signal is neither a clock signal nor a reset signal, it can be determined that it is a sideband input signal. Since the sideband input source requires additional settings, the boundary signal matching signal can be temporarily not provided here.

[0146] Step 30: If the boundary signal does not belong to the input signal, create a corresponding intermediate variable for the boundary signal, and match the boundary signal with the intermediate variable.

[0147] If it is determined that the input boundary signal does not belong to the bus protocol signal but to the output signal, it can be determined that the boundary signal belongs to the sideband output signal. At this time, an intermediate variable can be created for the boundary signal to use the intermediate variable to record the output signal value of the boundary signal.

[0148] It can be seen that by setting the above steps, the embodiment of the present invention can automatically perform signal matching processing on all boundary signals in the design file to be tested, thereby saving the generation time of the test platform.

[0149] Furthermore, since each file has a different level relative to the test platform, in order to facilitate testers to find and manage various files in the test platform, folders corresponding to each level can be created according to the preset level results of the above-mentioned files, and the files of the test platform can be stored in folders of the corresponding level.

[0150] Based on this, the method may further include:

[0151] Step 41: Create folders corresponding to each level according to the preset hierarchical structure among the on-chip network definition file, the access constraint file, the intellectual property core configuration file and the instantiation file;

[0152] Step 42: Store the on-chip network definition file, access constraint file, intellectual property core configuration file and instantiation file into folders of corresponding levels.

[0153] S104. Combining the test platform configuration file and the instantiation file into a test platform.

[0154] In this step, the test platform configuration file and the instantiation file can be combined into a test platform for the on-chip network to be tested. It should be noted that the embodiment of the present invention does not limit whether it is necessary to set a component file for verifying the intellectual property core separately in the test platform file. When the component file can be referenced from the outside, it is not necessary to set the component file in the test platform; in order to facilitate project management for testers, the above component file can also be set in the test platform file.

[0155] Based on the above embodiments, the present invention can first obtain the architecture information file of the on-chip network, which can include the design file information to be tested, clock signal information, reset signal information and network interface unit information corresponding to each network interface unit in the on-chip network; then, the present invention can obtain the test platform template file, and fill the test platform template file according to the network interface unit information to obtain the test platform configuration file, that is, the test platform configuration file can be automatically generated by template filling. Among them, the test platform configuration file includes an on-chip network definition file, an access constraint file and an intellectual property core configuration file. The on-chip network definition file contains network interface unit information, the access constraint file contains the access constraint relationship between the host and the slave, and the intellectual property core configuration file records all configuration information for verifying the intellectual property core. By setting the above test platform configuration file, it can be ensured that the on-chip network is fully tested. Subsequently, the present invention can also obtain the design file to be tested of the network on chip according to the information of the design file to be tested, connect the signals of each network interface unit in the design file to be tested with the verification intellectual property core, and set the clock signal and reset signal for the design file to be tested according to the clock signal information and the reset signal information, and obtain an instantiation file, that is, it can automatically connect the design file to be tested of the network on chip with the verification intellectual property core according to the architecture information file, and automatically set the required clock signal and reset signal for the design file to be tested. Finally, the present invention can form a test platform with the test platform configuration file and the instantiation file, and can automatically generate the test platform of the network on chip according to the architecture information file in a computer-automatic generation manner, avoiding manual generation, thereby improving the generation efficiency of the test platform.

[0156] Based on the above embodiment, the platform framework of the above test platform is introduced below based on a specific schematic diagram. The test platform provided by the embodiment of the present invention simulates the behavior of each host and slave by integrating and verifying the intellectual property core, and is specifically composed of three parts: NoC Defination package, TEST (test level), and ENV (working environment level). Figure 2 As shown, Figure 2 A schematic diagram of the structure of a test platform provided by an embodiment of the present invention.

[0157] The test platform file is divided into two parts:

[0158] 1) Files that instantiate the DUT (instantiation files)

[0159] Responsible for connecting the DUT to the corresponding VIP and providing clock and reset. Figure 2In the DUT, the Inititaor0NIU~InitiatorN NIU are connected to the Master0 VIP~MasterN VIP respectively, and the Target0 NIU~TargetN NIU of the DUT are connected to the Slaver0 VIP~SlaveN VIP respectively, and corresponding clocks and resets are provided for the DUT and these VIPs to ensure their normal operation.

[0160] 2) The rest of the files that make up the testbench

[0161] The embodiment of the present invention provides a test platform template file, which contains these other files. The template file content is modified according to the architecture information, and a new file is finally generated. The template file mainly includes:

[0162] 2.1) NoC Defination package file (on-chip network definition file)

[0163] Define all NIU information, namely Figure 2 The NoC Defination package in the test platform is compiled separately into a package so that the components and objects in the entire test platform can directly obtain the information in the package; and the entire test platform is based on the information in this file, including generating stimuli and checking whether the NoC behavior is correct. It is worth pointing out that as long as the architecture information remains unchanged, the NoC Defination package does not need to be recompiled. If the rest of the content in the test platform changes, such as the VIP component file, you only need to recompile the test platform, without recompiling the NoC Definationpackage file, which can save the compilation time of the test platform.

[0164] 2.2) Datapath constraint file (access constraint file)

[0165] Constraints are imposed on how each Master accesses the Slaves, such as which Slaves can be accessed, read access or write access, the burst type of access, etc.

[0166] 2.3) configuration file (verification intellectual property core configuration file)

[0167] Configuration information for each VIP, namely Figure 2Including AXI configuration of AXI Master / Slave VIP, AHB configuration of AHB Master / Slave VIP, APB configuration of APBMaster / Slave VIP, and NSP configuration of NSP Master / Slave VIP.

[0168] 2.4)env file (verification of intellectual property core component file)

[0169] This file contains the VIP component files, which are used to instantiate and connect VIP components. Figure 2 Master0~MasterN VIPs and Slave0~SlaveN VIPs in the VIP, and configure the configuration information of each VIP to the corresponding VIP, etc.

[0170] Based on the above embodiment, since the embodiment of the present invention has added an access constraint file to the test platform configuration file, the access constraint conditions between the host and the slave can be expected. Therefore, when a test case is obtained, the expected result corresponding to the test case can be determined in advance according to the access constraint conditions. Then, when the test result generated by the on-chip network for the test case is obtained, it can be determined whether the test result is the same as the expected result, so that the communication function of the on-chip network can be quickly tested. Based on this, the method can also include:

[0171] S201, obtaining a test case, and determining an expected result corresponding to the test case according to an access constraint file;

[0172] S202, using the test case to test the design file to be tested in the test platform to obtain a test result;

[0173] S203: Confirm whether the test is successful based on the expected result and the test result.

[0174] It should be noted that the embodiments of the present invention are not limited to specific test cases and can be set according to actual application requirements.

[0175] Based on the above embodiments, the above test platform generation method is fully introduced below based on a specific flowchart. For a system on a chip (SoC), it is often composed of multiple subsystems, and correspondingly there are multiple on-chip networks. The on-chip network is responsible for the connection and communication between each module and subsystem in each subsystem. The verification of the on-chip network is crucial to the reliability of the entire on-chip system. The present invention implements a method for generating an on-chip network test platform, which can provide convenience for verification engineers, so that verification engineers can quickly and universally build a test platform when faced with various on-chip networks. The flowchart of the present invention is shown in FIG. Figure 3 As shown:

[0176] 1. Fill in the architecture information according to the architecture information file format;

[0177] 2. Generate all the files that make up the test platform. This step is divided into two parts:

[0178] 1) Based on the template file, modify the template file according to the architecture information to generate a new file;

[0179] 2) Generate instantiated DUT files based on architecture information by extracting DUT boundary signals. The specific steps are as follows:

[0180] Step 1: Find the top-level file of DUT according to the module name and path of DUT in the architecture information. Traverse the top-level file of DUT, extract the boundary signals and signal widths of DUT, and store all boundary signals and bit widths in a data structure;

[0181] Step 2: Traverse the data structure in step 1, extract each boundary signal, and go to step 3;

[0182] Step 3: If the signal is an AXI protocol signal, based on the signal prefix and architecture information, it can be determined that it belongs to the AXIInitiator NIU or AXI Target NIU, so it is connected to the AXI Master / Slave VIP serial number. Finally, match the signal with the signal in the AXI Master / Slave VIP; if not, go to step 4;

[0183] Step 4: If the signal is an AHB protocol signal, it can be determined that it belongs to AHBInitiator NIU or AHB Target NIU based on the signal prefix and architecture information, so it is connected to the AHB Master / Slave VIP number. Finally, match the signal with the signal in the AHB Master / Slave VIP; if not, go to step 5;

[0184] Step 5: If the signal is an APB protocol signal, it can be determined that it belongs to the APBInitiator NIU or APB Target NIU based on the signal prefix and architecture information, so it is connected to the APB Master / Slave VIP number. Finally, match the signal with the signal in the APB Master / Slave VIP; if not, go to step 6;

[0185] Step 6: If the signal is an NSP protocol signal, it can be determined that it belongs to NSP Initiator NIU or NSP Target NIU based on the signal prefix and architecture information, so it is connected to the NSP Master / Slave VIP number. Finally, match the signal with the signal in the NSP Master / Slave VIP; if not, go to step 7;

[0186] Step 7: If the signal is not an input signal, and because it is not an AXI / AHB / APB / NSP protocol signal, it is a sideband signal output by the DUT, then the matching signal is an intermediate variable with the same name, which will be defined in this file; if so, proceed to step 8;

[0187] Step 8: If the signal is a clock or reset signal, the matching signal is the corresponding clock or reset signal defined in this file. This file will define all clock and reset signals according to the architecture information, and provide drive for the clock signal to ensure the output of the corresponding frequency clock; if not, go to step 9;

[0188] Step 9: This signal is the input sideband signal and is temporarily matched to 0.

[0189] Step 10: Repeat steps 3 to 9 until all boundary signals of the data structure in step 1 are traversed. Generate a file for instantiating the DUT based on the type and serial number of the connected VIP and the matching signal.

[0190] The functional structure diagram of the present invention is as follows Figure 4 shown.

[0191] The NoC testbench generation tool (NoC Testbench Generation Tool) of the present invention includes two functional modules: info_parse (architecture information extraction module) and tb_gen (testbench generation module).

[0192] 1.info_parse:

[0193] The architecture information extraction module includes a submodule extrct info and a data structure info structure. The submodule extrct info extracts the input architecture signal information and records it in the data structure info structure for the convenience of subsequent modules.

[0194] 2.tb_gen:

[0195] The test platform generation module contains 5 sub-modules: tb_hier_gen, replace_files_gen, dut_signal_parse, signal_match, th_file_gen, and a set of template files tb files template.

[0196] 2.1) tb_hier_gen generates empty folders according to the hierarchical structure of the test platform files;

[0197] 2.2) replace_files_gen traverses each file in the template file tb files template, modifies the template file according to the info structure in 1, generates new files with the same name, and places them in the corresponding folder in 2.1).

[0198] 2.3) dut_signal_parse finds the top-level file of DUT according to its module name and path, traverses all its input and output signals, and records the signal name and signal bit width in a data structure;

[0199] 2.4) signal_match traverses each signal of the data structure in 2.3), and matches the signal with the VIP signal / clock signal / reset signal, etc. according to the signal name and the infostructure information in 1;

[0200] 2.5) th_file_gen generates the th file of the instantiated DUT according to the matching signal in 2.4)

[0201] The files generated by 2.2) and 2.5) ultimately constitute the test platform.

[0202] The following is an introduction to a generation device, electronic device, computer program product, and computer-readable storage medium for an on-chip network test platform provided in an embodiment of the present invention. The generation device, electronic device, computer program product, and computer-readable storage medium for the on-chip network test platform described below and the generation method for the on-chip network test platform described above can be referenced to each other.

[0203] Please refer to Figure 5 , Figure 5A structural block diagram of a device for generating a network-on-chip test platform provided by an embodiment of the present invention, the device may include:

[0204] The acquisition module 501 is used to acquire the architecture information file of the on-chip network; wherein the architecture information file includes the design file information to be tested, clock signal information, reset signal information and network interface unit information corresponding to each network interface unit in the on-chip network, the network interface unit is used to connect with the host or the slave, and the host and the slave are both verification intellectual property cores;

[0205] Configuration file generation module 502, used to obtain a test platform template file, and fill the test platform template file according to the network interface unit information to obtain a test platform configuration file; wherein the test platform configuration file includes an on-chip network definition file, an access constraint file and an intellectual property core configuration file, the on-chip network definition file contains the network interface unit information, the access constraint file contains the access constraint relationship between the host and the slave, and the intellectual property core configuration file records all configuration information of the verified intellectual property core;

[0206] The instantiation file generation module 503 is used to obtain the design file to be tested of the on-chip network according to the design file to be tested information, connect the signal of each network interface unit in the design file to be tested with the verification intellectual property core, and set the clock signal and reset signal for the design file to be tested according to the clock signal information and reset signal information to obtain the instantiation file;

[0207] The test platform generation module 504 is used to compose a test platform from the test platform configuration files and the instantiation files.

[0208] Optionally, the configuration file generating module 502 may include:

[0209] A template acquisition submodule is used to acquire an on-chip network definition template file, an access constraint template file, and an intellectual property core configuration template file;

[0210] A first filling submodule is used to fill the network interface unit information into the on-chip network definition template file, and compile the filled on-chip network definition template file to obtain the on-chip network definition file;

[0211] A second filling submodule is used to determine the access constraint relationship between the host and the slave according to the stimulus generation information of the input network interface unit, the host routing information and the output network interface unit, the stimulus generation information, the slave routing information, and fill the access constraint relationship into the access constraint template file to obtain the access constraint file;

[0212] The third filling submodule is used to determine the configuration information of the host and the slave respectively according to the host communication information and the slave communication information, and fill the configuration information into the intellectual property core configuration template file to obtain the intellectual property core configuration file.

[0213] Optionally, the device may further include:

[0214] A folder creation module, used to create folders corresponding to each level according to a preset hierarchical structure among an on-chip network definition file, an access constraint file, an intellectual property core configuration file, and an instantiation file;

[0215] The file storage module is used to store the on-chip network definition file, access constraint file, intellectual property core configuration file and instantiation file in folders of corresponding levels.

[0216] Optionally, the instantiation file generation module 503 may include:

[0217] The first judgment submodule is used to obtain the boundary signal to be matched from the design file to be tested, and to judge whether the boundary signal belongs to the bus protocol signal;

[0218] A second judgment submodule is used for matching the signal prefix of the boundary signal with the input signal prefix in the input network interface unit information or the output signal prefix in the output network interface unit information if the boundary signal belongs to the bus protocol signal;

[0219] A first signal matching submodule, for determining a host corresponding to the boundary signal according to a host serial number in the input network interface unit information if the signal prefix matches the input signal prefix, and performing signal connection between the boundary signal and the corresponding host according to the host communication information in the input network interface unit information;

[0220] A second signal matching submodule, for determining the slave corresponding to the boundary signal according to the slave serial number in the output network interface unit information if the signal prefix matches the output signal prefix, and performing signal connection between the boundary signal and the corresponding slave according to the slave communication information in the output network interface unit information;

[0221] A third judgment submodule, used for judging whether the boundary signal belongs to an input signal if the boundary signal does not belong to a bus protocol signal;

[0222] A fourth judgment submodule, used for judging whether the boundary signal is a clock signal or a reset signal if the boundary signal belongs to an input signal;

[0223] A third signal matching submodule is used for, if the boundary signal is a clock signal, determining a target clock signal corresponding to the boundary signal according to a signal prefix and clock signal information of the boundary signal, creating a target clock signal according to the clock signal information of the target clock signal, and matching and connecting the boundary signal with the target clock signal;

[0224] A fourth signal matching submodule, for determining, if the boundary signal is a reset signal, a target reset signal corresponding to the boundary signal according to a signal prefix of the boundary signal and reset signal information, creating a target reset signal according to the reset signal information of the target reset signal, and matching and connecting the boundary signal with the target reset signal;

[0225] a fifth signal matching submodule, configured to match the boundary signal to a signal other than a clock signal and a reset signal if the boundary signal is neither a clock signal nor a reset signal;

[0226] The sixth signal matching submodule is used to create a corresponding intermediate variable for the boundary signal if the boundary signal does not belong to the input signal, and match the boundary signal with the intermediate variable.

[0227] Optionally, the first judgment submodule may be used to:

[0228] Determine whether the boundary signal belongs to the bus protocol signal according to the signal name of the boundary signal;

[0229] The fourth judgment submodule can be used to:

[0230] Determine whether the boundary signal is a clock signal or a reset signal based on the signal name of the boundary signal.

[0231] Optionally, the first judgment submodule may include:

[0232] The boundary signal traversal submodule is used to traverse the design file to be tested, obtain the signal prefix and bit width of all boundary signals in the design file to be tested, and save the signal prefix and bit width to the boundary signal list;

[0233] The boundary signal acquisition submodule is used to obtain the boundary signal to be matched from the boundary signal list.

[0234] Optionally, the device may further include:

[0235] An expected result determination module is used to obtain a test case and determine the expected result corresponding to the test case according to the access constraint file;

[0236] A test module, used to test the design file to be tested in a test platform using a test case to obtain a test result;

[0237] The test result verification module is used to confirm whether the test is successful based on the expected results and test results.

[0238] Please refer to Figure 6 , Figure 6 This is a structural block diagram of an electronic device provided in an embodiment of the present invention. The embodiment of the present invention provides an electronic device 60, including a processor 61 and a memory 62; wherein the memory 62 is used to store a computer program; and the processor 61 is used to execute the method for generating an on-chip network test platform provided in the above embodiment when executing the computer program.

[0239] For the specific process of the method for generating the above-mentioned on-chip network test platform, reference may be made to the corresponding contents provided in the above-mentioned embodiments, which will not be described in detail here.

[0240] Furthermore, the memory 62 as a carrier for storing resources may be a read-only memory, a random access memory, a magnetic disk or an optical disk, etc., and the storage method may be temporary storage or permanent storage.

[0241] In addition, the electronic device 60 also includes a power supply 63, a communication interface 64, an input / output interface 65 and a communication bus 66; wherein the power supply 63 is used to provide working voltage for each hardware device on the electronic device 60; the communication interface 64 can create a data transmission channel between the electronic device 60 and external devices, and the communication protocol it follows is any communication protocol that can be applied to the technical solution of the present invention, and is not specifically limited here; the input / output interface 65 is used to obtain external input data or output data to the outside world, and its specific interface type can be selected according to specific application needs, and is not specifically limited here.

[0242] An embodiment of the present invention further provides a computer program product, including a computer program / instruction, which, when executed by a processor, implements the method for generating an on-chip network test platform as described in the above embodiment.

[0243] Since the embodiments of the computer program product part correspond to the embodiments of the method for generating a network on chip test platform part, please refer to the description of the above embodiments for the embodiments of the computer program product part, which will not be repeated here.

[0244] An embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the method for generating an on-chip network test platform as described in the above embodiment is implemented.

[0245] Since the embodiments of the computer-readable storage medium part correspond to the embodiments of the method for generating the on-chip network test platform part, please refer to the description of the above embodiments for the embodiments of the storage medium part, which will not be repeated here.

[0246] The various embodiments in the specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referred to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part.

[0247] Professionals may further appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.

[0248] The steps of the method or algorithm described in conjunction with the embodiments disclosed herein may be implemented directly using hardware, a software module executed by a processor, or a combination of the two. The software module may be placed in a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.

[0249] The above is a detailed introduction to the generation method, device, electronic device and medium of the on-chip network test platform provided by the present invention. Specific examples are used in this article to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea. It should be pointed out that for ordinary technicians in this technical field, without departing from the principles of the present invention, several improvements and modifications can be made to the present invention, and these improvements and modifications also fall within the scope of protection of the present invention.

Claims

1. A method for generating a network-on-chip test platform, It is characterized in that include: Acquire an architecture information file of the network on chip; wherein the architecture information file includes design file information to be tested, clock signal information, reset signal information of the network on chip, and network interface unit information corresponding to each network interface unit in the network on chip, wherein the network interface unit is used to connect to a host or a slave, and both the host and the slave belong to the verification intellectual property core; Acquire a test platform template file, and fill the test platform template file according to the network interface unit information to obtain a test platform configuration file; wherein the test platform configuration file includes an on-chip network definition file, an access constraint file and an intellectual property core configuration file, the on-chip network definition file contains the network interface unit information, the access constraint file contains the access constraint relationship between the host and the slave, and the intellectual property core configuration file records all the configuration information of the verification intellectual property core; Acquire the design file to be tested of the network on chip according to the design file to be tested information, connect the signals of each network interface unit in the design file to be tested with the verification intellectual property core, and set the clock signal and reset signal for the design file to be tested according to the clock signal information and the reset signal information to obtain an instantiation file; The test platform configuration file and the instantiation file form a test platform.

2. The generation method according to claim 1, It is characterized in that The network interface unit information includes input network interface unit information and output network interface unit information; The input network interface unit information includes the bus protocol, clock domain, reset domain, host serial number, input signal prefix, host communication information, stimulus generation information and host routing information of the input network interface unit; The output network interface unit information includes the bus protocol, clock domain, reset domain, slave serial number, output signal prefix, slave communication information, stimulus generation information and slave routing information of the output network interface unit.

3. The generation method according to claim 2, It is characterized in that The step of obtaining a test platform template file and filling the test platform template file according to the network interface unit information to obtain a test platform configuration file includes: Obtaining a network-on-chip definition template file, an access constraint template file, and an intellectual property core configuration template file; Filling the network interface unit information into the on-chip network definition template file, and compiling the filled on-chip network definition template file to obtain the on-chip network definition file; Determine the access constraint relationship between the host and the slave according to the stimulus generation information of the input network interface unit, the host routing information and the stimulus generation information of the output network interface unit, the slave routing information, and fill the access constraint relationship into the access constraint template file to obtain the access constraint file; The configuration information of the host and the slave is determined respectively according to the host communication information and the slave communication information, and the configuration information is filled into the intellectual property core configuration template file to obtain the intellectual property core configuration file.

4. The generation method according to claim 3, It is characterized in that Also includes: According to the preset hierarchical structure among the on-chip network definition file, the access constraint file, the intellectual property core configuration file and the instantiation file, create folders corresponding to each level; The on-chip network definition file, the access constraint file, the intellectual property core configuration file and the instantiation file are stored in folders of corresponding levels.

5. The generation method according to claim 2, It is characterized in that The signal connection of the signals of each network interface unit in the design file to be tested with the verification intellectual property core, and setting the clock signal and the reset signal for the design file to be tested according to the clock signal information and the reset signal information, comprises: Acquire a boundary signal to be matched from the design file to be tested, and determine whether the boundary signal belongs to a bus protocol signal; If the boundary signal belongs to the bus protocol signal, matching the signal prefix of the boundary signal with the input signal prefix in the input network interface unit information or the output signal prefix in the output network interface unit information; If the signal prefix matches the input signal prefix, determining the host corresponding to the boundary signal according to the host serial number in the input network interface unit information, and performing signal connection between the boundary signal and the corresponding host according to the host communication information in the input network interface unit information; If the signal prefix matches the output signal prefix, determining the slave corresponding to the boundary signal according to the slave serial number in the output network interface unit information, and performing signal connection between the boundary signal and the corresponding slave according to the slave communication information in the output network interface unit information; If the boundary signal does not belong to the bus protocol signal, determining whether the boundary signal belongs to an input signal; If the boundary signal belongs to the input signal, determining whether the boundary signal is a clock signal or a reset signal; If the boundary signal is a clock signal, determining a target clock signal corresponding to the boundary signal according to a signal prefix of the boundary signal and the clock signal information, creating the target clock signal according to the clock signal information of the target clock signal, and matching and connecting the boundary signal with the target clock signal; If the boundary signal is the reset signal, determining a target reset signal corresponding to the boundary signal according to a signal prefix of the boundary signal and the reset signal information, creating the target reset signal according to the reset signal information of the target reset signal, and matching and connecting the boundary signal with the target reset signal; If the boundary signal is not the clock signal and is not the reset signal, then it is not the boundary signal matching signal; If the boundary signal does not belong to the input signal, a corresponding intermediate variable is created for the boundary signal, and the boundary signal is matched with the intermediate variable.

6. The generation method according to claim 5, It is characterized in that The determining whether the boundary signal belongs to a bus protocol signal comprises: Determining whether the boundary signal belongs to a bus protocol signal according to the signal name of the boundary signal; The determining whether the boundary signal is a clock signal or a reset signal comprises: It is determined whether the boundary signal is a clock signal or a reset signal according to the signal name of the boundary signal.

7. The generation method according to claim 5, It is characterized in that The step of obtaining a boundary signal to be matched from the design file to be tested includes: Traversing the design file to be tested, obtaining signal prefixes and bit widths of all boundary signals in the design file to be tested, and saving the signal prefixes and bit widths to a boundary signal list; The boundary signal to be matched is obtained from the boundary signal list.

8. A device for generating a network-on-chip test platform, It is characterized in that include: An acquisition module is used to acquire an architecture information file of the on-chip network; wherein the architecture information file includes the design file information to be tested, clock signal information, reset signal information of the on-chip network, and network interface unit information corresponding to each network interface unit in the on-chip network, wherein the network interface unit is used to connect to a host or a slave, and both the host and the slave belong to the verification intellectual property core; A configuration file generation module, used to obtain a test platform template file, and fill the test platform template file according to the network interface unit information to obtain a test platform configuration file; wherein the test platform configuration file includes an on-chip network definition file, an access constraint file and an intellectual property core configuration file, the on-chip network definition file contains the network interface unit information, the access constraint file contains the access constraint relationship between the host and the slave, and the intellectual property core configuration file records all the configuration information of the verification intellectual property core; an instantiation file generation module, configured to obtain a design file to be tested of the network on chip according to the design file to be tested information, connect the signals of each network interface unit in the design file to be tested with the verification intellectual property core, and set a clock signal and a reset signal for the design file to be tested according to the clock signal information and the reset signal information, so as to obtain an instantiation file; A test platform generation module is used to combine the test platform configuration file and the instantiation file into a test platform.

9. An electronic device, It is characterized in that include: Memory for storing computer programs; A processor, configured to implement the method for generating an on-chip network test platform as claimed in any one of claims 1 to 7 when executing the computer program.

10. A computer-readable storage medium, It is characterized in that The computer-readable storage medium stores computer-executable instructions, and when the computer-executable instructions are loaded and executed by a processor, the method for generating an on-chip network test platform as described in any one of claims 1 to 7 is implemented.

Citation Information

Cited By

  • Chip verification method and device, equipment, storage medium and program product

    CN120951930A