A computing cluster joint simulator synchronization processing method, device and system

By setting synchronization cycles and data exchange mechanisms for multiple emulators in a computer cluster, the development difficulty and simulation accuracy problems in cluster simulation are solved, and the simulation efficiency and accuracy are improved.

CN118227261BActive Publication Date: 2025-01-07TSINGHUA UNIVERSITY
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410321008.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-03-20
Publication Date
2025-01-07
Estimated Expiration
2044-03-20

AI Technical Summary

Technical Problem

In the computer cluster simulation scenario, a single emulator performs a whole cluster simulation solution with problems such as difficult development, difficult simulation architecture, and long development cycle. In the case of joint simulation of multiple emulators, simulation accuracy, granularity and results depend on each other. question.

Method used

By calculating multiple emulators in the cluster to obtain synchronization cycles, unify the simulation time on the time scale, execute simulation tasks independently within each synchronization cycle, and exchange synchronous data at the end of each synchronization cycle to ensure that the execution of simulation tasks is consistent. .

Benefits of technology

It improves simulation efficiency and synchronization accuracy, realizes efficient parallel processing of simulation tasks, and ensures the accuracy of simulation results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118227261B_ABST
    Figure CN118227261B_ABST
Patent Text Reader

Abstract

The present disclosure relates to the field of simulation technology, and in particular to a method, device and system for synchronous processing of joint simulators in a computing cluster. The method comprises: a plurality of simulators in a computing cluster obtain a synchronization period, and the synchronization period is used to unify the simulation time of the plurality of simulators in the computing cluster on a time scale; in each synchronization period, the plurality of simulators in the computing cluster independently execute their respective simulation tasks; at the end of each synchronization period, the plurality of simulators in the computing cluster exchange their respective synchronization data, and the synchronization data is used to indicate the execution status of the simulation task. The method for synchronous processing of joint simulators in a computing cluster provided in an embodiment of the present disclosure can ensure that each simulator is synchronized at the same time point by exchanging synchronization data at the end of the synchronization period, thereby improving the synchronization accuracy of the simulation and ensuring the accuracy of the simulation results.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of simulation technology, and in particular to a method, device and system for synchronous processing of a computing cluster and a joint simulator. Background Art

[0002] In computer cluster design, simulation technology is an important tool that can help designers predict and evaluate key indicators such as cluster performance, reliability, and scalability before actually building and deploying the cluster.

[0003] In the computing cluster simulation scenario, due to the large size and multiple functions of the cluster to be simulated, the solution of using a single simulator to simulate the entire cluster has the disadvantages of difficulty in joint development by developers, difficulty in integrating simulation architectures, and long development cycles. When two or more simulators perform joint simulation to simulate the operating status of multiple interconnected systems, there are problems such as simulation accuracy, simulation granularity, and mutual dependence of simulation results of each simulator.

[0004] Therefore, how to effectively jointly simulate multiple simulators is an important challenge in the current field of computing cluster simulation systems. Summary of the invention

[0005] In view of this, the present disclosure proposes a computing cluster joint simulator synchronization processing method, device and system.

[0006] According to one aspect of the present disclosure, a method for synchronously processing a computing cluster and a simulator is provided, the method comprising:

[0007] The multiple simulators in the computing cluster acquire a synchronization period, and the synchronization period is used to unify the simulation time of the multiple simulators in the computing cluster on a time scale;

[0008] In each synchronization period, the multiple simulators in the computing cluster independently execute respective simulation tasks;

[0009] At the end of each synchronization cycle, the plurality of simulators in the computing cluster exchange respective synchronization data, where the synchronization data is used to indicate the execution status of the simulation task.

[0010] In a possible implementation, in each synchronization period, the multiple simulators in the computing cluster independently execute respective simulation tasks, including:

[0011] In each synchronization cycle, the multiple simulators in the computing cluster independently execute their respective simulation tasks according to their respective clock cycles;

[0012] Among the clock cycles of the multiple simulators in the computing cluster, at least two clock cycles are different, or the clock cycles of the multiple simulators in the computing cluster are all different.

[0013] In another possible implementation, the multiple simulators of the computing cluster include at least one computing simulator and at least one communication simulator, the computing simulator is used to simulate the computing content of the computing node, and the communication simulator is used to simulate the processing content of the communication node.

[0014] In another possible implementation, at the end of each synchronization cycle, the plurality of simulators in the computing cluster exchange respective synchronization data, including:

[0015] At the end of each synchronization cycle, each simulator sends its own synchronization data to other simulators;

[0016] The method further comprises:

[0017] After receiving the synchronization data from other simulators, each simulator stores the synchronization data from other simulators in a local synchronization data buffer.

[0018] In another possible implementation, the method further includes:

[0019] At the beginning of each of the other synchronization cycles, each of the simulators obtains the synchronization data corresponding to the previous synchronization cycle in the local synchronization data buffer, and each of the other synchronization cycles is each of the other synchronization cycles except the first synchronization cycle;

[0020] In each of the other synchronization cycles, each simulator performs the simulation task of the current synchronization cycle according to the synchronization data corresponding to the previous synchronization cycle.

[0021] In another possible implementation, the synchronization data includes a simulation state and a simulation timestamp corresponding to the simulation task.

[0022] In another possible implementation, the multiple simulators in the computing cluster are different simulators in the same simulation instance, and the multiple simulators in the computing cluster exchange their respective synchronization data using the same interaction protocol.

[0023] In another possible implementation, the interaction protocol is used to indicate the global start time, the global end time and the synchronization period of the multiple simulators in the computing cluster.

[0024] According to another aspect of the present disclosure, a computing cluster joint simulator synchronization processing device is provided, the device comprising:

[0025] A synchronization period acquisition module, used to acquire a synchronization period, wherein the synchronization period is used to unify the simulation time of multiple simulators in the computing cluster on a time scale;

[0026] A simulation task execution module, used for independently executing the simulation task of the simulator itself in each synchronization cycle;

[0027] The synchronous data exchange module is used to exchange respective synchronous data with other simulators at the end of each synchronous cycle, and the synchronous data is used to indicate the execution status of the simulation task.

[0028] In a possible implementation, the simulation task execution module is further used to independently execute its own simulation task according to the simulator's own clock cycle within each synchronization period;

[0029] Among the clock cycles of the multiple simulators in the computing cluster, at least two clock cycles are different, or the clock cycles of the multiple simulators in the computing cluster are all different.

[0030] In another possible implementation, the multiple simulators of the computing cluster include at least one computing simulator and at least one communication simulator, the computing simulator is used to simulate the computing content of the computing node, and the communication simulator is used to simulate the processing content of the communication node.

[0031] In another possible implementation, the synchronization data exchange module is further used to send the synchronization data of the simulator itself to other simulators at the end of each synchronization cycle;

[0032] The device further comprises: a storage module, which is used to store the synchronization data of other simulators in a local synchronization data buffer after receiving the synchronization data of other simulators.

[0033] In another possible implementation, the simulation task execution module is further used to obtain the synchronization data corresponding to the previous synchronization cycle in the local synchronization data buffer at the beginning of each other synchronization cycle, and each other synchronization cycle is each synchronization cycle other than the first synchronization cycle;

[0034] In each of the other synchronization cycles, the simulation task of the current synchronization cycle is executed according to the synchronization data corresponding to the previous synchronization cycle.

[0035] In another possible implementation, the synchronization data includes a simulation state and a simulation timestamp corresponding to the simulation task.

[0036] In another possible implementation, the multiple simulators in the computing cluster are different simulators in the same simulation instance, and the multiple simulators in the computing cluster exchange their respective synchronization data using the same interaction protocol.

[0037] In another possible implementation, the interaction protocol is used to indicate the global start time, the global end time and the synchronization period of the multiple simulators in the computing cluster.

[0038] According to another aspect of the present disclosure, a computing cluster simulation system is provided. The system includes a plurality of simulators of a computing cluster. The system is used to implement the above method.

[0039] According to another aspect of the present disclosure, a computing device is provided, the computing device comprising:

[0040] processor;

[0041] a memory for storing processor-executable instructions;

[0042] The processor is configured to implement the method provided by the first aspect or any possible implementation manner of the first aspect when executing the instructions stored in the memory.

[0043] According to another aspect of the present disclosure, a non-volatile computer-readable storage medium is provided, on which computer program instructions are stored. When the computer program instructions are executed by a processor, the method provided by the above-mentioned first aspect or any possible implementation manner of the first aspect is implemented.

[0044] According to another aspect of the present disclosure, a computer program product is provided, including a computer-readable code, or a non-volatile computer-readable storage medium carrying the computer-readable code. When the computer-readable code runs in a processor of a computing device, the processor in the computing device executes the method provided by the first aspect or any possible implementation of the first aspect.

[0045] The disclosed embodiment provides a method for synchronous processing of a computing cluster joint simulator, wherein a synchronization period is obtained by computing multiple simulators in the cluster, and the synchronization period is used to unify the simulation time of the multiple simulators in the computing cluster on a time scale; within each synchronization period, the multiple simulators in the computing cluster independently execute their respective simulation tasks; at the end of each synchronization period, the multiple simulators in the computing cluster exchange their respective synchronization data, and the synchronization data is used to indicate the execution status of the simulation task; on the one hand, the simulation efficiency is improved: since each simulator can run independently within the synchronization period, this allows parallel computing, thereby improving the overall simulation efficiency; on the other hand, the synchronization accuracy of the simulation is improved: by exchanging synchronization data at the end of the synchronization period, it can be ensured that each simulator is synchronized at the same time point, thereby improving the synchronization accuracy of the simulation. That is to say, the method for synchronous processing of a computing cluster joint simulator provided by the disclosed embodiment realizes efficient parallel processing of simulation tasks through the exchange of synchronization periods and synchronization data, while ensuring the accuracy of the simulation results.

[0046] Further features and aspects of the present disclosure will become apparent from the following detailed description of exemplary embodiments with reference to the attached drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0047] The accompanying drawings, which are incorporated in and constitute a part of the specification, illustrate exemplary embodiments, features, and aspects of the disclosure and, together with the description, serve to explain the principles of the disclosure.

[0048] Figure 1 A schematic diagram of the structure of a computing cluster simulation system provided by an exemplary embodiment of the present disclosure is shown.

[0049] Figure 2 A flowchart of a method for synchronously processing a computing cluster and a joint simulator provided by an exemplary embodiment of the present disclosure is shown.

[0050] Figure 3 A flowchart of a method for synchronously processing a computing cluster and a joint simulator provided by another exemplary embodiment of the present disclosure is shown.

[0051] Figure 4 A schematic diagram showing the principles of a computing cluster joint simulator synchronization method provided by an exemplary embodiment of the present disclosure.

[0052] Figure 5 A schematic diagram showing the principles of a computing cluster joint simulator synchronization processing method provided by another exemplary embodiment of the present disclosure.

[0053] Figure 6 A schematic diagram of the structure of a computing cluster joint simulator synchronization processing device provided by an exemplary embodiment of the present disclosure is shown. DETAILED DESCRIPTION

[0054] Various exemplary embodiments, features and aspects of the present disclosure will be described in detail below with reference to the accompanying drawings. The same reference numerals in the accompanying drawings represent elements with the same or similar functions. Although various aspects of the embodiments are shown in the accompanying drawings, the drawings are not necessarily drawn to scale unless otherwise specified.

[0055] The word “exemplary” is used exclusively herein to mean “serving as an example, example, or illustration.” Any embodiment described herein as “exemplary” is not necessarily to be construed as preferred or advantageous over other embodiments.

[0056] In addition, in order to better illustrate the present disclosure, numerous specific details are given in the following specific embodiments. It should be understood by those skilled in the art that the present disclosure can also be implemented without certain specific details. In some examples, methods, means, components and circuits well known to those skilled in the art are not described in detail in order to highlight the subject matter of the present disclosure.

[0057] First, some terms involved in the embodiments of the present disclosure are introduced.

[0058] 1. Model: It is an abstract representation of the characteristics and behavior of a system in the real world. A model can be a mathematical, logical or linguistic description used to simulate the operation of a real system.

[0059] 2. Simulation: It is a model-based activity that experiments on models through computer programs to study existing or designed systems. The purpose of simulation is to analyze the performance and response of a system by imitating the behavior of the system.

[0060] 3. Simulator: A software or hardware tool that performs the simulation process. It can imitate the behavior of one or more devices, whether it is an integrated circuit or a complete set of devices.

[0061] Then, the application scenarios involved in the embodiments of the present disclosure are introduced. The computing cluster joint simulator synchronization processing method provided in the embodiments of the present disclosure can be applied to a computing cluster simulation system. The computing cluster simulation system is a software tool for simulating the functions and performance of a computing cluster. One type of computing cluster may be a heterogeneous cluster, which is a computing platform composed of computing nodes with different hardware and / or software configurations, capable of performing a variety of different tasks. By using the computing cluster simulation system, the functions and performance of the computing cluster can be predicted and evaluated without actually building physical hardware. One of the simulation contents of the computing cluster simulation system may include a distributed computing system, which includes at least one computing node and at least one communication node. The computing cluster simulation system includes multiple simulators for a computing cluster, and the multiple simulators for a computing cluster are two or more simulators, and the multiple simulators for a computing cluster include: multiple simulators for simulating the functions and performance of a computing cluster. Schematically, as Figure 1 As shown, the computing cluster simulation system 100 includes simulator 1, simulator 2, ... simulator n, where n is a positive integer.

[0062] Multiple simulators in a computing cluster can be different simulators in the same simulation instance. Different simulators in the same simulation instance of multiple simulators in a computing cluster means that in one simulation instance, in order to achieve a more comprehensive and accurate simulation, multiple different simulators may be used to perform simulation work. This can make full use of the advantages of different simulators and improve the accuracy and efficiency of simulation.

[0063] The simulator can be functionally divided into a computing simulator or a communication simulator. That is, the multiple simulators in the computing cluster can include at least one computing simulator and at least one communication simulator. The computing simulator is used to simulate the computing content of the computing node, and the communication simulator is used to simulate the processing content of the communication node.

[0064] In a possible implementation, the functions of the computing cluster simulation system can be divided into two parts: distributed computing simulation and cluster communication simulation, and both parts are simulated with synchronization cycles as basic units.

[0065] Among them, distributed computing simulation: can be simulated by a single or multiple computing simulators, depending on the complexity of the simulation and the required computing resources. The simulation content of the computing simulator is the computing content of the computing node, which may include the execution of various computing tasks and algorithms. For example, when the processor type used by the computing node is the central processing unit (CPU), the computing node is a CPU computing node; when the processor type used by the computing node is a graphics processing unit (GPU), the computing node is a GPU computing node. Distributed computing simulation is carried out step by step according to the synchronization cycle, which means that the computing simulator will update and synchronize the status at the end of each synchronization cycle. Whenever the computing simulator completes a synchronization cycle of simulation, it will enter the data synchronization process to ensure that the status of all simulators (computing simulators and communication simulators) remains consistent.

[0066] Cluster communication simulation: Similar to distributed computing simulation, cluster communication simulation can also be performed by one or more communication simulators. The simulation content of the communication simulator is the processing content of the communication node, including data transmission, implementation of communication protocols, etc. Cluster communication simulation is also carried out according to the synchronization cycle to ensure the synchronization of communication activities. Whenever the communication simulator completes a synchronization cycle of simulation, it will also enter the data synchronization process to ensure the correct order and timing of communication activities.

[0067] Below, an exemplary embodiment is used to introduce the computing cluster joint simulator synchronization processing method provided by the embodiment of the present disclosure.

[0068] Please refer to Figure 2 , which shows a flowchart of a computing cluster joint simulator synchronization processing method provided by an exemplary embodiment of the present disclosure, and this embodiment is illustrated by using the method in a computing cluster simulation system. The method includes the following steps.

[0069] Step 201 : multiple simulators in a computing cluster obtain a synchronization period, where the synchronization period is used to unify the simulation time of multiple simulators in the computing cluster on a time scale.

[0070] Multiple simulators in a computing cluster can be different simulators in the same simulation instance. Each simulator can set its own internal simulation granularity and clock cycle according to its own simulation requirements, and set a global synchronization cycle suitable for multiple simulators in the computing cluster. The synchronization cycle is used to unify the simulation time of multiple simulators in the computing cluster on a time scale and serve as a benchmark for synchronization of each simulator. In other words, the synchronization cycle is the simulation time interval for exchanging synchronization data between multiple simulators in the computing cluster. The simulation time interval is not the time interval for the actual operation of the simulator, but the time interval for the simulator to simulate. After each simulator executes a simulation synchronization cycle, it synchronizes data with other simulators that are simulated together in the simulation instance.

[0071] The synchronization period can be set by default or can be set by user. In principle, a global synchronization period can be set according to the simulation requirements of the simulation instance. In principle, the synchronization period is a common multiple of the clock period inside all simulators to ensure that all simulators can exchange data and update status at a certain point in the synchronization period.

[0072] Optionally, each simulator sets its own internal simulation granularity according to its own simulation requirements. The simulation granularity of the simulator is used to indicate the calculation accuracy of the simulator when performing simulation. For example, if the simulation granularity of the simulator is 1 microsecond, it means that the calculation accuracy of the simulator when performing simulation is one simulation step per microsecond, and the corresponding clock frequency is 1MHz. The finer the simulation granularity, the more accurate the simulation result, but the simulation time will also increase accordingly.

[0073] Optionally, under the premise of ensuring the correctness of the internal logic of the simulator, the clock cycle setting of each simulator can be adjusted so that it can complete the required simulation tasks within the global synchronization cycle. The clock cycle of the simulator is the physical time interval of the simulation calculation of the simulator, that is, the time interval for each simulation calculation to be triggered. Among them, there are at least two clock cycles in the clock cycles of multiple simulators in the computing cluster that are different, or the clock cycles of multiple simulators in the computing cluster are different. In other words, multiple simulators in the computing cluster are synchronized in synchronous data exchange, and are asynchronous in the execution of their own internal simulation tasks.

[0074] The multiple simulators in the computing cluster obtain the set synchronization period. The synchronization period can be obtained by a special interaction protocol or by interaction between simulators (such as indicated by the transmission of data messages between simulators). In addition, the multiple simulators in the computing cluster also obtain the set global start time and global end time. The global start time is the start time of the synchronization process of the multiple simulators in the computing cluster, and the global end time is the end time of the synchronization process of the multiple simulators in the computing cluster. The way to obtain the global start time and the global end time can be analogous to the way to obtain the reference synchronization period.

[0075] Optionally, multiple simulators in a computing cluster within the same simulation instance exchange their respective synchronization data using the same interaction protocol, and multiple simulators in the computing cluster obtain the same interaction protocol, which is used to indicate the synchronization period of multiple simulators in the computing cluster, and the interaction protocol is also used to indicate the synchronization start time, synchronization end time and synchronization period. It should be noted that the acquisition method depends on the design and technical requirements of the computing cluster simulation system, and the embodiments of the present disclosure do not limit this.

[0076] Step 202: In each synchronization period, multiple simulators in the computing cluster independently execute their respective simulation tasks.

[0077] Based on the set synchronization cycle, in each synchronization cycle, each simulator independently runs the simulation, including but not limited to the initialization of the simulation task, the execution of the simulation task and the acquisition of the simulation results. According to the object to be simulated, the corresponding model is loaded for each simulator. In each synchronization cycle, each simulator independently executes its own simulation task according to the initialized model and parameters according to its own clock cycle. That is, for each simulator, the simulator advances the simulation time according to the set clock cycle, and the internal state of the simulator will change accordingly in each clock cycle. During this period, the simulator will update its own simulation state according to the dynamic changes. At the end of each synchronization cycle, the simulator obtains the synchronization data to be synchronized, and the synchronization data may include the current simulation state and simulation timestamp, and prepare for the next step of synchronization data exchange. Among them, the simulation state is used to indicate the situation of the simulator when it imitates the target system running, including the simulated processor state, memory content and interaction state with external hardware. The simulation timestamp includes the simulation time when each event occurs during the simulation process. The synchronization data may also include control information, which usually refers to data and instructions used to guide or change the operation behavior of the simulator, such as control information including operation instructions such as starting or stopping simulation, single-step execution, and setting breakpoints. The synchronization data may also include other data determined by synchronization requirements in the simulation instance, which is not limited in the embodiments of the present disclosure.

[0078] Step 203: At the end of each synchronization cycle, the multiple simulators in the computing cluster exchange their respective synchronization data, and the synchronization data is used to indicate the execution status of the simulation task.

[0079] At the end of each synchronization cycle, each simulator packages the information to be shared to obtain synchronization data and sends its own synchronization data through an appropriate communication protocol. This may involve point-to-point transmission or broadcast data distribution between multiple simulators in a computing cluster. In other words, the above exchange includes sending and may or may not include receiving. Unlike sending, receiving is a passive process. As long as the data arrives at the input port of the simulator, no matter when and where, the simulator will automatically process the received data according to its design. The receiving action is not limited by the synchronization cycle and can occur at any time.

[0080] After receiving the synchronization data of other simulators, each simulator caches the synchronization data of other simulators (for example, stores the synchronization data of other simulators in a local synchronization data buffer) and continues to execute subsequent simulation steps. The other simulators corresponding to each simulator can be all simulators other than the simulator in the simulation instance, or can be at least one simulator other than the simulator in the simulation instance. The embodiments of the present disclosure are not limited to this.

[0081] Optionally, at the end of each synchronization cycle, each simulator pauses its own system runtime and starts to execute the data synchronization step, that is, sends its own synchronization data to other simulators and receives synchronization data sent by other simulators. After receiving all synchronization data sent by other simulators, cache the synchronization data of other simulators, resume starting its own system runtime, and continue to execute subsequent simulation steps. The system runtime is the internal time progress of the target system simulated by the simulator when simulating the target system runtime.

[0082] Among them, an emulator can determine whether it has received all the synchronization data sent by other emulators through a variety of methods. For example, the interactive protocol is used to indicate the total number of packets of synchronization data to be received by each emulator. Each emulator determines the total number of packets of synchronization data that it needs to receive based on the interactive protocol, and a counter can be set to track the number of packets received. Whenever a data packet is received, the counter increases until the value of the counter is equal to the expected total number of packets, at which time it can be determined that all synchronization data has been received. For another example, a timer is set. If no new data packets are received within a predetermined time, it can be considered that all synchronization data have been received. The embodiments of the present disclosure are not limited to this.

[0083] In the data transmission process, each simulator can communicate with other simulators through but not limited to socket communication, shared memory, pipes, etc. to exchange synchronization data. The synchronization data may include the current simulation state, simulation timestamp, control information and other data determined by the synchronization requirements in the simulation instance.

[0084] Optionally, when multiple simulators in a computing cluster exchange their own synchronization data, the synchronization data between multiple simulators in the computing cluster in the same simulation instance use the same interaction protocol. The interaction protocol can be formulated in a form similar to an event according to the simulation requirements of the simulation instance. The interaction protocol may change in different simulation instances due to simulation requirements.

[0085] In an illustrative example, an exemplary version of the interaction protocol between multiple simulators in a computing cluster is shown in Table 1.

[0086] Table 1

[0087] event_type Event Type Dest Purpose Information Source Source Information arrive_time Arrival time data_id Data No. datalen Data length Reserve Reserved bits

[0088] The above interaction protocol, i.e. the information content in the "event", can formulate a framework for an interaction protocol in conjunction with the interaction mechanism described above. "Event" is a fixed-length field, and which bits are valid is determined by the event type. Each event type corresponds to some detailed information in the "event", i.e. its valid bits. In order to have new valid bits available when new event types are added later, some reserved bits are reserved. All required event types can be defined in advance, and the field length of "event" can be determined so that the fields in the reserved bits are not modified as much as possible during subsequent updates and upgrades.

[0089] The following examples illustrate several event types and their usage, which are not limited in the embodiments of the present disclosure.

[0090] 1. Pure data type: No real data is transmitted between simulators, only the description information of the data segment is transmitted through the "event" of pure data type. At this time, the valid fields that may be concerned in the "event" are the destination information "Dest", source information "Source", arrival time "arrive_time", data number "data_id", and data length "datalen".

[0091] 2. Back pressure type: The valid field of this event type is the back pressure information "BP_info". The real-time back pressure information of the local simulator is recorded according to the data flow and fed back to the peer simulator. The back pressure information can be used to adjust the speed of data flow or signal flow to prevent data backlog or buffer overflow. The back pressure type is only a representative of multiple control information types, and other types can be added according to actual needs.

[0092] 3. Tail packet type: This event type has no valid fields except the event type itself, and its purpose is to cooperate with the interaction mechanism mentioned above. Each time multiple simulators in a computing cluster exchange their own synchronization data, each simulator sends the synchronization data in the form of events of various event types. Here, it is necessary to ensure that the event type of the last event sent is the tail packet type; then each simulator receives the events sent by other simulators. When the tail packet type event is received, it can be confirmed that all events (that is, all synchronization data corresponding to this synchronization cycle) have been received, and the simulation operation of the next synchronization cycle can continue. The tail packet type and its related mechanisms here are only representative of multiple interactive handshake types. If there are more complex interactive handshake requirements, additions and modifications can be made.

[0093] Optionally, for each simulator, after storing the synchronization data of other simulators in the local synchronization data buffer, at the beginning of each subsequent synchronization cycle, the synchronization data corresponding to the previous synchronization cycle in the local synchronization data buffer is obtained, and the simulation task of the current synchronization cycle is executed according to the synchronization data corresponding to the previous synchronization cycle. Each subsequent synchronization cycle is each other synchronization cycle, that is, each synchronization cycle other than the first synchronization cycle. The synchronization data corresponding to the previous synchronization cycle is the synchronization data of other simulators received after the end of the previous synchronization cycle.

[0094] Optionally, in this synchronization cycle, each simulator can adjust its own simulation state according to the simulation state and simulation timestamp in the synchronization data corresponding to the previous synchronization cycle to achieve synchronization with other simulators. And according to the synchronization cycle in the interaction protocol, confirm whether this synchronization cycle has ended. If this synchronization cycle has ended, in the next synchronization cycle, the simulation of the next synchronization cycle can be run according to the synchronization data received in this synchronization cycle. And so on, until the synchronization processing of multiple simulators in the computing cluster is completed.

[0095] Please refer to Figure 3 , which shows a flowchart of a method for synchronizing a computing cluster and a simulator provided by another exemplary embodiment of the present disclosure, and this embodiment is illustrated by using the method in a computing cluster simulation system. The method includes the following steps.

[0096] Step 301 : multiple simulators in a computing cluster obtain a synchronization period, where the synchronization period is used to unify the simulation time of multiple simulators in the computing cluster on a time scale.

[0097] Optionally, the multiple simulators of the computing cluster include at least one computing simulator and at least one communication simulator, the computing simulator is used to simulate the computing content of the computing node, and the communication simulator is used to simulate the processing content of the communication node.

[0098] Step 302: In each synchronization cycle, multiple simulators in the computing cluster independently execute their respective simulation tasks according to their respective clock cycles.

[0099] Among the clock cycles of the multiple simulators in the computing cluster, at least two clock cycles are different, or the clock cycles of the multiple simulators in the computing cluster are all different.

[0100] Step 303: At the end of each synchronization cycle, each simulator sends its own synchronization data to other simulators.

[0101] Optionally, the synchronization data includes a simulation state and a simulation timestamp corresponding to the simulation task.

[0102] Optionally, the multiple simulators in the computing cluster are different simulators in the same simulation instance, and the multiple simulators in the computing cluster exchange their respective synchronization data using the same interaction protocol. The interaction protocol is used to indicate the global start time, global end time and synchronization period of the multiple simulators in the computing cluster.

[0103] Step 304: After receiving the synchronization data from other simulators, each simulator stores the synchronization data from other simulators in a local synchronization data buffer.

[0104] Optionally, at the beginning of each other synchronization cycle, each simulator obtains the synchronization data corresponding to the previous synchronization cycle in the local synchronization data buffer. Each other synchronization cycle is every synchronization cycle except the first synchronization cycle. In each other synchronization cycle, each simulator executes the simulation task of the current synchronization cycle according to the synchronization data corresponding to the previous synchronization cycle.

[0105] It should be noted that the relevant details of each step in this embodiment can be referred to the relevant description in the above embodiment, and will not be repeated here.

[0106] In an illustrative example, the interaction between two simulators (simulator A and simulator B) is used as an example for explanation. The simulation granularity of simulator A is T1, and the simulation granularity of simulator B is T2. The interaction process between the two is as follows: Figure 4As shown. Step 1, simulator A starts simulation at the global start time 0, and simulates the calculation, processing, control and other behaviors of system A within one synchronization cycle (0-Kclock). Simultaneously, simulator B starts simulation at the global start time 0, and simulates the calculation, processing, control and other behaviors of system B within one synchronization cycle (0-Kclock). Wherein, clock represents the clock cycle of simulator B, Kclock represents K clock cycles of simulator B, and K is a positive integer. Step 2, simulator A suspends the system running time of simulator A at time T1, starts to execute event synchronization behavior, sends all the synchronization data of simulator A generated in step 1 (various data to be synchronized that need to be output to simulator B) to simulator B in the form of events, and then receives the events sent by simulator B; simulator B and simulator A have symmetrical behaviors, suspend the system running time of simulator B at time Kclock, start to execute event synchronization behavior, send all the synchronization data of simulator B generated in step 1 (various data to be synchronized that need to be output to simulator A) to simulator A in the form of events, and then receives the events sent by simulator A. And so on, no longer listed one by one, until the global end time in the interactive protocol, the synchronization processing of multiple simulators in the computing cluster is ended. The embodiments of the present disclosure do not limit the values ​​of T1, T2, and K.

[0107] Based on the above example, in another illustrative example, only taking T1 as 1 μs (ie, the clock frequency is 1 MHz) and T2 as 10 ns (ie, the clock frequency is 100 MHz) as an example, the interaction process between the two is further introduced. Figure 5 As shown. The synchronization period of simulator A and simulator B is 1μs system running time, that is, 1μs system running time is 1 clock cycle of simulator A, and 1μs system running time is 100 clock cycles of simulator B. In simulator A and simulator B, the two behaviors of "simulation running" and "event synchronization" are executed alternately, and the steps are as follows:

[0108] Step 1: Simulator A starts simulation at the global start time 0μs, and simulates the calculation, processing, and control behaviors of system A within one synchronization cycle (0-100clock). Simulator B starts simulation at the global start time 0μs, and simulates the calculation, processing, and control behaviors of system B within one synchronization cycle (0-100clock). Where clock represents the clock cycle of simulator B.

[0109] Step 2, simulator A pauses the system running time of simulator A at 1μs, starts to execute event synchronization behavior, sends all the synchronization data of simulator A generated in step 1 (various data to be synchronized that need to be output to simulator B) to simulator B in the form of events, and then receives the events sent by simulator B; simulator B has symmetrical behavior with simulator A, pauses the system running time of simulator B at 100clock, starts to execute event synchronization behavior, sends all the synchronization data of simulator B generated in step 1 (various data to be synchronized that need to be output to simulator A) to simulator A in the form of events, and then receives the events sent by simulator A.

[0110] Step 3, after receiving all the events sent by simulator B, simulator A resumes the system running time of simulator A, continues its own simulation operation, and simulates the calculation, processing, control and other behaviors of system A within one synchronization cycle (100-200clock); simulator B has a symmetrical behavior with simulator A. After simulator B receives all the events sent by simulator A, it resumes the system running time of simulator B, continues its own simulation operation, and simulates the calculation, processing, control and other behaviors of system B within one synchronization cycle (100-200clock).

[0111] Step 4: Simulator A pauses the system running time of simulator A at 2μs, starts to execute event synchronization behavior, sends all the synchronization data of simulator A generated in step 3 (various data to be synchronized that need to be output to simulator B) to simulator B in the form of events, and then receives the events sent by simulator B; Simulator B and simulator A have symmetrical behaviors, pause the system running time of simulator B at 200clock, start to execute event synchronization behavior, send all the synchronization data of simulator B generated in step 3 (various data to be synchronized that need to be output to simulator A) to simulator A in the form of events, and then receive the events sent by simulator A. And so on, no longer listed one by one, until the global end time in the interaction protocol, the synchronization processing of multiple simulators in the computing cluster ends.

[0112] In summary, the disclosed embodiment provides a method for synchronous processing of a computing cluster joint simulator, which ensures that the multiple simulators in the computing cluster are synchronized in synchronous data exchange and asynchronous in internal respective simulation task execution by setting respective clock cycles of multiple simulators in the computing cluster, solves the synchronization problem existing in the simulation of the computing cluster simulation system in the related technology, improves the accuracy and efficiency of the simulation, and the combination of the synchronization of the multiple simulators in synchronous data exchange and the asynchrony in internal simulation task execution of the multiple simulators in the computing cluster brings many beneficial effects such as high efficiency, strong compatibility, stability, support for complex systems, development of distributed collaborative simulation and time synchronization to the simulation field. In addition, the multiple simulators in the computing cluster may include at least one computing simulator and at least one communication simulator, so that the functions of the computing cluster simulation system can be divided into two major parts: distributed computing simulation and cluster communication simulation, and both are simulated with the synchronization cycle as the basic unit, so that the simulation is more detailed and comprehensive, which helps to shorten the development cycle.

[0113] The following is an apparatus embodiment of the present disclosure. For parts not described in detail in the apparatus embodiment, reference may be made to the technical details disclosed in the above method embodiment.

[0114] Please refer to Figure 6 , which shows a schematic diagram of the structure of a computing cluster joint simulator synchronization processing device provided by an exemplary embodiment of the present disclosure. The computing cluster joint simulator synchronization processing device can be implemented as all or part of the simulator through software, hardware, or a combination of the two. The device includes: a synchronization cycle acquisition module 610, a simulation task execution module 620, and a synchronization data exchange module 630.

[0115] A synchronization period acquisition module 610 is used to acquire a synchronization period, and the synchronization period is used to unify the simulation time of multiple simulators in the computing cluster on a time scale;

[0116] The simulation task execution module 620 is used to independently execute the simulation task of the simulator itself in each synchronization cycle;

[0117] The synchronization data exchange module 630 is used to exchange respective synchronization data with other simulators at the end of each synchronization cycle, and the synchronization data is used to indicate the execution status of the simulation task.

[0118] In a possible implementation, the simulation task execution module 620 is further configured to independently execute its own simulation task according to the simulator's own clock cycle in each synchronization cycle;

[0119] Among the clock cycles of the multiple simulators in the computing cluster, at least two clock cycles are different, or the clock cycles of the multiple simulators in the computing cluster are all different.

[0120] In another possible implementation, the multiple simulators of the computing cluster include at least one computing simulator and at least one communication simulator. The computing simulator is used to simulate the computing content of the computing node, and the communication simulator is used to simulate the processing content of the communication node.

[0121] In another possible implementation, the synchronization data exchange module 630 is further configured to send the synchronization data of the simulator itself to other simulators at the end of each synchronization cycle;

[0122] The device also includes: a storage module, which is used to store the synchronization data of other simulators in a local synchronization data buffer after receiving the synchronization data of other simulators.

[0123] In another possible implementation, the simulation task execution module 620 is further used to obtain the synchronization data corresponding to the previous synchronization cycle in the local synchronization data buffer at the beginning of each other synchronization cycle, and each other synchronization cycle is each synchronization cycle other than the first synchronization cycle;

[0124] In each other synchronization cycle, the simulation task of the current synchronization cycle is executed according to the synchronization data corresponding to the previous synchronization cycle.

[0125] In another possible implementation, the synchronization data includes a simulation state and a simulation timestamp corresponding to the simulation task.

[0126] In another possible implementation, the multiple simulators in the computing cluster are different simulators in the same simulation instance, and the multiple simulators in the computing cluster exchange their respective synchronization data using the same interaction protocol.

[0127] In another possible implementation, the interaction protocol is used to indicate the global start time, global end time and synchronization period of multiple simulators in the computing cluster.

[0128] It should be noted that the device provided in the above embodiment only uses the division of the above-mentioned functional modules as an example to implement its functions. In practical applications, the above-mentioned functions can be assigned to different functional modules according to actual needs, that is, the content structure of the device can be divided into different functional modules to complete all or part of the functions described above.

[0129] Regarding the device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.

[0130] The embodiment of the present disclosure further provides a computing cluster simulation system, the system comprising a computing cluster multiple simulators, the computing cluster multiple simulators are used to:

[0131] Get the synchronization period, which is used to unify the simulation time of multiple simulators in the computing cluster on a time scale;

[0132] In each synchronization cycle, each simulation task is executed independently;

[0133] At the end of each synchronization cycle, multiple simulators in the computing cluster exchange their own synchronization data, which is used to indicate the execution status of the simulation task.

[0134] In a possible implementation, a computing cluster includes multiple simulators and is further configured to:

[0135] In each synchronization cycle, each simulation task is executed independently according to its own clock cycle;

[0136] Among the clock cycles of the multiple simulators in the computing cluster, at least two clock cycles are different, or the clock cycles of the multiple simulators in the computing cluster are all different.

[0137] In another possible implementation, the multiple simulators of the computing cluster include at least one computing simulator and at least one communication simulator. The computing simulator is used to simulate the computing content of the computing node, and the communication simulator is used to simulate the processing content of the communication node.

[0138] In another possible implementation, each simulator is further configured to:

[0139] At the end of each synchronization cycle, it sends its own synchronization data to other simulators;

[0140] After receiving the synchronization data of other simulators, the synchronization data of other simulators are stored in the local synchronization data buffer.

[0141] In another possible implementation, each simulator is further configured to:

[0142] At the beginning of each other synchronization cycle, the synchronization data corresponding to the previous synchronization cycle in the local synchronization data buffer is obtained, and each other synchronization cycle is each synchronization cycle other than the first synchronization cycle;

[0143] In each other synchronization cycle, the simulation task of the current synchronization cycle is executed according to the synchronization data corresponding to the previous synchronization cycle.

[0144] In another possible implementation, the synchronization data includes a simulation state and a simulation timestamp corresponding to the simulation task.

[0145] In another possible implementation, the multiple simulators in the computing cluster are different simulators in the same simulation instance, and the multiple simulators in the computing cluster exchange their respective synchronization data using the same interaction protocol.

[0146] In another possible implementation, the interaction protocol is used to indicate the global start time, global end time and synchronization period of multiple simulators in the computing cluster.

[0147] Regarding the system in the above embodiment, the specific manner in which each simulator performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.

[0148] The embodiment of the present disclosure also provides a computing device, which may be a terminal or a server. The computing device includes: a processor; a memory for storing instructions executable by the processor; wherein the processor is configured to implement the above method when executing the instructions stored in the memory.

[0149] The embodiment of the present disclosure also provides a non-volatile computer-readable storage medium on which computer program instructions are stored. When the computer program instructions are executed by a processor, the above method is implemented.

[0150] The embodiments of the present disclosure also provide a computer program product, including a computer-readable code, or a non-volatile computer-readable storage medium carrying the computer-readable code. When the computer-readable code runs in a processor of a computing device, the processor in the computing device executes the above method.

[0151] The present disclosure may be a system, a method and / or a computer program product. The computer program product may include a computer-readable storage medium carrying computer-readable program instructions for causing a processor to implement various aspects of the present disclosure.

[0152] A computer-readable storage medium may be a tangible device that can hold and store instructions used by an instruction execution device. A computer-readable storage medium may be, for example, but not limited to, an electrical storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination of the foregoing. More specific examples of computer-readable storage media (a non-exhaustive list) include: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a static random access memory (SRAM), a portable compact disk read-only memory (CD-ROM), a digital versatile disk (DVD), a memory stick, a floppy disk, a mechanical encoding device, such as a punch card or a raised structure in a groove on which instructions are stored, and any suitable combination of the foregoing. As used herein, a computer-readable storage medium is not to be interpreted as a transient signal per se, such as a radio wave or other freely propagating electromagnetic wave, an electromagnetic wave propagating through a waveguide or other transmission medium (e.g., a light pulse through a fiber optic cable), or an electrical signal transmitted through a wire.

[0153] The computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to each computing / processing device, or downloaded to an external computer or external storage device via a network, such as the Internet, a local area network, a wide area network, and / or a wireless network. The network can include copper transmission cables, optical fiber transmissions, wireless transmissions, routers, firewalls, switches, gateway computers, and / or edge servers. The network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards the computer-readable program instructions for storage in the computer-readable storage medium in each computing / processing device.

[0154] The computer program instructions for performing the operation of the present disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-related instructions, microcode, firmware instructions, state setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages, such as Smalltalk, C++, etc., and conventional procedural programming languages, such as "C" language or similar programming languages. Computer-readable program instructions may be executed completely on a user's computer, partially on a user's computer, as an independent software package, partially on a user's computer, partially on a remote computer, or completely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., using an Internet service provider to connect via the Internet). In some embodiments, an electronic circuit, such as a programmable logic circuit, a field programmable gate array (FPGA), or a programmable logic array (PLA), may be customized by utilizing the state information of the computer-readable program instructions, and the electronic circuit may execute the computer-readable program instructions, thereby realizing various aspects of the present disclosure.

[0155] Various aspects of the present disclosure are described herein with reference to the flowcharts and / or block diagrams of the methods, devices (systems) and computer program products according to the embodiments of the present disclosure. It should be understood that each box in the flowchart and / or block diagram and the combination of each box in the flowchart and / or block diagram can be implemented by computer-readable program instructions.

[0156] These computer-readable program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, thereby producing a machine, so that when these instructions are executed by the processor of the computer or other programmable data processing device, a device that implements the functions / actions specified in one or more boxes in the flowchart and / or block diagram is generated. These computer-readable program instructions can also be stored in a computer-readable storage medium, and these instructions cause the computer, programmable data processing device, and / or other equipment to work in a specific manner, so that the computer-readable medium storing the instructions includes a manufactured product, which includes instructions for implementing various aspects of the functions / actions specified in one or more boxes in the flowchart and / or block diagram.

[0157] Computer-readable program instructions may also be loaded onto a computer, other programmable data processing apparatus, or other device so that a series of operating steps are performed on the computer, other programmable data processing apparatus, or other device to produce a computer-implemented process, thereby causing the instructions executed on the computer, other programmable data processing apparatus, or other device to implement the functions / actions specified in one or more boxes in the flowchart and / or block diagram.

[0158] The flow chart and block diagram in the accompanying drawings show the possible architecture, function and operation of the system, method and computer program product according to multiple embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a part of a module, program segment or instruction, and a part of the module, program segment or instruction includes one or more executable instructions for realizing the specified logical function. In some alternative implementations, the function marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two continuous square boxes can actually be executed substantially in parallel, and they can sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs the specified function or action, or can be implemented with a combination of special hardware and computer instructions.

[0159] The embodiments of the present disclosure have been described above, and the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Many modifications and changes will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The selection of terms used herein is intended to best explain the principles of the embodiments, practical applications, or technical improvements in the market, or to enable other persons of ordinary skill in the art to understand the embodiments disclosed herein.

Claims

1. A method for synchronous processing of a computing cluster and a joint simulator, characterized in that: The method comprises: The multiple simulators in the computing cluster obtain a synchronization period, and the synchronization period is used to unify the simulation time of the multiple simulators in the computing cluster on a time scale. The synchronization period is a simulation time interval for exchanging synchronization data between the multiple simulators in the computing cluster. The simulation time interval is not a time interval for the actual operation of the simulator, but a time interval for the simulation of the simulator. In each synchronization period, the multiple simulators in the computing cluster independently execute respective simulation tasks; At the end of each synchronization cycle, the plurality of simulators in the computing cluster exchange respective synchronization data, wherein the synchronization data is used to indicate the execution status of the simulation task, and the synchronization data includes the current simulation state and simulation timestamp, wherein the simulation state includes the simulated processor state, memory content and interaction state with external hardware, and the simulation timestamp includes the simulation time when each event occurs during the simulation process; In each synchronization period, the multiple simulators in the computing cluster independently perform their respective simulation tasks, including: In each synchronization cycle, the multiple simulators in the computing cluster independently execute their respective simulation tasks according to their respective clock cycles; Among the clock cycles of the multiple simulators in the computing cluster, at least two clock cycles are different, or the clock cycles of the multiple simulators in the computing cluster are different, the clock cycle of each simulator is adjustable, and the synchronization cycle is a common multiple of the clock cycles inside all the simulators.

2. The method according to claim 1, characterized in that: The multiple simulators of the computing cluster include at least one computing simulator and at least one communication simulator. The computing simulator is used to simulate the computing content of the computing node, and the communication simulator is used to simulate the processing content of the communication node.

3. The method according to claim 1, characterized in that At the end of each synchronization cycle, the plurality of simulators in the computing cluster exchange respective synchronization data, including: At the end of each synchronization cycle, each simulator sends its own synchronization data to other simulators; The method further comprises: After receiving the synchronization data from other simulators, each simulator stores the synchronization data from other simulators in a local synchronization data buffer.

4. The method according to claim 3, characterized in that The method further comprises: At the beginning of each of the other synchronization cycles, each of the simulators obtains the synchronization data corresponding to the previous synchronization cycle in the local synchronization data buffer, and each of the other synchronization cycles is each of the other synchronization cycles except the first synchronization cycle; In each of the other synchronization cycles, each simulator performs the simulation task of the current synchronization cycle according to the synchronization data corresponding to the previous synchronization cycle.

5. The method according to any one of claims 1 to 4, characterized in that: The synchronization data includes a simulation state and a simulation timestamp corresponding to the simulation task.

6. The method according to any one of claims 1 to 4, characterized in that The multiple simulators in the computing cluster are different simulators in the same simulation instance, and the multiple simulators in the computing cluster exchange their respective synchronization data using the same interaction protocol.

7. The method according to claim 6, characterized in that The interaction protocol is used to indicate the global start time, the global end time and the synchronization period of the multiple simulators in the computing cluster.

8. A computing cluster joint simulator synchronization processing device, characterized in that: The device comprises: A synchronization cycle acquisition module is used to acquire a synchronization cycle, wherein the synchronization cycle is used to unify the simulation time of multiple simulators in the computing cluster on a time scale. The synchronization cycle is a simulation time interval for exchanging synchronization data between multiple simulators in the computing cluster. The simulation time interval is not a time interval for the actual operation of the simulator, but a time interval for the simulation of the simulator. A simulation task execution module, used for independently executing the simulation task of the simulator itself in each synchronization cycle; A synchronization data exchange module, used for exchanging respective synchronization data with other simulators at the end of each synchronization cycle, wherein the synchronization data is used to indicate the execution status of the simulation task, and the synchronization data includes a current simulation state and a simulation timestamp, wherein the simulation state includes a simulated processor state, memory content, and an interaction state with external hardware, and the simulation timestamp includes a simulation time when each event occurs during the simulation process; The simulation task execution module is also used for: In each synchronization cycle, the multiple simulators in the computing cluster independently execute their respective simulation tasks according to their respective clock cycles; Among the clock cycles of the multiple simulators in the computing cluster, at least two clock cycles are different, or the clock cycles of the multiple simulators in the computing cluster are different, the clock cycle of each simulator is adjustable, and the synchronization cycle is a common multiple of the clock cycles inside all the simulators.

9. A computing cluster simulation system, characterized in that: The system comprises a computing cluster and a plurality of simulators, and the system is used to implement the method according to any one of claims 1 to 7.