Bayesian optimization and constraint random verification collaborative acceleration method and device

By combining Bayesian optimization and constrained stochastic verification to accelerate the process, a closed-loop coordination between test selection and stimulus generation in integrated circuit functional verification was achieved, solving the problems of coverage plateau and resource waste, and improving verification efficiency.

CN122431966APending Publication Date: 2026-07-21PRIMARIUS TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
PRIMARIUS TECH CO LTD
Filing Date
2026-04-27
Publication Date
2026-07-21

AI Technical Summary

Technical Problem

In existing integrated circuit functional verification methods, there is a disconnect between the test selection and test generation stages, resulting in a plateau in coverage during the later stages of verification. This leads to huge resource consumption but slow coverage improvement, and the reliance on experience-based adjustments can easily introduce human error.

Method used

A collaborative acceleration method combining Bayesian optimization and constrained stochastic validation is adopted. By clustering analysis and difference scoring of historical coverage data, the potential of uncovered points is identified, the branch priority is dynamically sorted, and a surrogate model is constructed to optimize the probability parameters, thereby achieving closed-loop collaboration between test selection and incentive generation.

Benefits of technology

It improves the convergence efficiency of functional coverage, reduces simulation resource consumption, shortens the verification cycle, and overcomes the coverage plateau and resource waste problems of traditional methods.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122431966A_ABST
    Figure CN122431966A_ABST
Patent Text Reader

Abstract

The application discloses a method for accelerating based on Bayesian optimization and constraint random verification, comprising the following steps: based on the coverage vector generated by historical simulation and the coverage data corresponding to the test category, the coverage clusters are obtained by clustering the coverage points and the representative sample set is constructed, the difference score is obtained by difference calculation based on the original coverage data and the representative sample set, and the execution object of the next round of simulation is obtained; based on the branch decision logic and the random variable value rule, the value preference is controlled through the probability parameter, and the parameterized constraint solver is dynamically sorted and updated according to the branch priority; based on the initial value of the probability parameter and the parameter space, the optimal probability parameter configuration is obtained through dimension reduction processing, construction of the agent model and combination of Bayesian optimization for multiple rounds of iterative search.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of electronic design automation and digital integrated circuit functional verification technology, and particularly relates to a method and apparatus for accelerating Bayesian optimization and constrained stochastic verification. Background Technology

[0002] Currently, mainstream integrated circuit functional verification methods still primarily rely on simulation-driven verification processes. This involves building a SystemVerilog-based constrained stochastic test platform at the register-transfer level (RTL) and repeatedly executing a large number of tests to achieve functional coverage convergence. The effectiveness of this method depends on the diversity and coverage of test stimuli. By generating a large number of random vectors that satisfy design rules through a constraint solver, the method gradually approaches the preset functional coverage target.

[0003] Analysis reveals significant technical deficiencies in the existing verification process, particularly in the two crucial stages of test selection and test generation. On the one hand, in the test selection phase, existing test selection methods mostly rely on similarity measurements based on test input parameters, program structure features, or static feature spaces, ignoring the functional coverage behavior generated during actual test execution. When verification enters the later stages, the number of remaining uncovered coverage points is small and their distribution is extremely uneven. Traditional selection methods based on feature diversity struggle to accurately determine which tests still have the ability to hit uncovered points, easily leading to a large number of repeated simulations and wasting computational resources.

[0004] On the other hand, in the test generation phase, existing constraint random verification relies on the SystemVerilog constraint solver to generate stimuli that meet the legality requirements. However, the branching strategies and search heuristics within the solver are usually fixed, and repeated randomizations often produce highly similar stimulus patterns, making it difficult to effectively explore low-probability triggered boundary states. In engineering practice, one can only rely on manually adjusting the distribution constraints to apply probability biases. This process is highly dependent on experience, labor-intensive, difficult to reuse, and prone to introducing human error.

[0005] Furthermore, in existing verification processes, test selection and test generation are typically run as two independent modules, either serially or loosely coupled. The test scheduling module cannot utilize the solver's internal random generation capabilities, and the constraint solver cannot adaptively adjust parameters using real-time coverage targets; the two lack an effective coordination mechanism. This fragmented architecture often leads to a significant plateau in functional coverage in the later stages of verification, resulting in substantial simulation resource consumption but slow coverage improvement. Summary of the Invention

[0006] To address the aforementioned issues, this invention proposes a collaborative acceleration method and apparatus based on Bayesian optimization and constrained stochastic verification. By using cluster analysis and difference scoring based on historical coverage data, it identifies the test category with the highest potential for uncovered points to hit, avoiding repetitive simulations caused by the reliance on static features in traditional methods. By introducing probability parameters to random variables and dynamically prioritizing branches, it achieves continuous adjustment of the stimulus generation distribution, providing a searchable parameter space for automated parameter optimization. The combination of Bayesian optimization and a surrogate model enables automatic searching for optimal probability parameter configurations, effectively exploring low-probability triggering boundary states. Through closed-loop collaborative execution of test selection, parameter optimization, and constraint solving, it achieves bidirectional information transmission between test scheduling and stimulus generation, breaking the limitations of the separation between these two processes in traditional workflows and continuously driving rapid coverage convergence.

[0007] The first aspect of this invention provides a method for accelerating Bayesian optimization and constrained stochastic verification in a coordinated manner, comprising: S100: Based on the coverage vector generated by historical simulation and the coverage data corresponding to the test category, the coverage points are clustered to obtain coverage clusters and construct a representative sample set. Based on the original coverage data and the representative sample set, the difference score is obtained through difference calculation and the execution object of the next round of simulation is obtained. S200: Based on branch decision logic and random variable value rules, it controls value preferences through probability parameters and dynamically sorts branch priorities to update the parameterized constraint solver; S300: Based on probability parameters and initial values ​​of the parameter space, the optimal probability parameter configuration is obtained through dimensionality reduction, construction of a proxy model, and multiple rounds of iterative search combined with Bayesian optimization.

[0008] Preferably, the method for accelerating Bayesian optimization and constrained stochastic verification based on claim 1 further includes: The optimal test category is obtained by executing S100 based on the current coverage status; Based on the optimal probability parameter configuration, the parameterized constraint solver described in S200 generates stimuli and performs simulation, updating the coverage data; The next iteration is carried out based on the coverage data, realizing closed-loop collaborative execution between test category selection, probability parameter optimization and constraint solving.

[0009] Preferably, the step of obtaining the execution object for the next round of simulation further includes: Based on the coverage data, a co-occurrence relationship metric is calculated between each coverage point, and cluster analysis is performed on the coverage points according to the co-occurrence relationship metric to obtain coverage clusters; By calculating the coverage ratio of each parameter in the coverage cluster, the cluster corresponding to the minimum coverage ratio is set as the target coverage cluster. Coverage data that hits the target coverage cluster is filtered from historical coverage data. Based on the coverage data, a representative sample set is obtained through balanced sampling. Calculate the degree of difference between the covered data and the representative sample set, obtain a difference score based on the degree of difference, and select the highest test category corresponding to the difference score as the execution object for the next round of simulation.

[0010] Preferably, the step of updating the parametric constraint solver further includes: Based on the branch decision logic and the random variable value rules, probability parameters are configured for each random variable to obtain a parameterized branch decision strategy. Calculate the degree of deviation between the probability parameter and the reference probability value, dynamically sort the random variables based on the degree of deviation, and assign the random variable with the largest degree of deviation the highest branch priority; Based on the sorted branch priorities, the parameterized constraint solver sequentially performs branch decisions on each random variable to obtain the value results of each random variable.

[0011] Preferably, step S300 further includes: Correlation analysis is performed on the random variables and coverage point sampling signals involved in the parametric constraint solution to identify and eliminate parameters that affect the coverage results; For the remaining probability parameters, initial parameters are selected within a preset parameter space, and simulation is performed to obtain the coverage contribution results. A surrogate model representing the mapping relationship between probability parameters and coverage contribution is constructed, and the optimal probability parameter configuration is obtained through multiple rounds of iterative search via Bayesian optimization.

[0012] Preferably, the Bayesian optimization uses the number or rate of effective sampling within a preset time as the objective function. Through iterative search, the objective function value is maximized as the optimization objective to obtain the optimal probability parameter configuration. Here, effective sampling refers to the sampling event that hits any coverage point in the target coverage cluster during the simulation process.

[0013] Preferably, the step of constructing a representative sample set further includes: For each coverage point in the target coverage cluster, the vector that hits the coverage point is selected from the historical coverage vectors. A preset number of candidate coverage vectors are uniformly extracted for each coverage point. By uniformly sampling from the candidate coverage vectors, a representative sample set of coverage is obtained.

[0014] Preferably, the step of obtaining the difference score further includes: Calculate the distance between the coverage vector of the test category and the representative sample set, extract the representative sample data with high distance from it, and calculate the difference score based on the representative sample data.

[0015] A second aspect of the present invention provides a collaborative acceleration device based on Bayesian optimization and constrained stochastic verification, comprising: The test selection unit is used to obtain coverage clusters and construct a representative sample set by clustering coverage points based on the coverage vectors generated from historical simulations and the coverage data corresponding to the test categories. Based on the original coverage data and the representative sample set, the unit calculates the difference score and obtains the execution object for the next round of simulation. The parameterized constraint solver building module is used to control the value preference through probability parameters based on branch decision logic and random variable value rules, and dynamically sort the branch priorities to update the parameterized constraint solver. The parameter tuning module is used to obtain the optimal probability parameter configuration by performing dimensionality reduction processing, constructing a surrogate model, and combining Bayesian optimization to perform multiple rounds of iterative search based on probability parameters and initial values ​​of the parameter space.

[0016] A third aspect of the present invention provides an electronic device including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the steps of a Bayesian optimization and constrained stochastic verification collaborative acceleration method as described in any of the preceding claims.

[0017] Because the present invention adopts the above technical solution, it has the following advantages and positive effects compared with the prior art: (1) By modeling and analyzing historical coverage behavior, the ability to cover test categories and the automatic selection of the optimal test categories are achieved, overcoming the shortcomings of traditional test selection methods in terms of coverage behavior.

[0018] (2) By constructing a parameterized constraint solver, the generation of random excitations with a fixed distribution is transformed into a continuous and adjustable distribution that can be controlled by probability parameters, thus overcoming the problem that traditional constraint solvers are not adjustable.

[0019] (3) By automatically iteratively searching the probability parameters through Bayesian optimization, the excitation generation distribution can be adaptively oriented to the target coverage cluster, overcoming the problems of manual adjustment relying on experience, large workload and difficulty in reuse.

[0020] (4) By implementing closed-loop collaborative execution of test selection, parameter optimization and constraint solving, the bidirectional information transmission and joint optimization of test scheduling and incentive generation are realized, overcoming the problem of coverage plateau caused by the separation of the two. Attached Figure Description

[0021] The specific embodiments of the present invention will be further described in detail below with reference to the accompanying drawings, wherein: Figure 1This is the main flowchart of a collaborative acceleration method based on Bayesian optimization and constrained stochastic verification in this invention.

[0022] Figure 2 This is one embodiment of constructing coverage data and collecting data in this invention; Figure 3 This is one embodiment of the target coverage cluster and representative sample set in this invention; Figure 4 This is one embodiment of the difference scoring in the present invention; Figure 5 This is one embodiment of the probability parameter in the present invention; Figure 6 This is one embodiment of the parameterized SystemVerilog constraint stochastic solver in this invention; Figure 7 This is one embodiment of the random variable in the present invention; Figure 8 This is one embodiment of Bayesian optimization in this invention; Figure 9 This is an embodiment of the collaborative approach of test selection, parameter optimization, and stochastic constraint solving in this invention. Detailed Implementation

[0023] The present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments. The advantages and features of the present invention will become clearer from the following description and claims. It should be noted that the drawings are all in a very simplified form and use non-precise ratios, and are only used to facilitate and clarify the illustration of the embodiments of the present invention.

[0024] It should be noted that all directional indicators (such as up, down, left, right, front, back, etc.) in the embodiments of the present invention are only used to explain the relative positional relationship and movement of each component in a certain specific posture (as shown in the figure). If the specific posture changes, the directional indicator will also change accordingly.

[0025] First Embodiment See Figures 1-9 The first aspect of the present invention provides a method for accelerating Bayesian optimization and constrained stochastic verification in a coordinated manner, comprising: S100: Based on the coverage vector generated by historical simulation and the coverage data corresponding to the test category, the coverage points are clustered to obtain coverage clusters and construct a representative sample set. Based on the original coverage data and the representative sample set, the difference score is obtained through difference calculation and the execution object of the next round of simulation is obtained. S200: Based on branch decision logic and random variable value rules, it controls value preferences through probability parameters and dynamically sorts branch priorities to update the parameterized constraint solver; S300: Based on probability parameters and initial values ​​of the parameter space, the optimal probability parameter configuration is obtained through dimensionality reduction, construction of a proxy model, and multiple rounds of iterative search combined with Bayesian optimization.

[0026] By leveraging behavior-driven test selection, parameterized constraint solver construction, and Bayesian optimization for automatic parameter tuning, the system achieves improved convergence efficiency of functional coverage by enabling the selection of test categories, targeted control of stimulus generation distribution, and optimization of probability parameters.

[0027] This application provides examples through embodiments. For details regarding the S100 process, please refer to [link / reference]. Figures 2-4 The implementation adopts the following process: S101: In the initial verification phase, a preset number of simulation tests are performed for each test category, and coverage data for each simulation is collected. The coverage data is represented in the form of a coverage vector, where each dimension corresponds to a functional coverage point, with a value of 1 indicating that the coverage point was hit in this simulation and a value of 0 indicating that it was not hit. Based on the collected coverage data, a co-occurrence relationship metric is calculated between each coverage point, and cluster analysis is performed on all coverage points according to the co-occurrence relationship metric, dividing them into 4 coverage clusters. Each coverage cluster consists of coverage points that are related in terms of functional semantics or triggering conditions, and coverage points in the same coverage cluster show a positive correlation in simulation hit behavior.

[0028] S102: During each round of test selection, the number of remaining uncovered coverage points in each coverage cluster is counted. In this embodiment, the number of remaining uncovered points in the four selected coverage clusters are 5, 9, 12, and 21, respectively. The coverage cluster with the largest number of remaining uncovered points (i.e., the smallest coverage ratio) is determined as the target coverage cluster. In this embodiment, the 32 coverage points in the target coverage cluster are selected from historical coverage data. Coverage vectors that hit each coverage point are filtered out. Five sets of candidate coverage vectors are evenly extracted for each coverage point. Then, a representative sample set including coverage behavior is obtained by evenly sampling from the extracted candidate coverage vectors. In this embodiment, a total of 20 sets of coverage vectors are used.

[0029] S103: Calculate the degree of difference between the historical coverage vector of each test category and the representative sample set. In a specific example, a distance metric is used to calculate the degree of difference. For each test category, representative high-distance samples are extracted based on the distance distribution of its internal samples, and a difference score is calculated accordingly. In this embodiment, the scores for the three test categories are 0.31, 0.58, and 0.42, respectively. The test category with the highest score (0.58) is selected as the execution object for this round of simulation.

[0030] For details regarding the S200 process, please refer to [link / reference]. Figures 5-6 The implementation adopts the following process: S201: Select Boolean random variables A, B, C, and D from the random variables participating in the SystemVerilog constraint solution, and assign corresponding probability parameters θ to each random variable. A θ B θ C θ D The probability parameter controls the probability weight of the corresponding random variable taking a value of 1 during randomization. In a specific parameter configuration, θ is set... A =0.65, θ B =0.80, θ C =0.50, θ D =0.20, meaning the probability of variable A taking the value 1 is 65%, the probability of variable B taking the value 1 is 80%, the probability of variable C taking the value 1 is 50%, and the probability of variable D taking the value 1 is 20%.

[0031] S202: Before starting the constraint solution, calculate the deviation of each probability parameter from the reference probability value (0.5), and use the degree of deviation as the basis for prioritizing branches. Calculate the deviation for each variable: |0.50-θ A |=0.15、|0.50-θ B |=0.30、|0.50-θ C |=0.00、|0.50-θ D |=0.30; The branch priority order is determined based on the degree of deviation: variables B (deviation 0.30) and D (deviation 0.30) have the highest priority, followed by variable A (deviation 0.15), and variable C has the lowest priority (deviation 0.00). The specific ranking result is B, D, A, C.

[0032] S203: The solver performs branch decisions on each random variable sequentially according to the branch priority order. In a specific example: variable B has an 80% probability of taking the value 1, and is taken as 1 in this solution; variable D has a 20% probability of taking the value 1, and is taken as 0 in this solution; variable A has a 65% probability of taking the value 1, and is taken as 1 in this solution; variable C has an equal probability of taking the value 0 or 1, and is taken as 0 in this solution. Under the premise of satisfying the original SystemVerilog constraints, the values ​​of each random variable are obtained as {A=1, B=1, C=0, D=0}, which is used as a set of random stimulus configurations.

[0033] For details regarding the S300 process, please refer to [link / reference]. Figures 7-8 The implementation adopts the following process: S301: Perform correlation analysis on the random variables involved in solving the parameterized constraints and the sampling signals of the coverage points. In a specific example, a total of 5 random variables participate in the parameterization process. Based on their influence on the sampling signals of the coverage points, identify the random variables that have a dominant influence on the coverage results and are prone to causing excessive bias in the excitation distribution. Two highly correlated random variables, D and E, are excluded from the parameterization optimization set, while the remaining 3 random variables A, B, and C are retained for subsequent parameter optimization to reduce the dimensionality of the parameter space.

[0034] S302: For the three retained random variables A, B, and C, introduce the corresponding probability parameter θ. A θ B θ C An optimization search is performed. Multiple sets of initial parameters are selected within a preset parameter space, and constrained stochastic solutions and simulations are performed respectively, collecting the coverage contribution results corresponding to each set of parameters. Based on historical parameters and their corresponding coverage contribution results, a surrogate model representing the mapping relationship between probability parameters and target coverage contribution is constructed. According to the surrogate model, Bayesian optimization techniques are used to determine the next set of candidate parameters, and the probability parameters are continuously updated through multiple iterations. In a specific optimization result, when θ... A *=0.70、θ B *=0.25、θ C When *=0.60, the target coverage cluster sampling is fastest, obtaining 120 valid samples within a 10-second simulation time. The corresponding sampling rate selected in the objective function value is 12. Valid sampling refers to the sampling event that hits any coverage point in the target coverage cluster during the simulation. Bayesian optimization uses the number of valid samples or the sampling rate within a preset time as the objective function, aiming to maximize the objective function value. This set of parameters is then configured as the optimal probability parameters for the current round.

[0035] For details regarding the S400 process, please refer to [link / reference]. Figure 9 The implementation adopts the following process: S401: Based on the current coverage status, execute the method described in S100 to obtain the optimal test category; S402: Based on the optimal probability parameters θA*=0.70, θB*=0.25, θC*=0.60 obtained in S300, configure the parameterized constraint solver described in S200; S403: Generate random stimuli and execute simulation using the parametric constraint solver; S404: Update the coverage data and use the updated coverage state as the input for the next iteration; Return to step one to form a closed-loop collaborative execution between test selection, parameter optimization and constraint solving.

[0036] Preferred options also include: The optimal test category is obtained by executing S100 based on the current coverage status; Based on the optimal probability parameter configuration, the parameterized constraint solver described in S200 generates stimuli and performs simulation, updating the coverage data; The next iteration is carried out based on the coverage data, realizing closed-loop collaborative execution between test category selection, probability parameter optimization and constraint solving.

[0037] By using the current coverage status as input to S100, test selection responds in real time to coverage conditions, ensuring that each round targets the weakest coverage area. By implicitly guiding the parameter optimization direction of S300 with the optimal test category output by S100, test requirements are transferred to parameter optimization, giving stimulus generation a clear coverage target orientation. By configuring the optimal probability parameters output by S300 into the constraint solver of S200, the transformation of parameter optimization results into stimulus generation is achieved, enabling the random stimulus distribution to adaptively bias towards the target coverage cluster. By using the updated coverage data from simulation results as input for the next iteration, an automatic loop of selection, optimization, generation, simulation, and feedback is formed, achieving adaptive iterative optimization of the verification process. Through this closed-loop collaborative mechanism, the limitations of the separation between test selection and stimulus generation in traditional verification are broken, enabling continuous targeted attacks on remaining uncovered points, overcoming the plateau bottleneck of slow coverage growth in the later stages of verification, and significantly reducing simulation resource consumption.

[0038] Preferably, the step of obtaining the execution object for the next round of simulation further includes: Based on the coverage data, a co-occurrence relationship metric is calculated between each coverage point, and cluster analysis is performed on the coverage points according to the co-occurrence relationship metric to obtain coverage clusters; By calculating the coverage ratio of each parameter in the coverage cluster, the cluster corresponding to the minimum coverage ratio is set as the target coverage cluster. Coverage data that hits the target coverage cluster is filtered from historical coverage data. Based on the coverage data, a representative sample set is obtained through balanced sampling. Calculate the degree of difference between the covered data and the representative sample set, obtain a difference score based on the degree of difference, and select the highest test category corresponding to the difference score as the execution object for the next round of simulation.

[0039] By calculating the co-occurrence relationship metric between coverage points and performing cluster analysis, functionally semantically related coverage points are grouped into the same coverage cluster, providing a structured foundation for subsequent target localization. By calculating the coverage ratio of each coverage cluster and setting the cluster corresponding to the minimum value as the target coverage cluster, automatic identification of the coverage area with the lowest current coverage rate and the greatest need for attention is achieved. Through balanced sampling from the coverage data hitting the target coverage cluster, a representative sample set capable of characterizing the typical triggering patterns of the target coverage cluster is constructed. By calculating the degree of difference between the coverage data of each test category and the representative sample set and comparing scores, the test category with the greatest potential for coverage improvement is selected. Through the complete process of clustering, target cluster selection, sample construction, and scoring selection described above, coverage behavior-driven test selection is achieved, overcoming the technical problem of traditional methods based on static feature selection leading to many invalid simulations in the later stages.

[0040] Preferably, the step of updating the parametric constraint solver further includes: Based on the branch decision logic and the random variable value rules, probability parameters are configured for each random variable to obtain a parameterized branch decision strategy. Calculate the degree of deviation between the probability parameter and the reference probability value, dynamically sort the random variables based on the degree of deviation, and assign the random variable with the largest degree of deviation the highest branch priority; Based on the sorted branch priorities, the parameterized constraint solver sequentially performs branch decisions on each random variable to obtain the value results of each random variable.

[0041] By configuring probability parameters for each random variable to control its value preference, a traditional fixed-distribution constraint solver is transformed into a parameterized solver with continuously adjustable excitation generation distribution. The deviation of the probability parameters from a reference probability value (e.g., 0.5) is calculated to quantitatively evaluate the bias strength of each random variable. By dynamically ranking the random variables based on their deviation and assigning the variable with the largest deviation the highest branch priority, a positive correlation between bias strength and decision priority is achieved. By performing branch decisions on each random variable according to the ranked branch priorities, stochastic excitations with directional probability biases are generated while satisfying the original constraints. Through this parameterized configuration and dynamic ranking mechanism, the constraint solver is transformed from a fixed strategy to an adjustable and adaptive one, effectively solving the problem that traditional methods struggle to explore low-probability boundary states.

[0042] Preferably, step S300 further includes: Correlation analysis is performed on the random variables and coverage point sampling signals involved in the parametric constraint solution to identify and eliminate parameters that affect the coverage results; For the remaining probability parameters, initial parameters are selected within a preset parameter space, and simulation is performed to obtain the coverage contribution results. A surrogate model representing the mapping relationship between probability parameters and coverage contribution is constructed, and the optimal probability parameter configuration is obtained through multiple rounds of iterative search via Bayesian optimization.

[0043] By performing correlation analysis on random variables and sampling signals of coverage points, variables with a dominant influence on coverage results were identified and eliminated, thus reducing the dimensionality of the parameter optimization space and preventing the excitation distribution from being overly concentrated on a few coverage points. Initial parameters were selected within a preset parameter space, and simulations were performed to obtain coverage contribution results, providing initial training data for surrogate model construction. By constructing a surrogate model representing the mapping relationship between probability parameters and coverage contributions, the actual mapping relationship was approximated with a small amount of simulation data, significantly reducing the total number of simulations required for optimization. Through multi-round iterative search using Bayesian optimization, the parameter space was efficiently explored within the simulation budget, intelligently balancing the exploration of unknown regions with the utilization of known optimal regions.

[0044] Preferably, the Bayesian optimization uses the number or rate of effective sampling within a preset time as the objective function. Through iterative search, the objective function value is maximized as the optimization objective to obtain the optimal probability parameter configuration. Here, effective sampling refers to the sampling event that hits any coverage point in the target coverage cluster during the simulation process.

[0045] By defining the effective sampling count or rate within a preset time period as the objective function of Bayesian optimization, the parameter optimization objective is directly aligned with the ultimate verification objective of accelerating coverage convergence. By defining effective sampling as a sampling event that hits any coverage point in the target coverage cluster during simulation, a quantitative evaluation of whether each set of probability parameters can effectively hit the target coverage cluster is achieved. By using the effective sampling rate within a preset time period as the optimization objective, the coverage efficiency per unit time is maximized, ensuring that the optimal parameters generate the most effective samples in the shortest time. By using a fixed preset time window as the evaluation period, fair and standardized comparisons between different probability parameter configurations are achieved, eliminating evaluation bias caused by different simulation durations. Through the definition and optimization mechanism of the above objective function, rapid coverage of the target coverage cluster is achieved, shortening the simulation time required to reach the coverage target and accelerating the verification convergence process.

[0046] Preferably, the step of constructing a representative sample set further includes: For each coverage point in the target coverage cluster, the vector that hits the coverage point is selected from the historical coverage vectors. A preset number of candidate coverage vectors are uniformly extracted for each coverage point. By uniformly sampling from the candidate coverage vectors, a representative sample set of coverage is obtained.

[0047] By individually selecting historical vectors that hit each coverage point in the target coverage cluster, comprehensive coverage of all coverage points within the target coverage cluster is achieved by the representative sample set, avoiding any omission of coverage points of interest. By uniformly extracting a predetermined number of candidate coverage vectors for each coverage point, a balance is achieved among the candidate sample sets, eliminating sample bias caused by different trigger frequencies of coverage points. Secondary uniform sampling from the candidate coverage vectors further simplifies the candidate sample set, reducing sample redundancy and noise interference, and improving the quality of the representative sample set. Through this construction process, a reliable benchmark capable of characterizing the typical triggering patterns of the target coverage cluster is provided for subsequent test category scoring, ensuring the accuracy of the difference scoring results. The balanced sampling mechanism achieves a reasonable allocation of limited validation resources among the coverage points, avoiding excessive concentration of validation resources and improving overall validation efficiency.

[0048] Preferably, the step of obtaining the difference score further includes: Calculate the distance between the coverage vector of the test category and the representative sample set, extract the representative sample data with high distance from it, and calculate the difference score based on the representative sample data.

[0049] By calculating the distance between the coverage vector of each test category and each sample in the representative sample set, a quantitative assessment of the ability of each test category to hit the target coverage cluster is achieved, transforming the abstract coverage capability into a comparable numerical indicator. By extracting representative sample data with high distances from the representative sample set, representative samples are selected, focusing on the most discriminative samples and avoiding the dilution of the score's discriminative power by a large number of similar samples. Calculating the difference score based on high-distance representative sample data improves the robustness of the scoring results to sample noise and outliers, preventing a few abnormal samples from having an excessive impact on the score. By using the difference score as the basis for test category selection and selecting the test category with the highest score, the test category most likely to bring new coverage behavior is selected, directly addressing the improvement of coverage capability. Through the above difference scoring mechanism, even when the remaining uncovered points are scarce and unevenly distributed in the later stages of validation, the most promising test categories can still be effectively identified.

[0050] Second Embodiment A second aspect of the present invention provides a collaborative acceleration device based on Bayesian optimization and constrained stochastic verification, comprising: The test selection unit is used to obtain coverage clusters and construct a representative sample set by clustering coverage points based on the coverage vectors generated from historical simulations and the coverage data corresponding to the test categories. Based on the original coverage data and the representative sample set, the unit calculates the difference score and obtains the execution object for the next round of simulation. The parameterized constraint solver building module is used to control the value preference through probability parameters based on branch decision logic and random variable value rules, and dynamically sort the branch priorities to update the parameterized constraint solver. The parameter tuning module is used to obtain the optimal probability parameter configuration by performing dimensionality reduction processing, constructing a surrogate model, and combining Bayesian optimization to perform multiple rounds of iterative search based on probability parameters and initial values ​​of the parameter space.

[0051] The test selection unit automatically filters the test categories with the greatest coverage potential by clustering historical coverage data and constructing a representative sample set, overcoming the shortcomings of traditional test selection methods that ignore coverage behavior. The parameterized constraint solver construction module transforms a fixed-distribution constraint solver into a continuously adjustable stimulus generator by configuring probability parameters for random variables and dynamically prioritizing branches. The parameter tuning module automates the search for optimal probability parameter configurations through dimensionality reduction, surrogate model construction, and Bayesian optimization iterative search, eliminating the need for manual intervention.

[0052] Third Embodiment A third aspect of the present invention provides an electronic device including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the steps of a Bayesian optimization and constrained stochastic verification collaborative acceleration method as described in any of the preceding claims.

[0053] By executing the computer program stored in memory through the processor, all steps of the method described in the first aspect are implemented, including the coordinated work of behavior-driven test selection, parameterized constraint solver construction, and Bayesian optimization automatic parameter tuning. Through the automated execution of the above method, joint optimization of test selection and stimulus generation in the chip verification process of electronic devices is achieved, significantly improving the convergence efficiency of functional coverage, reducing simulation resource consumption, and shortening the chip verification cycle.

[0054] In the description of this application, it should be noted that the terms "inner" and "outer," etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings, or the orientation or positional relationship commonly used when the product is in use. They are used only for the convenience of describing this application and for simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, they should not be construed as limitations on this application. Furthermore, the terms "first," "second," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.

[0055] It should also be noted that, unless otherwise explicitly specified and limited, the terms "setup" and "connection" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal connection of two components. Those skilled in the art can understand the specific meaning of the above terms in this application based on the specific circumstances.

[0056] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific identification content executed by the system and device described above can be referred to the corresponding process in the foregoing method embodiments.

[0057] The embodiments of the present invention have been described in detail above with reference to the accompanying drawings, but the present invention is not limited to the above embodiments. Even if various changes are made to the present invention, if these changes fall within the scope of the claims of the present invention and their equivalents, they shall still fall within the protection scope of the present invention.

Claims

1. A method for accelerating Bayesian optimization and constrained stochastic verification through joint acceleration, characterized in that, include: S100: Based on the coverage vector generated by historical simulation and the coverage data corresponding to the test category, the coverage points are clustered to obtain coverage clusters and construct a representative sample set. Based on the original coverage data and the representative sample set, the difference score is obtained through difference calculation and the execution object of the next round of simulation is obtained. S200: Based on branch decision logic and random variable value rules, it controls value preferences through probability parameters and dynamically sorts branch priorities to update the parameterized constraint solver; S300: Based on probability parameters and initial values ​​of the parameter space, the optimal probability parameter configuration is obtained through dimensionality reduction, construction of a proxy model, and multiple rounds of iterative search combined with Bayesian optimization.

2. The method for accelerating Bayesian optimization and constrained stochastic verification based on claim 1, characterized in that, Also includes: The optimal test category is obtained by executing S100 based on the current coverage status; Based on the optimal probability parameter configuration, the parameterized constraint solver described in S200 generates stimuli and performs simulation, updating the coverage data; The next iteration is carried out based on the coverage data, realizing closed-loop collaborative execution between test category selection, probability parameter optimization and constraint solving.

3. The method for accelerating Bayesian optimization and constrained stochastic verification based on claim 1, characterized in that, The steps for obtaining the execution object for the next round of simulation further include: Based on the coverage data, a co-occurrence relationship metric is calculated between each coverage point, and cluster analysis is performed on the coverage points according to the co-occurrence relationship metric to obtain coverage clusters; By calculating the coverage ratio of each parameter in the coverage cluster, the cluster corresponding to the minimum coverage ratio is set as the target coverage cluster. Coverage data that hits the target coverage cluster is filtered from historical coverage data. Based on the coverage data, a representative sample set is obtained through balanced sampling. Calculate the degree of difference between the covered data and the representative sample set, obtain a difference score based on the degree of difference, and select the highest test category corresponding to the difference score as the execution object for the next round of simulation.

4. The method for accelerating Bayesian optimization and constrained stochastic verification based on claim 1, characterized in that, The steps of updating the parametric constraint solver further include: Based on the branch decision logic and the random variable value rules, probability parameters are configured for each random variable to obtain a parameterized branch decision strategy. Calculate the degree of deviation between the probability parameter and the reference probability value, dynamically sort the random variables based on the degree of deviation, and assign the random variable with the largest degree of deviation the highest branch priority; Based on the sorted branch priorities, the parameterized constraint solver sequentially performs branch decisions on each random variable to obtain the value results of each random variable.

5. The method for accelerating Bayesian optimization and constrained stochastic verification based on claim 1, characterized in that, The steps of S300 further include: Correlation analysis is performed on the random variables and coverage point sampling signals involved in the parametric constraint solution to identify and eliminate parameters that affect the coverage results; For the remaining probability parameters, initial parameters are selected within a preset parameter space, and simulation is performed to obtain the coverage contribution results. A surrogate model representing the mapping relationship between probability parameters and coverage contribution is constructed, and the optimal probability parameter configuration is obtained through multiple rounds of iterative search via Bayesian optimization.

6. The method for accelerating Bayesian optimization and constrained stochastic verification based on claim 1, characterized in that, The Bayesian optimization uses the number or rate of effective sampling within a preset time as the objective function. Through iterative search, the goal is to maximize the value of the objective function and obtain the optimal probability parameter configuration. Here, effective sampling refers to the sampling event that hits any coverage point in the target coverage cluster during the simulation process.

7. The method for accelerating Bayesian optimization and constrained stochastic verification based on claim 1, characterized in that, The steps of constructing a representative sample set further include: For each coverage point in the target coverage cluster, the vector that hits the coverage point is selected from the historical coverage vectors. A preset number of candidate coverage vectors are uniformly extracted for each coverage point. By uniformly sampling from the candidate coverage vectors, a representative sample set of coverage is obtained.

8. The method for accelerating Bayesian optimization and constrained stochastic verification based on claim 1, characterized in that, The steps to obtain the difference score further include: Calculate the distance between the coverage vector of the test category and the representative sample set, extract the representative sample data with high distance from it, and calculate the difference score based on the representative sample data.

9. A collaborative acceleration device based on Bayesian optimization and constrained stochastic verification, characterized in that, include: The test selection unit is used to obtain coverage clusters and construct a representative sample set by clustering coverage points based on the coverage vectors generated from historical simulations and the coverage data corresponding to the test categories. Based on the original coverage data and the representative sample set, the unit calculates the difference score and obtains the execution object for the next round of simulation. The parameterized constraint solver building module is used to control the value preference through probability parameters based on branch decision logic and random variable value rules, and dynamically sort the branch priorities to update the parameterized constraint solver. The parameter tuning module is used to obtain the optimal probability parameter configuration by performing dimensionality reduction processing, constructing a surrogate model, and combining Bayesian optimization to perform multiple rounds of iterative search based on probability parameters and initial values ​​of the parameter space.

10. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the computer program is executed by the processor, it implements the steps of the method for accelerating Bayesian optimization and constrained stochastic verification as described in any one of claims 1-8.