Function safety test method, system and device of integrated circuit and storage medium
By determining the consistency test results of the unit under test and the copied logic unit in the integrated circuit, and adjusting the logic circuit to achieve the target test coverage, the problem of large circuit area overhead and high development cost under the Dual Core solution is solved, and efficient functions are achieved Security testing.
Patent Information
- Application Number
- CN202410707778.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-31
- Publication Date
- 2024-09-06
AI Technical Summary
In the functional safety test of automotive integrated circuits, the Dual Core solution needs to copy the entire logic circuit to be protected to achieve 100% test coverage, resulting in a large circuit area overhead, and when conducting functional safety testing of integrated circuits with low safety level requirements , the redesign process consumes huge manpower and high development costs.
By determining the consistency test results of the unit under test and the copied logic unit in the integrated circuit, the logic circuit is adjusted to achieve the target test coverage, avoiding the redesign of the integrated circuit, simplifying the adjustment process, and saving human development costs.
It achieves accurate adjustment of test coverage without increasing the circuit area, reduces the development cost of functional safety test, and improves test efficiency.
Smart Images

Figure CN118604574A
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of functional safety (FuSa) technology, and in particular to a functional safety testing method, system, device, and storage medium for integrated circuits. Background Art
[0002] Currently, in the FuSa security protection of automotive integrated circuits (such as automotive system on chip (SOC) or neural network processors), the dual core solution has become an essential protection solution for FuSa security protection because it is applicable to all logic circuits in the integrated circuit.
[0003] However, the Dual Core solution requires duplicating the entire logic circuit to be protected in order to implement testing of the entire logic circuit to be protected (the test coverage of the functional safety test reaches 100%), that is, the Dual Core solution needs to pay twice the circuit area cost to implement functional safety testing of a single circuit, and the area overhead is relatively large. In order to reduce the area overhead, when the Dual Core solution is used for functional safety testing of integrated circuits that do not have high requirements for the safety level (for example, the target test coverage of the functional safety test is less than 100%), the integrated circuit can be redesigned to add multiple duplicate logic units corresponding to the target test coverage in each original logic circuit to be protected (in some examples, this can be obtained by duplicating the units to be tested in the original logic circuit) to obtain a target integrated circuit with the target test coverage. However, the process of redesigning the integrated circuit requires repeated design iterations and trade-offs to determine the multiple duplicate logic units corresponding to the target test coverage, which consumes a huge amount of human resources and has high development costs. Summary of the Invention
[0004] Typically, when using a dual-core solution to perform functional safety testing on integrated circuits with lower level requirements, it is necessary to repeatedly redesign each logic circuit to be protected in the integrated circuit, resulting in high manpower development costs.
[0005] To solve the above technical problems, the present disclosure provides a testing method for an integrated circuit, wherein the integrated circuit includes a first logic circuit and a second logic circuit for performing a functional safety test on the first logic circuit. The testing method includes:
[0006] Determine at least one first unit under test in the first logic circuit and second units under test corresponding to each first unit under test in the second logic circuit;
[0007] Performing a functional safety test on the first logic circuit and the second logic circuit to obtain a consistency test result of first test data output by each first unit under test and second test data output by each corresponding second unit under test;
[0008] Determine the current test coverage of the integrated circuit based on the consistency test results;
[0009] In response to the current test coverage not satisfying a preset numerical relationship with the target test coverage, adjusting a first unit under test in the first logic circuit and a second unit under test in the second logic circuit to obtain a first target logic circuit and a second target logic circuit;
[0010] A target integrated circuit corresponding to a target test coverage is determined based on the first target logic circuit and the second target logic circuit.
[0011] A second aspect of the present disclosure provides a functional safety test system for an integrated circuit, comprising an integrated circuit and a test device for performing a functional safety test on the integrated circuit; the integrated circuit comprises a first logic circuit, a second logic circuit, and a comparator;
[0012] a test device for determining at least one first unit under test in the first logic circuit and second units under test corresponding to each first unit under test in the second logic circuit;
[0013] a first logic circuit coupled to the comparator, and configured to output first test data to the comparator based on at least one first unit under test in the first logic circuit;
[0014] a second logic circuit coupled to the comparator, and configured to output second test data to the comparator based on at least one second unit under test in the second logic circuit;
[0015] a comparator coupled to the test device, and configured to output a consistency test result to the test device based on the first test data and the second test data;
[0016] A test device is used to determine the current test coverage of an integrated circuit based on consistency test results; in response to the current test coverage and the target test coverage not satisfying a preset numerical relationship, adjust the first unit to be tested in the first logic circuit and the second unit to be tested in the second logic circuit to obtain a first target logic circuit and a second target logic circuit; based on the first target logic circuit and the second target logic circuit, determine a target integrated circuit corresponding to the target test coverage.
[0017] A third aspect of the present disclosure provides a functional safety testing device for an integrated circuit, the integrated circuit comprising a first logic circuit and a second logic circuit for performing a functional safety test on the first logic circuit, the functional safety testing device comprising:
[0018] A first determining module is configured to determine at least one first unit under test in the first logic circuit and second units under test corresponding to each first unit under test in the second logic circuit;
[0019] a functional safety testing module, configured to perform a functional safety test on the first logic circuit and the second logic circuit, and obtain a consistency test result of first test data output by each first unit under test and second test data output by each corresponding second unit under test;
[0020] A second determination module is configured to determine a current test coverage of the integrated circuit based on the consistency test result;
[0021] an adjustment module, configured to adjust a first unit under test in the first logic circuit and a second unit under test in the second logic circuit in response to the current test coverage not satisfying a preset numerical relationship with the target test coverage, to obtain a first target logic circuit and a second target logic circuit;
[0022] The third determining module is configured to determine a target integrated circuit corresponding to a target test coverage based on the first target logic circuit and the second target logic circuit.
[0023] A fourth aspect of the present disclosure provides a computer-readable storage medium storing a computer program for executing the integrated circuit testing method of the first aspect.
[0024] In the disclosed embodiment, functional safety testing is performed on a first logic circuit and a second logic circuit to obtain consistency test results for first test data output by each first unit under test in the first logic circuit and second test data output by each second unit under test in the second logic circuit. Therefore, the consistency test results are related to each first unit under test in the first logic circuit and each second unit under test in the second logic circuit. The current test coverage of the integrated circuit, determined based on the consistency test results, is also related to each first unit under test in the first logic circuit and each second unit under test in the second logic circuit. Furthermore, when the current test coverage does not satisfy a preset numerical relationship with a target test coverage, the current test coverage can be accurately adjusted to the target test coverage by adjusting the first test units in the first logic circuit and the second test units in the second logic circuit, thereby obtaining a target integrated circuit corresponding to the target test coverage. Furthermore, because adjusting the first test units in the first logic circuit and the second test units in the second logic circuit is relatively simple to implement, it does not require redesign of the integrated circuit, effectively saving manpower development costs. BRIEF DESCRIPTION OF THE DRAWINGS
[0025] Figure 1This is a schematic diagram of the composition structure of an integrated circuit applicable to a dual core solution with high security level requirements provided by an exemplary embodiment of the present disclosure.
[0026] Figure 2 This is a schematic diagram of the composition structure of an integrated circuit applicable to a dual core solution with low security level requirements provided by an exemplary embodiment of the present disclosure.
[0027] Figure 3 The figure is a schematic diagram of the structure of a functional safety test system for integrated circuits provided by an exemplary embodiment of the present disclosure.
[0028] Figure 4 It is a schematic diagram of the composition structure of another integrated circuit functional safety testing system provided by an exemplary embodiment of the present disclosure.
[0029] Figure 5 The figure is a flow chart of a functional safety testing method for an integrated circuit provided by an exemplary embodiment of the present disclosure.
[0030] Figure 6 It is a flowchart of another integrated circuit functional safety testing method provided by an exemplary embodiment of the present disclosure.
[0031] Figure 7 This is a flowchart of another integrated circuit functional safety testing method provided by an exemplary embodiment of the present disclosure.
[0032] Figure 8 This is a flowchart of another integrated circuit functional safety testing method provided by an exemplary embodiment of the present disclosure.
[0033] Figure 9 This is a flowchart of another integrated circuit functional safety testing method provided by an exemplary embodiment of the present disclosure.
[0034] Figure 10 This is a flowchart of another integrated circuit functional safety testing method provided by an exemplary embodiment of the present disclosure.
[0035] Figure 11 It is a schematic diagram of the composition structure of another integrated circuit functional safety testing system provided by an exemplary embodiment of the present disclosure.
[0036] Figure 12 It is a schematic diagram of the composition structure of another integrated circuit functional safety testing system provided by an exemplary embodiment of the present disclosure.
[0037] Figure 13 It is a schematic diagram of the composition structure of another integrated circuit functional safety testing system provided by an exemplary embodiment of the present disclosure.
[0038] Figure 14 The figure is a schematic diagram of the structure of a functional safety testing device for integrated circuits provided by an exemplary embodiment of the present disclosure.
[0039] Figure 15 The figure is a schematic diagram of the composition structure of another integrated circuit functional safety testing device provided by an exemplary embodiment of the present disclosure.
[0040] Figure 16 It is a schematic diagram of the composition structure of another integrated circuit functional safety testing device provided by an exemplary embodiment of the present disclosure.
[0041] Figure 17 It is a schematic diagram of the composition structure of another integrated circuit functional safety testing device provided by an exemplary embodiment of the present disclosure.
[0042] Figure 18 It is a schematic diagram of the composition structure of another integrated circuit functional safety testing device provided by an exemplary embodiment of the present disclosure.
[0043] Figure 19 It is a schematic diagram of the composition structure of another integrated circuit functional safety testing device provided by an exemplary embodiment of the present disclosure.
[0044] Figure 20 It is a schematic diagram of the composition structure of another integrated circuit functional safety testing device provided by an exemplary embodiment of the present disclosure.
[0045] Figure 21 It is a schematic diagram of the composition structure of an electronic device provided by an exemplary embodiment of the present disclosure. DETAILED DESCRIPTION
[0046] To explain the present disclosure, example embodiments of the present disclosure will be described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present disclosure, rather than all the embodiments. It should be understood that the present disclosure is not limited to the example embodiments.
[0047] It should be noted that the relative arrangement of components and steps, the numerical expressions and numerical values set forth in these embodiments do not limit the scope of the present disclosure unless specifically stated otherwise.
[0048] Application Overview
[0049] Currently, the FuSa mechanism is a key capability in the automotive field and has been widely used in automotive integrated circuits. Typically, FuSa protection solutions for automotive integrated circuits include a dual-core solution that applies to all logic circuits in the IC. This dual-core solution requires duplicating the entire logic circuit to be protected in order to test it, achieving 100% functional safety coverage.
[0050] Since when the dual core solution is used to perform functional safety testing on an integrated circuit, all logic circuits to be protected in the integrated circuit are in normal working condition, therefore, the coupling relationship of each original logic circuit (logic circuit to be protected) in the integrated circuit of the dual core solution is fixed (for example, the output of each original logic circuit is coupled to the corresponding other logic circuits, that is, each original logic circuit can drive the load circuit of the next level). In order to perform functional safety testing on an integrated circuit, it is only necessary to add a test circuit for functional safety testing according to the safety level requirements and perform corresponding coupling. In the embodiment of the present disclosure, the test circuit may include a copied original logic circuit (copied logic circuit), a copied logic unit (copied logic unit) and a comparator.
[0051] Because the coupling relationships of the original logic circuits in an integrated circuit do not change with changes in the functional safety test safety level, the coupling relationships of the original logic circuits are neither illustrated nor described in the following figures. The disclosed embodiments do not limit the coupling relationships of the original logic circuits in an integrated circuit; the coupling relationships of the original logic circuits in an integrated circuit can be determined based on the actual functions of the integrated circuit.
[0052] Figure 1 This is a schematic diagram of the structure of an integrated circuit applicable to a dual core solution with high security requirements provided by an exemplary embodiment of the present disclosure. Figure 1 As shown, the integrated circuit 10 may include a logic circuit 11 (a logic circuit to be protected), a replica logic circuit 12 obtained by replicating the logic circuit 11 , and a comparator 13 coupled to both the logic circuit 11 and the replica logic circuit 12 .
[0053] The logic circuit 11 may include first to fourth logic units 111 to 114 ; the replication logic circuit 12 may include first to fourth replication logic units 121 to 124 corresponding to the first to fourth logic units 111 to 114 , respectively.
[0054] A first input terminal of comparator 13 is coupled to the output terminals of first to fourth logic units 111 to 114, and a second input terminal of comparator 13 is coupled to the output terminals of first to fourth replication logic units 121 to 124. Comparator 13 is configured to receive the first to fourth logic data outputted by first to fourth logic units 111 to 114, respectively, and the first to fourth replication logic data outputted by first to fourth replication logic units 121 to 124, respectively, compare each logical data in the first to fourth logic data with the corresponding replication logic data in the first to fourth replication logic data, obtain a comparison result, and transmit the comparison result to the operating system via an output terminal.
[0055] In the embodiment of the present disclosure, the coupling relationship between the logic units (in some examples, this may include the coupling relationship between the logic units and between the logic units and other logic units outside the logic circuit 11) and the coupling relationship between the replicated logic units in the replicated logic circuit 12 are exactly the same.
[0056] In the technical solution of the embodiment of the present disclosure, when performing functional safety testing on the integrated circuit 10 with high safety level requirements through the dual core solution, the entire logic circuit 11 is copied. Therefore, the area is doubled compared to the original area, and the area overhead is large.
[0057] In order to reduce area overhead, when using the Dual Core solution to perform functional safety testing on integrated circuits with low security level requirements (security level lower than the 100% test coverage requirement), multiple replicated logic units corresponding to the target test coverage can be added to each original logic circuit to be protected, that is, the target integrated circuit with the target test coverage can be obtained by redesigning the integrated circuit.
[0058] Figure 2 This is a schematic diagram of the structure of an integrated circuit applicable to a dual core solution with low security level requirements provided by an exemplary embodiment of the present disclosure. Figure 2 As shown, the integrated circuit 20 may include a new logic circuit 21 and a comparator 22 coupled to the new logic circuit 21. The new logic circuit 21 may include Figure 1 The logic circuit 11 and at least one replicated logic unit 23 (replicated unit under test) are shown. This embodiment of the disclosure is exemplified by taking as an example that at least one replicated logic unit 23 includes a first replicated logic unit 121 corresponding to the first logic unit 111 and a second replicated logic unit 122 corresponding to the second logic unit 112.
[0059] Among them, the output ends of the first logic unit 111 and the second logic unit 112 are both coupled to the first input end of the comparator 22; the output ends of the first copy logic unit 121 and the second copy logic unit 122 are both coupled to the second input end of the comparator 22; the output end of the comparator 22 is used to send the comparison result to the operating system.
[0060] In the disclosed embodiment, the input coupling relationship between each replicated logic unit and the corresponding logic unit in at least one replicated logic unit 23 is the same, that is, the input data of each replicated logic unit is the same as that of the corresponding logic unit in the original logic circuit, but the output of each replicated logic unit is not coupled to other logic units, that is, the output of each replicated logic unit does not drive a load circuit.
[0061] Reference below Figure 2 This section describes the implementation process of the Dual Core solution with low security level requirements.
[0062] First, the first logic unit 111 and the second logic unit 112 output the first logic test data and the second logic test data to the comparator 22 respectively; the first copy logic unit 121 and the second copy logic unit 122 output the first copy logic test data and the second copy logic test data to the comparator 22 respectively.
[0063] Next, the comparator 22 compares the first logic test data with the first duplicate logic test data and the second logic test data with the second duplicate logic test data to obtain a comparison result, and sends the comparison result to the operating system.
[0064] Next, the operating system calculates the current test coverage of the integrated circuit 20 according to the comparison result.
[0065] Finally, when the designer determines that the current test coverage is not equal to the target test coverage corresponding to the target security level, the designer redesigns the integrated circuit 20 based on the coverage difference between the current test coverage and the target test coverage, that is, repeatedly redesigns and iterates and discards the replicated logic units in at least one replicated logic unit 23 based on the logic circuit 11 to obtain multiple replicated logic units corresponding to the target coverage, that is, to obtain the target integrated circuit corresponding to the target test coverage.
[0066] In the technical solution of the disclosed embodiments, when using the DualCore solution to perform functional safety testing on a protected logic circuit with a low safety level requirement, only some logic units (units under test) in the original logic circuit to be protected are replicated, thereby reducing area overhead. However, the process of redesigning the integrated circuit requires repeated design iterations and trade-offs to determine the number of replicated logic units corresponding to the target test coverage, which consumes a huge amount of human resources.
[0067] Based on the above technical problems, an embodiment of the present disclosure provides a functional safety testing method for an integrated circuit, the method including: determining the current test coverage of the integrated circuit based on the consistency test results of the first test data output by each first test unit in the first logic circuit and the second test data output by each corresponding second test unit in the second logic circuit; and adjusting the first test unit in the first logic circuit and the second test unit in the second logic circuit based on the difference between the current test coverage and the target test coverage; and finally determining the target integrated circuit corresponding to the target test coverage based on the obtained first target logic circuit and the second target logic circuit.
[0068] Because the current test coverage of the integrated circuit is related to each first unit under test in the first logic circuit and each second unit under test in the second logic circuit, when the current test coverage and the target test coverage do not satisfy a preset numerical relationship, the current test coverage can be accurately adjusted to the target test coverage by adjusting the first test unit in the first logic circuit and the second test unit in the second logic circuit, thereby obtaining the target integrated circuit. At the same time, because the adjustment of the first test unit in the first logic circuit and the second test unit in the second logic circuit is relatively simple to implement, it does not require redesign of the integrated circuit, thus effectively saving manpower development costs.
[0069] Exemplary Systems
[0070] Figure 3 FIG. 1 is a schematic diagram showing the structure of a functional safety test system for an integrated circuit provided by an exemplary embodiment of the present disclosure. Figure 3 As shown, the functional safety test system 30 includes an integrated circuit 31 and a test device 32 for performing functional safety testing. The integrated circuit 31 may include Figure 1 The logic circuit 11, the adjustable ratio logic circuit 31 and the comparator 33 are shown. The adjustable ratio logic circuit 31 may include Figure 1 The first to fourth replication logic units 121 to 124 are shown.
[0071] The output of at least one logic unit in the logic circuit 11 is coupled to the first input of the comparator 33, and the output of at least one corresponding replica logic unit in the adjustable ratio logic circuit 31 is coupled to the second input of the comparator 33. The output of the comparator 33 is used to output a comparison result. The disclosed embodiment uses an example in which the outputs of the first logic unit 111 and the second logic unit 112 in the logic circuit 11 are both coupled to the first input of the comparator 33, and the outputs of the first replica logic unit 121 and the second replica logic unit 122 are both coupled to the second input of the comparator 33.
[0072] In the disclosed embodiment, the input coupling relationship between each replica logic unit and the corresponding logic unit in the adjustable ratio logic circuit 31 is the same, that is, the input data of each replica logic unit is the same as that of the corresponding logic unit in the original logic circuit, but the output of each replica logic unit is not coupled to other logic units, that is, the output of each replica logic unit does not drive the load circuit.
[0073] In the embodiment of the present disclosure, the testing device 32 may be a personal computer or an industrial computer installed with an electronic design automation (EDA) software testing tool.
[0074] In the above Figure 4 Based on the embodiment shown, the present disclosure provides another functional safety test system for integrated circuits. Figure 4 As shown, the integrated circuit 31 in the functional safety test system 30 further includes a hash generator 34 . The hash generator 34 may include a first hash generator 341 and a second hash generator 342 .
[0075] The outputs of the first logic unit 111 and the second logic unit 112 are coupled to the input of the first hash generator 341; the output of the first hash generator 341 is coupled to the first input of the comparator 33. The outputs of the first replication logic unit 121 and the second replication logic unit 122 are coupled to the input of the second hash generator 342; the output of the second hash generator 342 is coupled to the second input of the comparator 33.
[0076] In some embodiments of the present disclosure, the first hash generator 341 and the second hash generator 342 may each include at least one hash generation module, and the number of hash generation modules in the first hash generator 341 and / or the second hash generator 342 may be determined based on the bit width of the hash generation module, the number and bit width of the first unit under test and the second unit under test included in the logic circuit 11 and / or the adjustable ratio logic circuit 31. The embodiments of the present disclosure do not limit the number of hash generation modules included in the first hash generator 341 and the second hash generator 342. The embodiments of the present disclosure are illustrative in the example where the first hash generator 341 and the second hash generator 342 each include one hash generation module.
[0077] Exemplary Methods
[0078] Figure 5 This is a flow chart of a functional safety test method for an integrated circuit provided by an exemplary embodiment of the present disclosure. The functional safety test method for an integrated circuit can be applied to Figure 3 and / or Figure 4 In the functional safety test system 30 shown, Figure 5As shown, the functional safety testing method for an integrated circuit may include the following steps 501 to 505 .
[0079] Step 501 : Determine at least one first unit under test in a first logic circuit and second units under test corresponding to each first unit under test in a second logic circuit.
[0080] For example, the first logic circuit may be an original logic circuit in an integrated circuit, and the output end of each logic unit included in the first logic circuit is coupled to a corresponding logic unit. The first unit to be tested may be an original logic unit in the original logic circuit that needs to undergo functional safety testing. In some examples, reference Figure 3 or Figure 4 As shown, the first logic circuit may be a logic circuit 11, and the first logic unit 111 to the second logic unit 114 in the logic circuit 11 are all coupled to corresponding logic units ( Figure 3 or Figure 4 (not shown), the at least one unit under test may include a first logic unit 111 and a second logic unit 112 coupled to the comparator 33.
[0081] For example, the second logic circuit can be obtained by duplicating each logic unit in the first logic circuit, and the output end of each logic unit included in the second logic circuit is not coupled to the logic unit. Figure 3 or Figure 4 As shown, the second logic circuit may be an adjustable scale logic circuit 31 obtained by replicating the first logic unit 111 to the second logic unit 114 , and the outputs of the first to fourth replica logic units 121 to 124 in the adjustable scale logic circuit 31 are not coupled to any logic unit.
[0082] For example, the second unit to be tested may be a logic unit that needs to be tested for functional safety among the multiple replicated logic units. Figure 3 or Figure 4 As shown, the at least one second UUT may include a first copy logic unit 121 and a second copy logic unit 122 .
[0083] Exemplarily, determining at least one first unit to be tested in the first logic circuit may include, without any basis, arbitrarily determining at least one logic unit that needs to be subjected to a functional safety test from a plurality of logic units in the first logic circuit, and determining the logic unit that needs to be subjected to a functional safety test as the first unit to be tested; it may also include determining at least one logic unit that needs to be subjected to a functional safety test from a plurality of logic units in the first logic circuit based on a target test coverage rate for performing functional safety testing, and determining the logic unit that needs to be subjected to a functional safety test as the first unit to be tested. The embodiments of the present disclosure do not limit the specific implementation method of determining at least one first unit to be tested from the first logic circuit. The embodiments of the present disclosure are illustratively described by taking the example of determining at least one unit to be tested from a plurality of logic units in the first logic circuit based on a target test coverage rate.
[0084] For example, refer to Figure 3 As shown, step 501 may include: the test device 32 determines the target test coverage of the functional safety test for the integrated circuit according to the safety level of the integrated circuit, and then determines that the first logic unit 111 and the second logic unit 112 need to be subjected to the functional safety test from the first logic unit 111 to the fourth logic unit 114 of the logic circuit 11 according to the target test coverage, and determines the first logic unit 111 and the second logic unit 112 as at least one first unit to be tested; determines the first replicated logic unit 121 corresponding to the first logic unit 111 and the second replicated logic unit 122 corresponding to the second logic unit 112 from the first replicated logic unit 121 to the fourth replicated logic unit 124 of the adjustable scale logic circuit 31, and determines the first replicated logic unit 121 and the second replicated logic unit 122 as at least one second unit to be tested.
[0085] In some examples, the test device 32 may determine at least one first unit under test and at least one second unit under test through a script program and the above method.
[0086] For example, refer to Figure 3As shown, taking the example of at least one first unit under test including a first logic unit 111 and a second logic unit 112, and at least one second unit under test including a first duplicate logic unit 121 and a second duplicate logic unit 122, the test device 32, after determining the at least one first unit under test and the at least one second unit under test through a script program, further includes: coupling the output of the first logic unit 111 and the output of the second logic unit 112 to the first input of the comparator 33 through an EDA software test operation to perform a functional safety test on the first logic unit 111 and the second logic unit 112; and coupling the output of the first duplicate logic unit 121 and the output of the second duplicate logic unit 122 to the second input of the comparator 33 to perform a functional safety test on the first duplicate logic unit 121 and the second duplicate logic unit 122.
[0087] Step 502 : Perform functional safety testing on the first logic circuit and the second logic circuit to obtain consistency test results of first test data output by each first unit under test and second test data output by each corresponding second unit under test.
[0088] For example, the first test data may be first processed data obtained after each first unit under test in the first logic circuit performs data processing on the input first data to be processed. The second test data may be second processed data obtained after each second unit under test in the second logic circuit performs data processing on the input second data to be processed. In some examples, the first data to be processed and the second data to be processed may be the same data, and when the first test unit and the second test unit are normal, the first processed data and the second processed data are also the same data, that is, the first test data and the second test data are consistent.
[0089] Exemplarily, the consistency test result may be a comparison result of the first test data and the second test data, and may include the consistency of the first test data and the second test data, and the inconsistency of the first test data and the second test data. In some examples, the consistency of the first test data and the second test data may be indicated by a logic high level "1", and the inconsistency of the first test data and the second test data may be indicated by a logic low level "0". In other examples, the consistency of the first test data and the second test data may be indicated by a logic low level "0", and the inconsistency of the first test data and the second test data may be indicated by a logic high level "1". The specific implementation form of the consistency test result is not limited in the embodiment of the present disclosure. The embodiment of the present disclosure is exemplified by the example of indicating that the first test data and the second test data are consistent by a logic high level "1" and indicating that the first test data and the second test data are inconsistent by a logic low level "0".
[0090] Illustratively, performing functional safety testing on the first logic circuit and the second logic circuit may include: inputting corresponding first data to be processed into each logic unit in the first logic circuit, and inputting corresponding second data to be processed into each replicated logic unit in the second logic circuit, so as to implement functional safety testing on the first logic circuit and the second logic circuit.
[0091] In some examples, reference Figure 3 As shown, taking the first logic circuit as logic circuit 11 and the second logic circuit as adjustable ratio logic circuit 31 as an example, performing functional safety testing on the first logic circuit and the second logic circuit may include: using an EDA software testing tool in a testing device 32 to simulate, in a manner, inputting corresponding first to-be-processed data into the first to-fourth logic units 111 to 114 in the logic circuit 11, and inputting corresponding second to-be-processed data into the first to-fourth replicated logic units 121 to 124 in the adjustable ratio logic circuit 31, to perform functional safety testing on the logic circuit 11 and the adjustable ratio logic circuit 31.
[0092] For example, when performing functional safety testing on the first logic circuit and the second logic circuit, first test data and second test data may be obtained first, and then the first test data and the second test data are compared to obtain consistency test results of the first test data and the second test data.
[0093] In some examples, for example, at least one first unit under test includes a first logic unit 111 and a second logic unit 112, and at least one second unit under test includes a first replica logic unit 121 and a second replica logic unit 122. After the corresponding first data to be processed is input to the first logic unit 111 to the fourth logic unit 114 in the logic circuit 11, and the corresponding second data to be processed is input to the first replica logic unit 121 to the fourth replica logic unit 124 in the adjustable ratio logic circuit 31, the first logic unit 111 and the second logic unit 112 will output first test data to the comparator 33; and the first replica logic unit 121 and the second replica logic unit 122 will output second test data to the comparator 33. Furthermore, the comparator 33 can compare the first test data with the second test data to obtain a consistency test result of the first test data and the second test data.
[0094] Step 503: Determine the current test coverage of the integrated circuit based on the consistency test result.
[0095] Exemplarily, step 503 may include: determining the composition structure and coupling relationship of each original logic circuit in the integrated circuit, and determining the current test coverage of the integrated circuit based on the composition structure and coupling relationship and the consistency test result.
[0096] In some examples, reference Figure 3 As shown, the EDA software testing tool in the test device 32 can obtain the consistency test results of the first test data and the second test data in real time, and calculate the current test coverage corresponding to the consistency test results based on the composition structure and coupling relationship of each original logic circuit in the pre-stored integrated circuit.
[0097] Step 504 : In response to the current test coverage and the target test coverage not satisfying a preset numerical relationship, adjusting the first unit under test in the first logic circuit and the second unit under test in the second logic circuit to obtain a first target logic circuit and a second target logic circuit.
[0098] Exemplarily, the preset numerical relationship may be equal or close in magnitude. In some examples, if the coverage difference between the current test coverage and the target test coverage is less than a difference threshold, the current test coverage is determined to be equal to or close to the target test coverage.
[0099] For example, refer to Figure 3 As shown, the test device 32 can determine the coverage difference between the current test coverage and the target test coverage through a script program. When the coverage difference is greater than or equal to the difference threshold, it is determined that the current test coverage and the target test coverage do not satisfy the preset numerical relationship. When the coverage difference is less than the difference threshold, it is determined that the current test coverage and the target test coverage satisfy the preset numerical relationship.
[0100] For example, the first target logic circuit may be the first logic circuit after adjusting the first test unit, and the second target logic circuit may be the second logic circuit after adjusting the second test unit.
[0101] Exemplarily, adjusting the first unit to be tested in the first logic circuit and the second unit to be tested in the second logic circuit to obtain the first target logic circuit and the second target logic circuit may include: adding, reducing or replacing the first unit to be tested in the first logic circuit and the second unit to be tested in the second logic circuit, and determining the first target logic circuit based on the added, reduced or replaced first unit to be tested, and determining the second target logic circuit based on the added, reduced or replaced second unit to be tested.
[0102] In some examples, reference Figure 3As shown, taking the example that the first unit under test includes the first logic unit 111 and the second logic unit 112, and the second unit under test includes the first duplicate logic unit 121 and the second duplicate logic unit 122, adding, reducing, or replacing the first unit under test in the first logic circuit and the second unit under test in the second logic circuit may include: the test device 32 using a script program adding the third logic unit 113 or the fourth logic unit 114 as the first unit under test, and correspondingly adding the third duplicate logic unit 123 or the fourth duplicate logic unit 124 as the second unit under test; or removing the test on the first logic unit 111 or the second logic unit 112, and correspondingly removing the test on the first duplicate logic unit 121 or the second duplicate logic unit 122; or replacing the test on the first logic unit 111 or the second logic unit 112 with a test on the third logic unit 113 or the fourth logic unit 114, and correspondingly replacing the test on the first duplicate logic unit 121 or the second duplicate logic unit 122 with a test on the third duplicate logic unit 123 or the fourth duplicate logic unit 124.
[0103] Step 505 : Determine a target integrated circuit corresponding to a target test coverage based on the first target logic circuit and the second target logic circuit.
[0104] For example, the target test coverage can be the test coverage required to be achieved when performing functional safety testing on an integrated circuit, determined based on the safety level of the integrated circuit. In some examples, the target test coverage can be any value less than 100%, for example, the target test coverage can be 80% or 90%. The present disclosure does not limit the specific value of the target test coverage. The present disclosure uses a target test coverage of 90% for illustrative purposes.
[0105] For example, reference 3 or Figure 4As shown, step 505 may include: the test device 32 determines the latest test coverage of the integrated circuit based on the first target logic circuit and the second target logic circuit. Then, it is determined whether the latest test coverage and the target test coverage meet a preset numerical relationship. When it is determined that the latest test coverage meets the preset numerical relationship, the integrated circuit corresponding to the first target logic circuit and the second target logic circuit is determined as the target integrated circuit corresponding to the target test coverage. When it is determined that the latest test coverage and the target test coverage do not meet the preset numerical relationship, the logic unit (first unit to be tested) coupled to the comparator 33 or the first hash generator 341 in the logic circuit 11 and the replica logic unit (second unit to be tested) coupled to the comparator 33 or the second hash generator 342 in the adjustable ratio logic circuit 31 are further adjusted, and then the first target logic circuit and the second target logic circuit are updated until the latest test coverage determined based on the updated first target logic circuit and the updated second target logic circuit meet the preset numerical relationship. The integrated circuit corresponding to the latest first target logic circuit and the latest second target logic circuit is determined as the target integrated circuit corresponding to the target test coverage.
[0106] In the disclosed embodiment, functional safety testing is performed on a first logic circuit and a second logic circuit to obtain consistency test results for first test data output by each first unit under test in the first logic circuit and second test data output by each second unit under test in the second logic circuit. Therefore, the consistency test results are related to each first unit under test in the first logic circuit and each second unit under test in the second logic circuit. The current test coverage of the integrated circuit, determined based on the consistency test results, is also related to each first unit under test in the first logic circuit and each second unit under test in the second logic circuit. Furthermore, when the current test coverage does not satisfy a preset numerical relationship with a target test coverage, the current test coverage can be accurately adjusted to the target test coverage by adjusting the first test units in the first logic circuit and the second test units in the second logic circuit, thereby obtaining a target integrated circuit corresponding to the target test coverage. Furthermore, because adjusting the first test units in the first logic circuit and the second test units in the second logic circuit is relatively simple to implement, it does not require redesign of the integrated circuit, effectively saving manpower development costs.
[0107] like Figure 6 As shown in the above Figure 5 Based on the illustrated embodiment, step 502 may include the following steps 5021 to 5023 .
[0108] Step 5021: Perform functional safety testing on the first logic circuit and the second logic circuit to obtain first test data and second test data.
[0109] Illustratively, step 5021 may include: inputting corresponding first data to be processed into each logic unit in the first logic circuit, and inputting corresponding second data to be processed into each replicated logic unit in the second logic circuit; each first unit to be tested in the first logic circuit will perform data processing on the first data to be processed to obtain first test data; and each second unit to be tested in the second logic circuit will perform data processing on the second data to be processed to obtain second test data.
[0110] In some examples, it is taken as an example that at least one first unit under test includes a first logic unit 111 and a second logic unit 112, and at least one second unit under test includes a first copy logic unit 121 and a second copy logic unit 122. Figure 4 As shown, step 5021 may specifically include: inputting corresponding first data to be processed into the first logic unit 111 to the fourth logic unit 114 in the logic circuit 11, and inputting corresponding second data to be processed into the first replication logic unit 121 to the fourth replication logic unit 124 in the adjustable ratio logic circuit 31. In response to the received first data to be processed, the first logic unit 111 and the second logic unit 112 respectively perform data processing on the first data to be processed to obtain first test data (first processed data), and output the first test data to the hash generator 34; in response to the received second data to be processed, the first replication logic unit 121 and the second replication logic unit 122 respectively perform data processing on the second data to be processed to obtain second test data (second processed data), and output the second test data to the hash generator 34.
[0111] Step 5022: Perform hash calculations on the first test data and the second test data respectively using a hash generator in the integrated circuit to obtain a first hash value corresponding to the first test data and a second hash value corresponding to the second test data.
[0112] For example, refer to Figure 4 As shown, step 5022 may include: the hash generator 34 performs hash calculations on the first test data and the second test data respectively, and outputs the first hash value corresponding to the first test data to the first input end of the comparator 33, and outputs the second hash value corresponding to the second test data to the second input end of the comparator 33.
[0113] In some embodiments of the present disclosure, the hash generator may include a first hash generator and a second hash generator. Step 5022 may include: performing a hash calculation on the first test data using the first hash generator to obtain a first hash value; and performing a hash calculation on the second test data using the second hash generator to obtain a second hash value.
[0114] For example, refer to Figure 4As shown, the first logic unit 111 and the second logic unit 112 can output the first test data to the first hash generator 341 in the hash generator 34, and the first copy logic unit 121 and the second copy logic unit 122 can output the second test data to the second hash generator 342 in the hash generator 34. Correspondingly, step 5022 may include: the first hash generator 341 processes the first test data using a corresponding first hash algorithm to obtain a first hash value of a first fixed length, and outputs the first hash value to the first input terminal of the comparator 33; the second hash generator 342 processes the second test data using a corresponding second hash algorithm to obtain a second hash value of a second fixed length, and outputs the second hash value to the second input terminal of the comparator 33.
[0115] In some examples, the first hash algorithm and the second hash algorithm can be the same algorithm. The first fixed length and the second fixed length can be the same length, and the first fixed length and / or the second fixed length can be smaller than the bit width of the first test data and the bit width of the second test data. In this way, the first hash value and the second hash value with the same bit width and smaller bit width can be obtained by the first hash generator and the second hash generator.
[0116] Step 5023: Determine a consistency test result based on the first Hash value and the second Hash value.
[0117] For example, refer to Figure 4 As shown, the comparator 33 can compare the first hash value and the second hash value to obtain a consistency test result, and output the consistency test result to the test device 32.
[0118] The disclosed embodiment performs a hash calculation on first test data using a first hash generator to obtain a first hash value representing the first test data; and performs a hash calculation on second test data using a second hash generator to obtain a second hash value representing the second test data. Thus, when the lengths of the first hash value and the second hash value are the same and both are smaller than the lengths of the first test data and the second test data, comparing the first hash value and the second hash value can not only accurately determine the consistency test result of the first test data and the second test data, but also reduce the computational complexity and amount of the comparison.
[0119] like Figure 7 As shown in the above Figure 5 Based on the illustrated embodiment, the functional safety testing method for an integrated circuit may further include the following step 506 .
[0120] Step 506 : In response to the current test coverage and the target test coverage satisfying a preset numerical relationship, determine a target integrated circuit based on the first logic circuit and the second logic circuit.
[0121] Exemplarily, step 506 may include: when the current test coverage and the target test coverage satisfy a preset numerical relationship, determining the first logic circuit as the first target logic circuit, removing logic units other than the second unit under test in the second logic circuit (retaining at least one second unit under test in the second logic circuit), and determining the remaining at least one second unit under test as the second target logic circuit. Finally, determining the integrated circuits corresponding to the first target logic circuit and the second target logic circuit as the target integrated circuit.
[0122] In some examples, it is taken as an example that at least one first unit under test includes a first logic unit 111 and a second logic unit 112, and at least one second unit under test includes a first copy logic unit 121 and a second copy logic unit 122. Figure 3 or Figure 4 As shown, step 506 may specifically include: when the current test coverage rate and the target test coverage rate satisfy a preset numerical relationship, using the integrated circuit 11 as the first target logic circuit, and automatically removing the third and fourth replicated logic units 123 and 124 from the adjustable scale logic circuit 31 using the EDA software testing tool in the test equipment 32, and using the remaining first and second replicated logic units 121 and 122 as the second target logic circuit. Finally, the integrated circuit consisting of the integrated circuit 11, the first replicated logic unit 121, and the second replicated logic unit 122 is determined as the target integrated circuit.
[0123] In the disclosed embodiment, since the current test coverage is determined based on the consistency test results, and the consistency test results are related to each first unit under test in the first logic circuit and each second unit under test in the second logic circuit, the current test coverage corresponds to each first unit under test in the first logic circuit and each second unit under test in the second logic circuit. Furthermore, when the current test coverage and the target test coverage satisfy a preset numerical relationship, the target integrated circuit corresponding to the target test coverage can be accurately determined based on the first logic circuit and the second logic circuit.
[0124] like Figure 8 As shown in the above Figure 5 Based on the illustrated embodiment, step 504 may include the following steps 5041 and 5042 .
[0125] Step 5041, in response to the difference between the current test coverage and the target test coverage being greater than or equal to the difference threshold, based on the difference between the current test coverage and the target test coverage, determine an adjustment strategy for adjusting the first unit to be tested in the first logic circuit and the second unit to be tested in the second logic circuit.
[0126] Exemplarily, the fact that the current test coverage and the target test coverage satisfy a preset numerical relationship can be represented by the difference between the current test coverage and the target test coverage being greater than or equal to a difference threshold. The difference threshold is used to represent the degree of closeness between the current test coverage and the target test coverage, and can be determined based on the test accuracy of the functional safety test system of the integrated circuit. In some examples, since the current test coverage can approach the target test coverage in a positive direction (from small to large) or in a negative direction (from large to small), the difference threshold can be a positive value or a negative value. The embodiments of the present disclosure do not limit the positive or negative value and the specific size of the difference threshold.
[0127] Exemplarily, the adjustment strategy may include a first adjustment strategy for a first unit under test in a first logic circuit and a second adjustment strategy for adjusting a second unit under test in a second logic circuit. In some examples, the first adjustment strategy may correspond to the second adjustment strategy. For example, the first adjustment strategy is to increase the first unit under test, and the second adjustment strategy is to increase the second unit under test. For another example, the first adjustment strategy is to decrease the first unit under test, and the second adjustment strategy is to decrease the second unit under test. For another example, the first adjustment strategy is to replace the first unit under test, and the second adjustment strategy is to replace the second unit under test.
[0128] For example, refer to Figure 3 or Figure 4 As shown, step 5041 may include: when the test device 32 determines that the difference between the current test coverage and the target test coverage is greater than or equal to the difference threshold, based on the difference between the current test coverage and the target test coverage, it generates a first adjustment strategy for adjusting the logic unit (first unit to be tested) coupled to the comparator 33 or the first hash generator 341 in the logic circuit 11 and a second adjustment strategy for adjusting the copy logic unit (second unit to be tested) coupled to the comparator 33 or the second hash generator 342 in the adjustable proportional logic circuit 31.
[0129] Step 5042: Adjust the first unit under test in the first logic circuit and the second unit under test in the second logic circuit based on the adjustment strategy to obtain a first target logic circuit and a second target logic circuit.
[0130] For example, refer to Figure 3 or Figure 4 As shown, step 5042 may include: the test device 32 adjusts the logic unit coupled to the comparator 33 or the first hash generator 341 in the logic circuit 11 based on the first adjustment strategy to obtain the first target logic circuit; based on the second adjustment strategy, adjusts the copy logic unit coupled to the comparator 33 or the second hash generator 342 in the adjustable proportional logic circuit 31 to obtain the second target logic circuit.
[0131] In the embodiment of the present disclosure, since the current test coverage corresponds to each first unit under test in the first logic circuit and each second unit under test in the second logic circuit, when the difference between the current test coverage and the target test coverage is greater than or equal to the difference threshold, an adjustment strategy for adjusting the first unit under test in the first logic circuit and the second unit under test in the second logic circuit is accurately determined based on the difference between the current test coverage and the target test coverage. Furthermore, by adjusting the first unit under test in the first logic circuit and the second unit under test in the second logic circuit based on the adjustment strategy, a first target logic circuit and a second target logic circuit corresponding to the target test coverage can be obtained, thereby accelerating the speed of obtaining the target integrated circuit based on the first target logic circuit and the second target logic circuit.
[0132] like Figure 9 As shown in the above Figure 8 Based on the illustrated embodiment, step 5041 may include the following steps 901 and 902 .
[0133] Step 901: In response to the difference between the current test coverage and the target test coverage being greater than or equal to the difference threshold and greater than the first threshold, determining that the adjustment strategy is to reduce the number of first units under test in the first logic circuit and second units under test in the second logic circuit.
[0134] Exemplarily, the first threshold is used to indicate the magnitude relationship between the current test coverage and the target test coverage. If the difference between the current test coverage and the target test coverage is greater than the first threshold, then the current test coverage is greater than the target test coverage. In some examples, the first threshold can be equal to a value of 0.
[0135] For example, it is assumed that at least one first unit under test includes two logic units (a first logic unit 111 and a second logic unit 112), and at least one second unit under test includes two replicated logic units (a first replicated logic unit 121 and a second replicated logic unit 122). Figure 3 or Figure 4 As shown, step 901 may include: when the difference between the current test coverage and the target test coverage is greater than or equal to the difference threshold and greater than the first threshold, the test device 32 determines that the adjustment strategy includes a first adjustment strategy for reducing the number of at least one first unit to be tested from 2 to 1 and a second adjustment strategy for reducing the number of at least one second unit to be tested from 2 to 1.
[0136] In some examples, taking at least one first unit under test including a first logic unit 111 and a second logic unit 112 as an example, the first adjustment strategy may include removing the coupling between the first logic unit 111 or the second logic unit 112 and the comparator 33 or the first hash generator 341 .
[0137] In some examples, taking the example that at least one second unit under test includes a first replication logic unit 121 and a second replication logic unit 122 , the second adjustment strategy may include removing the coupling between the first replication logic unit 121 or the second replication logic unit 122 and the comparator 33 or the second hash generator 342 .
[0138] Step 902: In response to the difference between the current test coverage and the target test coverage being greater than or equal to a difference threshold and less than a second threshold, determining that the adjustment strategy is to increase the number of first units under test in the first logic circuit and second units under test in the second logic circuit.
[0139] Exemplarily, the second threshold is also used to indicate the magnitude relationship between the current test coverage and the target test coverage. If the difference between the current test coverage and the target test coverage is less than the second threshold, then the current test coverage is less than the target test coverage. In some examples, the second threshold can be the same as the first threshold. For example, the second threshold can also be a value of 0.
[0140] For example, it is assumed that at least one first unit under test includes two logic units (a first logic unit 111 and a second logic unit 112), and at least one second unit under test includes two replicated logic units (a first replicated logic unit 121 and a second replicated logic unit 122). Figure 3 or Figure 4 As shown, step 902 may include: when the difference between the current test coverage and the target test coverage is greater than or equal to the difference threshold and less than the second threshold, the test device 32 determines that the adjustment strategy includes a first adjustment strategy of increasing the number of at least one first unit to be tested from 2 to 3 and a second adjustment strategy of increasing the number of at least one second unit to be tested from 2 to 3.
[0141] In some examples, taking the example that at least one first unit under test includes a first logic unit 111 and a second logic unit 112 , the first adjustment strategy may include increasing the coupling between the third logic unit 113 or the fourth logic unit 114 and the comparator 33 or the first hash generator 341 .
[0142] In some examples, taking the example that at least one second unit under test includes the first replication logic unit 121 and the second replication logic unit 122 , the second adjustment strategy may include adding coupling between the third replication logic unit 123 or the fourth replication logic unit 124 and the comparator 33 or the second hash generator 342 .
[0143] In the embodiment of the present disclosure, since the current test coverage corresponds to the first unit to be tested in the first logic circuit and the second unit to be tested in the second logic circuit, when the difference between the current test coverage and the target test coverage is greater than or equal to the difference threshold, and greater than the first threshold, determining the adjustment strategy to reduce the number of the first unit to be tested in the first logic circuit and the second unit to be tested in the second logic circuit can effectively reduce the current test coverage, so that the current test coverage approaches the target test coverage. When the difference between the current test coverage and the target test coverage is greater than or equal to the difference threshold, and less than the second threshold, determining the adjustment strategy to increase the number of the first unit to be tested in the first logic circuit and the second unit to be tested in the second logic circuit can effectively increase the current test coverage, so that the current test coverage approaches the target test coverage.
[0144] In other embodiments of the present disclosure, step 5041 may also include: in response to the difference between the current test coverage and the target test coverage being greater than or equal to the difference threshold and greater than the first threshold, determining that the adjustment strategy is to replace the first unit to be tested in the first logic circuit and the second unit to be tested in the second logic circuit; in response to the difference between the current test coverage and the target test coverage being greater than or equal to the difference threshold and less than the second threshold, determining that the adjustment strategy is to replace the first unit to be tested in the first logic circuit and the second unit to be tested in the second logic circuit.
[0145] For example, taking at least one first unit under test including a first logic unit 111 and a second logic unit 112 as an example, referring to Figure 3 or Figure 4 As shown, it is taken as an example that at least one first unit under test includes a first logic unit 111 and a second logic unit 112 , and at least one second unit under test includes a first copy logic unit 121 and a second copy logic unit 122 .
[0146] refer to Figure 3 or Figure 4 As shown, in response to the difference between the current test coverage and the target test coverage being greater than or equal to the difference threshold and greater than the first threshold, determining that the adjustment strategy is to replace the first unit to be tested in the first logic circuit and the second unit to be tested in the second logic circuit may include: when the difference between the current test coverage and the target test coverage is greater than or equal to the difference threshold and greater than the first threshold, the test device 32 determines that the adjustment strategy includes a first adjustment strategy of replacing the first logic unit 111 or the second logic unit 112 with the third logic unit 113 or the fourth logic unit 114, and a second adjustment strategy of replacing the first copy logic unit 121 or the second copy logic unit 122 with the third copy logic unit 123 or the fourth copy logic unit 124.
[0147] In some examples, replacing the first logic unit 111 or the second logic unit 112 with the third logic unit 113 or the fourth logic unit 114 may include: first removing the coupling between the first logic unit 111 or the second logic unit 112 and the comparator 33 or the first hash generator 341, and then adding the coupling between the third logic unit 113 or the fourth logic unit 114 and the comparator 33 or the first hash generator 341.
[0148] like Figure 10 As shown in the above Figure 8 Based on the illustrated embodiment, step 5042 may include the following steps 1001 to 1003 .
[0149] Step 1001 : Adjust a first unit under test in a first logic circuit based on an adjustment strategy, and determine the adjusted first logic circuit as a first target logic circuit.
[0150] For example, taking the first adjustment strategy in the adjustment strategy as adding a first unit to be tested in the first logic circuit as an example, refer to Figure 3 or Figure 4 As shown, step 1001 may include: the test device 32 adds the coupling between the third logic unit 113 (or the fourth logic unit 114) and the comparator 33 or the first hash generator 341 based on the first adjustment strategy, and uses the integrated circuit 11 after adding the coupling between the third logic unit 113 (or the fourth logic unit 114) and the comparator 33 or the first hash generator 341 as the first target logic circuit.
[0151] Step 1002 : adjusting the second unit under test in the second logic circuit based on the adjustment strategy, and retaining the adjusted second unit under test in the second logic circuit to obtain at least one adjusted second unit under test.
[0152] For example, taking the second adjustment strategy in the adjustment strategy as increasing the number of the second units under test in the second logic circuit as an example, refer to Figure 3 or Figure 4 As shown, step 1002 may include: the test device 32 adds a coupling between the third replica logic unit 123 (or the fourth replica logic unit 124) and the comparator 33 or the second hash generator 342 based on the second adjustment strategy to obtain an adjusted adjustable proportional logic circuit 31. Then, the fourth replica logic unit 124 (or the third replica logic unit 123) is removed.
[0153] Step 1003: Determine at least one adjusted second unit under test as a second target logic circuit.
[0154] For example, the second adjustment strategy specifically includes increasing the coupling between the third replication logic unit 123 and the comparator 33 or the second hash generator 342. Figure 3 or Figure 4 As shown, step 1003 may include: the test device 32 determines the logic circuit after removing the fourth replica logic unit 124 from the adjustable scale logic circuit 31 as the second target logic circuit.
[0155] In an embodiment of the present disclosure, when the adjustment strategy is an adjustment strategy that can make the current test coverage and the target test coverage satisfy a preset proportional relationship, the first unit to be tested in the first logic circuit is adjusted through the adjustment strategy, and the first logic circuit corresponding to the target test coverage can be obtained; based on the adjustment strategy, the second unit to be tested in the second logic circuit is adjusted, and the second target logic circuit corresponding to the target test coverage can be obtained.
[0156] Based on the above embodiments, the embodiments of the present disclosure provide yet another functional safety testing system for integrated circuits. Figure 11 FIG. 1 is a schematic diagram showing the structure of another integrated circuit functional safety test system provided by an exemplary embodiment of the present disclosure. Figure 11 As shown, the functional safety test system 110 for integrated circuits may include an integrated circuit 111 and a test device 112 for performing a functional safety test on the integrated circuit 111. The integrated circuit 111 includes a first logic circuit 1110, a second logic circuit 1111, and a comparator 1112.
[0157] The test device 112 is configured to determine at least one first unit under test in the first logic circuit 1110 and second units under test corresponding to each first unit under test in the second logic circuit 1111 ;
[0158] A first logic circuit 1110 is coupled to the comparator 1112 and configured to output first test data to the comparator 1112 based on at least one first unit under test in the first logic circuit 1110 ;
[0159] The second logic circuit 1111 is coupled to the comparator 1112 and configured to output second test data to the comparator 1112 based on at least one second unit under test in the second logic circuit 1111 ;
[0160] A comparator 1112 coupled to the test device 112 and configured to output a consistency test result to the test device 112 based on the first test data and the second test data;
[0161] The test device 112 is used to determine the current test coverage of the integrated circuit 111 based on the consistency test result; in response to the current test coverage and the target test coverage not satisfying a preset numerical relationship, adjust the first unit to be tested in the first logic circuit 1110 and the second unit to be tested in the second logic circuit 1111 to obtain the first target logic circuit and the second target logic circuit; based on the first target logic circuit and the second target logic circuit, determine the target integrated circuit corresponding to the target test coverage.
[0162] like Figure 12 As shown in the above Figure 10 Based on the illustrated embodiment, the integrated circuit 111 may further include: a hash generator 1113;
[0163] a hash generator 1113 coupled to the first logic circuit 1110, the second logic circuit 1111, and the comparator 1112, configured to perform hash calculations on the first test data and the second test data, respectively, to obtain a first hash value corresponding to the first test data and a second hash value corresponding to the second test data, and to output the first hash value and the second hash value to the comparator 1112;
[0164] The comparator 1112 is configured to determine a consistency test result based on the first hash value and the second hash value.
[0165] like Figure 13 As shown in the above Figure 12 Based on the illustrated embodiment, the hash generator 1113 includes a first hash generator 1301 and a second hash generator 1302 .
[0166] A first hash generator 1301 is coupled to the first logic circuit 1110 and the comparator 1112 , and is configured to perform a hash calculation on the first test data and output the obtained first hash value to the comparator 1112 ;
[0167] The second hash generator 1302 is coupled to the second logic circuit 1111 and the comparator 1112 , and is configured to perform hash calculation on the second test data and output the obtained second hash value to the comparator 1112 .
[0168] Based on the above embodiments, an embodiment of the present disclosure provides a functional safety testing device for an integrated circuit. Figure 14 FIG. 1 is a schematic diagram of the structure of a functional safety test device for an integrated circuit provided by an exemplary embodiment of the present disclosure. The integrated circuit includes a first logic circuit and a second logic circuit for performing a functional safety test on the first logic circuit. Figure 14As shown, the functional safety testing device 140 for integrated circuits may include a first determining module 1401 , a functional safety testing module 1402 , a second determining module 1403 , an adjusting module 1404 , and a third determining module 1405 .
[0169] A first determining module 1401 is configured to determine at least one first unit under test in a first logic circuit and second units under test corresponding to each first unit under test in a second logic circuit;
[0170] Functional safety testing module 1402, configured to perform functional safety testing on the first logic circuit and the second logic circuit, and obtain consistency test results of first test data output by each first unit under test and second test data output by each corresponding second unit under test;
[0171] A second determining module 1403 is configured to determine a current test coverage of the integrated circuit based on the consistency test result;
[0172] an adjusting module 1404 for adjusting, in response to the current test coverage not satisfying a preset numerical relationship with the target test coverage, a first unit under test in the first logic circuit and a second unit under test in the second logic circuit to obtain a first target logic circuit and a second target logic circuit;
[0173] The third determining module 1405 is configured to determine a target integrated circuit corresponding to a target test coverage based on the first target logic circuit and the second target logic circuit.
[0174] like Figure 15 As shown in the above Figure 14 Based on the illustrated embodiment, the functional safety testing module 1402 may include a functional safety testing unit 1501 , a hash calculation unit 1502 , and a first determination unit 1503 .
[0175] The functional safety testing unit 1501 is configured to perform a functional safety test on the first logic circuit and the second logic circuit to obtain first test data and second test data.
[0176] A hash calculation unit 1502 is configured to perform hash calculations on the first test data and the second test data respectively using a hash generator in the integrated circuit to obtain a first hash value corresponding to the first test data and a second hash value corresponding to the second test data;
[0177] The first determining unit 1503 is configured to determine a consistency test result based on the first Hash value and the second Hash value.
[0178] like Figure 16 As shown in the above Figure 15Based on the illustrated embodiment, the hash calculation unit 1502 includes a first hash calculation subunit 1601 and a second hash calculation subunit 1602 .
[0179] The first hash calculation subunit 1601 is configured to perform a hash calculation on the first test data using a first hash generator to obtain a first hash value;
[0180] A second hash calculation subunit 1602 is configured to perform a hash calculation on the second test data using a second hash generator to obtain a second hash value;
[0181] The hash generator includes a first hash generator and a second hash generator.
[0182] like Figure 17 As shown in the above Figure 14 Based on the illustrated embodiment, the functional safety testing device 140 for integrated circuits may further include a fourth determining module 1406 .
[0183] The fourth determining module 1406 is configured to determine a target integrated circuit based on the first logic circuit and the second logic circuit in response to the current test coverage and the target test coverage satisfying a preset numerical relationship.
[0184] like Figure 18 As shown in the above Figure 14 Based on the illustrated embodiment, the adjustment module 1404 may include a second determining unit 1801 and an adjusting unit 1802 .
[0185] A second determining unit 1801 is configured to determine, in response to a difference between a current test coverage and a target test coverage being greater than or equal to a difference threshold, an adjustment strategy for adjusting a first unit under test in the first logic circuit and a second unit under test in the second logic circuit based on the difference;
[0186] The adjusting unit 1802 is configured to adjust the first unit under test in the first logic circuit and the second unit under test in the second logic circuit based on the adjustment strategy to obtain a first target logic circuit and a second target logic circuit.
[0187] like Figure 19 As shown in the above Figure 18 On the basis of the illustrated embodiment, the second determining unit 1801 includes a first determining subunit 1901 and a second determining subunit 1902 .
[0188] A first determining subunit 1901 is configured to determine, in response to the difference being greater than a first threshold, that the adjustment strategy is to reduce the number of first units under test in the first logic circuit and second units under test in the second logic circuit;
[0189] The second determining subunit 1902 is configured to determine, in response to the difference being less than a second threshold, that the adjustment strategy is to increase the number of first units under test in the first logic circuit and second units under test in the second logic circuit.
[0190] like Figure 20 As shown in the above Figure 18 Based on the illustrated embodiment, the adjusting unit 1802 may include a first adjusting subunit 2001 , a second adjusting subunit 2002 and a third determining subunit 2003 .
[0191] A first adjustment subunit 2001 is configured to adjust a first unit under test in a first logic circuit based on an adjustment strategy, and determine the adjusted first logic circuit as a first target logic circuit;
[0192] The second adjusting subunit 2002 is configured to adjust the second unit under test in the second logic circuit based on the adjustment strategy, and retain the adjusted second unit under test in the second logic circuit to obtain at least one adjusted second unit under test;
[0193] The third determining subunit 2003 is configured to determine at least one adjusted second unit under test as a second target logic circuit.
[0194] Exemplary electronic devices
[0195] Figure 21 FIG. 1 is a schematic diagram of the structure of an electronic device provided by an exemplary embodiment of the present disclosure. Figure 21 As shown, the electronic device 210 includes one or more processors 2101 and a memory 2102 .
[0196] The processor 2101 may be a central processing unit (CPU) or other forms of processing units having data processing capabilities and / or instruction execution capabilities, and may control other components in the electronic device 210 to perform desired functions.
[0197] The memory 2102 may include one or more computer program products, which may include various forms of computer-readable storage media, such as volatile memory and / or non-volatile memory. Volatile memory may include, for example, random access memory (RAM) and / or cache memory. Non-volatile memory may include, for example, read-only memory (ROM), a hard disk, a flash memory, etc. One or more computer program instructions may be stored on the computer-readable storage medium, and the processor 2101 may execute the program instructions to implement the functional safety testing method for the integrated circuit of each embodiment of the present disclosure and / or other desired functions.
[0198] In one example, the electronic device 210 may further include an input device 2103 and an output device 2104 , and these components are interconnected via a bus system and / or other forms of connection mechanisms (not shown).
[0199] Of course, to simplify, Figure 21 Only some of the components related to the present disclosure in the electronic device 210 are shown, and components such as buses, input / output interfaces, etc. are omitted. In addition, the electronic device 210 may further include any other appropriate components according to specific application scenarios.
[0200] Exemplary computer program products and computer-readable storage media
[0201] In addition to the above-mentioned methods and devices, an embodiment of the present disclosure may also be a computer program product, which includes computer program instructions, which, when executed by a processor, enable the processor to execute the steps of the functional safety testing method of an integrated circuit according to various embodiments of the present disclosure described in the above "Exemplary Method" section of this specification.
[0202] The computer program product may be written in any combination of one or more programming languages to implement the operations of the disclosed embodiments, including object-oriented programming languages such as Java, C++, and conventional procedural programming languages such as C or similar programming languages. The program code may be executed entirely on the user's computing device, partially on the user's computing device, as a stand-alone software package, partially on the user's computing device and partially on a remote computing device, or entirely on a remote computing device or server.
[0203] In addition, an embodiment of the present disclosure may also be a computer-readable storage medium having computer program instructions stored thereon. When the computer program instructions are executed by a processor, the processor executes the steps of the functional safety testing method for integrated circuits according to various embodiments of the present disclosure described in the above “Exemplary Method” section of this specification.
[0204] Computer readable storage media can adopt any combination of one or more readable media. The readable medium can be a readable signal medium or a readable storage medium. The readable storage medium can, for example, include but is not limited to a system, device or component of electricity, magnetism, light, electromagnetic, infrared, or semiconductor, or any combination thereof. More specific examples (non-exhaustive list) of readable storage media include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof.
[0205] The basic principles of the present disclosure have been described above in conjunction with specific embodiments. However, it should be noted that the advantages, strengths, and effects mentioned in this disclosure are merely illustrative and not restrictive, and should not be construed as necessarily possessed by each embodiment of the present disclosure. Furthermore, the specific details disclosed above are provided for illustrative purposes and to facilitate understanding, rather than as limitations. These details do not limit the present disclosure to necessarily being implemented using these specific details.
[0206] Those skilled in the art may make various changes and modifications to the present disclosure without departing from the spirit and scope of the present application. Thus, if these modifications and variations of the present application fall within the scope of the claims of the present disclosure and their equivalents, the present disclosure is intended to include these modifications and variations.
Claims
1. A functional safety testing method for an integrated circuit, wherein: The integrated circuit includes a first logic circuit and a second logic circuit for performing a functional safety test on the first logic circuit, and the method includes: Determine at least one first unit under test in the first logic circuit and second units under test in the second logic circuit corresponding to each of the first units under test; Performing a functional safety test on the first logic circuit and the second logic circuit to obtain a consistency test result of first test data output by each of the first units under test and second test data output by each of the corresponding second units under test; Determining a current test coverage of the integrated circuit based on the consistency test result; In response to the current test coverage and the target test coverage not satisfying a preset numerical relationship, adjusting a first unit under test in the first logic circuit and a second unit under test in the second logic circuit to obtain a first target logic circuit and a second target logic circuit; A target integrated circuit corresponding to the target test coverage is determined based on the first target logic circuit and the second target logic circuit.
2. The method according to claim 1, wherein: The performing functional safety test on the first logic circuit and the second logic circuit to obtain a consistency test result of first test data output by each of the first units under test and second test data output by each of the corresponding second units under test includes: Performing a functional safety test on the first logic circuit and the second logic circuit to obtain the first test data and the second test data; Performing hash calculations on the first test data and the second test data respectively by a hash generator in the integrated circuit to obtain a first hash value corresponding to the first test data and a second hash value corresponding to the second test data; The consistency test result is determined based on the first Hash value and the second Hash value.
3. The method according to claim 2, wherein: The step of performing hash calculation on the first test data and the second test data by a hash generator in the integrated circuit to obtain a first hash value and a second hash value includes: Performing hash calculation on the first test data by a first hash generator to obtain the first hash value; Performing hash calculation on the second test data by a second hash generator to obtain the second hash value; The hash generator includes the first hash generator and the second hash generator.
4. The method according to claim 1, further comprising: In response to the current test coverage and the target test coverage satisfying the preset numerical relationship, the target integrated circuit is determined based on the first logic circuit and the second logic circuit.
5. The method according to any one of claims 1 to 4, wherein: In response to the current test coverage and the target test coverage not satisfying a preset numerical relationship, adjusting the first unit under test in the first logic circuit and the second unit under test in the second logic circuit to obtain a first target logic circuit and a second target logic circuit, including: In response to a difference between the current test coverage and the target test coverage being greater than or equal to a difference threshold, determining, based on the difference, an adjustment strategy for adjusting a first unit under test in the first logic circuit and a second unit under test in the second logic circuit; The first unit under test in the first logic circuit and the second unit under test in the second logic circuit are adjusted based on the adjustment strategy to obtain the first target logic circuit and the second target logic circuit.
6. The method according to claim 5, wherein: The step of determining, based on the difference, an adjustment strategy for adjusting the first unit under test in the first logic circuit and the second unit under test in the second logic circuit comprises: In response to the difference being greater than a first threshold, determining that the adjustment strategy is to reduce the number of first units under test in the first logic circuit and second units under test in the second logic circuit; In response to the difference being less than a second threshold, determining the adjustment strategy to increase the number of first units under test in the first logic circuit and second units under test in the second logic circuit.
7. The method according to claim 5, wherein: The step of adjusting the first unit under test in the first logic circuit and the second unit under test in the second logic circuit based on the adjustment strategy to obtain the first target logic circuit and the second target logic circuit includes: Adjusting the first unit under test in the first logic circuit based on the adjustment strategy, and determining the adjusted first logic circuit as the first target logic circuit; Adjusting the second unit under test in the second logic circuit based on the adjustment strategy, and retaining the adjusted second unit under test in the second logic circuit to obtain at least one of the adjusted second unit under test; At least one of the adjusted second units under test is determined as the second target logic circuit.
8. A functional safety test system for an integrated circuit, comprising: An integrated circuit and a test device for performing functional safety test on the integrated circuit; the integrated circuit comprises a first logic circuit, a second logic circuit and a comparator; The test device is used to determine at least one first unit under test in the first logic circuit and second units under test in the second logic circuit corresponding to each of the first units under test; The first logic circuit is coupled to the comparator and is used to output first test data to the comparator based on at least one first unit under test in the first logic circuit; The second logic circuit is coupled to the comparator and is used to output second test data to the comparator based on at least one second unit under test in the second logic circuit; The comparator is coupled to the test device and is used to output a consistency test result to the test device based on the first test data and the second test data; The test device is used to determine the current test coverage of the integrated circuit based on the consistency test result; in response to the current test coverage and the target test coverage not satisfying a preset numerical relationship, adjust the first unit under test in the first logic circuit and the second unit under test in the second logic circuit to obtain a first target logic circuit and a second target logic circuit; A target integrated circuit corresponding to the target test coverage is determined based on the first target logic circuit and the second target logic circuit.
9. The system of claim 8, wherein the integrated circuit further comprises a hash generator; The hash generator is coupled to the first logic circuit, the second logic circuit and the comparator, and is used to perform hash calculations on the first test data and the second test data, respectively, to obtain a first hash value corresponding to the first test data and a second hash value corresponding to the second test data, and output the first hash value and the second hash value to the comparator; The comparator is used to determine the consistency test result based on the first Hash value and the second Hash value.
10. The system according to claim 9, wherein: The hash generator includes a first hash generator and a second hash generator; The first hash generator is coupled to the first logic circuit and the comparator, and is used to perform hash calculation on the first test data and output the obtained first hash value to the comparator; The second hash generator is coupled to the second logic circuit and the comparator, and is used for performing hash calculation on the second test data and outputting the obtained second hash value to the comparator.
11. A functional safety test device for an integrated circuit, the integrated circuit comprising a first logic circuit and a second logic circuit for performing a functional safety test on the first logic circuit, comprising: A first determining module, configured to determine at least one first unit under test in the first logic circuit and second units under test in the second logic circuit corresponding to each of the first units under test; a functional safety testing module, configured to perform a functional safety test on the first logic circuit and the second logic circuit, and obtain a consistency test result of the first test data output by each of the first units under test and the corresponding second test data output by each of the second units under test; A second determination module, configured to determine a current test coverage of the integrated circuit based on the consistency test result; an adjustment module, configured to adjust a first unit under test in the first logic circuit and a second unit under test in the second logic circuit in response to the current test coverage and the target test coverage not satisfying a preset numerical relationship, so as to obtain a first target logic circuit and a second target logic circuit; A third determination module is configured to determine a target integrated circuit corresponding to the target test coverage based on the first target logic circuit and the second target logic circuit. 12 . A computer-readable storage medium storing a computer program, wherein the computer program is used to execute the functional safety testing method for an integrated circuit according to claim 1 .
Citation Information
Cited By
Functional safety test method, system and apparatus for integrated circuit, and storage medium
EP4745588A1
Functional safety test method, system and apparatus for integrated circuit, and storage medium
WO2025246525A1
