Virtual machine configuration method and device based on c86 architecture

By constructing the hardware resource topology and kernel cluster distribution information under the C86 architecture, an optimization strategy is formed, which solves the problems of insufficient virtual machine resource isolation and high scheduling overhead, and improves the performance and resource utilization of virtual machines.

CN120872491BActive Publication Date: 2026-06-23HAIGUANG INTEGRATED CIRCUIT DESIGN (BEIJING) CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
HAIGUANG INTEGRATED CIRCUIT DESIGN (BEIJING) CO LTD
Filing Date
2025-07-09
Publication Date
2026-06-23

AI Technical Summary

Technical Problem

In the existing technology, the virtual machine configuration for the C86 architecture does not fully take into account the non-uniform memory access architecture of the central processing unit and the characteristics of multi-core chip modules, resulting in insufficient resource isolation and high scheduling overhead, which affects the performance optimization of virtual machines.

Method used

By generating the first kernel cluster distribution information, constructing the hardware resource topology using the host system information, determining the topological correspondence of hardware resources at different levels, forming optimization strategies to configure virtual machines, achieving resource isolation and flexible configuration, and reducing scheduling overhead.

Benefits of technology

It effectively reduces the scheduling overhead of virtual machines, improves resource utilization and virtual machine performance, and optimizes virtual machine resource configuration.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120872491B_ABST
    Figure CN120872491B_ABST
Patent Text Reader

Abstract

The present specification relates to the technical field of virtual machines, and provides a virtual machine configuration method and device based on C86 architecture. The method comprises: generating first kernel cluster distribution information according to system information of a host computer; forming an optimization strategy according to the first kernel cluster distribution information and a preset quantization strategy; and obtaining virtual machine configuration information by using the optimization strategy. By the embodiment of the present specification, the scheduling overhead of the virtual machine can be reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This specification relates to the field of virtual machine technology, and in particular to virtual machine configuration methods and apparatus based on the C86 architecture. Background Technology

[0002] With the rapid development of information technology, virtualization technology has gradually become an indispensable component of modern computer systems. Virtualization technology allows multiple virtual machines to run on a single physical hardware, thereby significantly improving the utilization of hardware resources while enhancing the flexibility and manageability of computing.

[0003] In virtualization technology, optimizing the central processing unit (CPU) architecture is crucial. CPUs typically employ non-uniform memory access architectures and multi-core chip modules. How to more rationally and efficiently utilize these hardware characteristics to improve virtualization performance is a key point in the practical application of virtualization technology. However, in existing technologies, virtual machine configurations for the C86 architecture often do not deeply consider these hardware characteristics, resulting in insufficient resource isolation and high scheduling overhead. This leads to significant challenges in virtual machine performance optimization. Therefore, a virtual machine configuration method is urgently needed to achieve resource isolation and flexible resource allocation, thereby reducing virtual machine scheduling overhead. Summary of the Invention

[0004] Given that CPU architecture optimization is crucial in virtualization technology, and CPUs typically employ non-uniform memory access architectures and multi-core chip modules, how to more rationally and efficiently utilize these hardware characteristics to improve virtualization performance has become a key point in the practical application of virtualization technology. However, current virtual machine configurations for the C86 architecture often do not deeply consider these hardware characteristics, resulting in insufficient resource isolation and high scheduling overhead. This leads to numerous challenges in virtual machine performance optimization. This specification provides a virtual machine configuration method and apparatus based on the C86 architecture to overcome or at least partially solve the aforementioned problems.

[0005] On the one hand, the purpose of some embodiments of this specification is to provide a virtual machine configuration method based on the C86 architecture, the method including:

[0006] Generate the first kernel cluster distribution information based on the host machine's system information;

[0007] An optimization strategy is formed based on the distribution information of the first kernel cluster and the preset quantization strategy;

[0008] The virtual machine configuration information is obtained using the optimization strategy described above.

[0009] Furthermore, before generating the first kernel cluster distribution information based on the host machine's system information, the process further includes:

[0010] By obtaining dynamic operational information of the host machine, the system information of the host machine can be obtained.

[0011] Furthermore, based on the host machine's system information, the first kernel cluster distribution information is generated, including:

[0012] The topology of hardware resources is constructed based on the system information of the host machine;

[0013] The first kernel cluster distribution information is generated based on the topology of the hardware resources.

[0014] Furthermore, constructing the hardware resource topology based on the host machine's system information includes:

[0015] The first mapping relationship between the slot and the non-consistent memory access node and the second mapping relationship between the non-consistent memory access node and the L3 cache are determined based on the system information of the host machine.

[0016] The topology of hardware resources at each level is determined using the system information of the host machine;

[0017] Based on the aforementioned topology, the correspondence between the topologies of hardware resources at different levels is determined using the first and second mapping relationships.

[0018] Furthermore, based on the aforementioned topology, determining the correspondence of hardware resource topologies between different levels using the first and second mapping relationships further includes:

[0019] Based on the first mapping relationship, an inconsistent memory access topology corresponding to the slot topology in the topology structure is constructed using the inconsistent memory access node information.

[0020] Based on the second mapping relationship, a three-level cache topology corresponding to the non-consistent memory access topology is constructed using the three-level cache information.

[0021] Furthermore, it further includes:

[0022] The topology of the hardware resources is deduplicated based on the first and second mapping relationships.

[0023] Further, based on the topology of the hardware resources, first kernel cluster distribution information is generated, including:

[0024] Based on the topology analysis of the hardware resources, the allocation strategy of the L3 cache and the mapping relationship between the L3 cache and the kernel cluster are analyzed to construct the distribution function of L3 cache-kernel cluster;

[0025] The distribution function is used to obtain the distribution information of the first kernel cluster corresponding to the host machine.

[0026] Furthermore, after generating the first kernel cluster distribution information based on the topology of the hardware resources, the process further includes:

[0027] The static hardware information of the host machine is sampled using a random function to obtain the second kernel cluster distribution information; the second kernel cluster distribution information includes the sampling distribution information of at least one CPU core;

[0028] Compare whether the second kernel cluster distribution information is consistent with the first kernel cluster distribution information;

[0029] If they are inconsistent, the topology of the hardware resources is reconstructed to update the distribution information of the first kernel cluster, so that the updated distribution information of the first kernel cluster is consistent with the distribution information of the second kernel cluster.

[0030] Furthermore, the second kernel cluster distribution information includes sampling distribution information of one CPU core or sampling distribution information of multiple CPU cores.

[0031] Further, an optimization strategy is formed based on the first kernel cluster distribution information and a preset quantization strategy, including:

[0032] The optimized deployment configuration for the virtual machine is determined based on the first kernel cluster distribution information and the preset quantization strategy.

[0033] An optimization strategy is formed based on the optimized deployment configuration corresponding to the virtual machine.

[0034] On the other hand, some embodiments of this specification also provide a virtual machine configuration device based on the C86 architecture, the device comprising:

[0035] The generation module is used to generate the first kernel cluster distribution information based on the host machine's system information;

[0036] A forming module is used to form an optimization strategy based on the first kernel cluster distribution information and a preset quantization strategy;

[0037] The configuration module is used to obtain virtual machine configuration information using the optimization strategy.

[0038] On the other hand, some embodiments of this specification also provide a computer device, including a memory, a processor, and a computer program stored in the memory, which, when run by the processor, executes instructions for the methods described above.

[0039] On the other hand, some embodiments of this specification also provide a computer storage medium having a computer program stored thereon, which, when run by the processor of a computer device, executes instructions for the methods described above.

[0040] On the other hand, some embodiments of this specification also provide a computer program product, which includes a computer program that, when run by the processor of a computer device, executes instructions for the methods described above.

[0041] Some embodiments of this specification provide one or more technical solutions, which have at least the following technical effects:

[0042] As can be seen from the technical solutions provided in the embodiments of this specification above, the embodiments of this specification are for the C86 architecture. They generate first kernel cluster distribution information based on the host system information to clarify the distribution of kernel clusters in the processor and computing modules. Thus, when configuring virtual machines, scheduling optimization can be performed based on the first kernel cluster distribution information and a preset quantization strategy to form an optimization strategy. The virtual machine configuration information is obtained from the optimization strategy, and resource isolation and flexible resource configuration of the virtual machine are performed based on the virtual machine configuration information to reduce the scheduling overhead of the virtual machine.

[0043] The above description is merely an overview of some embodiments of the technical solutions in this specification. In order to better understand the technical means of some embodiments of this specification and to implement them in accordance with the content of the specification, and to make the above and other objects, features and advantages of some embodiments of this specification more apparent and understandable, specific implementation methods of some embodiments of this specification are given below. Attached Figure Description

[0044] To more clearly illustrate some embodiments or technical solutions in the prior art of this specification, the accompanying drawings used in the description of the embodiments or prior art will be briefly introduced below. Obviously, the drawings described below are merely some embodiments recorded in this specification. For those skilled in the art, other drawings can be obtained based on these drawings without any creative effort. In the drawings:

[0045] Figure 1 A schematic diagram of an implementation system for a virtual machine configuration method based on the C86 architecture, as illustrated in some embodiments of this specification, is shown.

[0046] Figure 2 A flowchart illustrating a virtual machine configuration method based on the C86 architecture in some embodiments of this specification is shown;

[0047] Figure 3 This is a partial structural diagram of a processor under the C86 architecture in some embodiments of this specification;

[0048] Figure 4 These are schematic diagrams illustrating existing virtual machine configuration methods in some embodiments of this specification;

[0049] Figure 5 This is a schematic diagram illustrating the steps of generating the first kernel cluster distribution information based on the host machine's system information in some embodiments of this specification;

[0050] Figure 6 This is a schematic diagram illustrating the steps of constructing a hardware resource topology based on the host machine's system information in some embodiments of this specification.

[0051] Figure 7 This is a schematic diagram illustrating the steps for determining the topology of hardware resources between different levels in some embodiments of this specification;

[0052] Figure 8 This is a schematic diagram illustrating the steps of generating the first kernel cluster distribution information based on the topology of hardware resources in some embodiments of this specification;

[0053] Figure 9 This is a schematic diagram of the process for generating and verifying the distribution information of the first kernel set in some embodiments of this specification;

[0054] Figure 10 This is a schematic diagram illustrating the steps for verifying the distribution information of the first kernel cluster in some embodiments of this specification;

[0055] Figure 11 This is a schematic diagram illustrating the steps of forming an optimization strategy based on the first kernel cluster distribution information and a preset quantization strategy in some embodiments of this specification.

[0056] Figure 12 This is a schematic diagram of the virtual machine virtualization optimization process in some embodiments of this specification;

[0057] Figure 13 This is a schematic diagram of the virtual machine configuration before optimization in some embodiments of this specification;

[0058] Figure 14 These are schematic diagrams illustrating optimized virtual machine configurations in some embodiments of this specification;

[0059] Figure 15 This is a schematic diagram of the structure of a virtual machine configuration device based on the C86 architecture in some embodiments of this specification.

[0060] [Explanation of Labels in the Attached Image]

[0061] 1501, Generation Module;

[0062] 1502, Forming Modules;

[0063] 1503, Configuration Module. Detailed Implementation

[0064] To enable those skilled in the art to better understand the technical solutions in this specification, the technical solutions in some embodiments of this specification will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this specification, and not all embodiments. Based on some embodiments of this specification, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of this specification.

[0065] It should be noted that the terms "first," "second," etc., used in the specification, claims, and accompanying drawings herein are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, apparatus, product, or device that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or devices.

[0066] It should be noted that the acquisition, storage, use, and processing of data in the technical solution of this application all comply with the relevant provisions of relevant laws and regulations.

[0067] It should be noted that in the embodiments of this specification, certain software, components, models and other existing solutions in the industry may be mentioned. These should be regarded as exemplary and are only intended to illustrate the feasibility of implementing the technical solution of this application. However, they do not mean that the applicant has used or necessarily used the solution.

[0068] like Figure 1The diagram illustrates an implementation system of a virtual machine configuration method based on the C86 architecture according to an embodiment of the present invention. The implementation system may include a processor, memory, input / output interfaces (I / O), and a communication interface. The processor, memory, and I / O interfaces are connected via a system bus, and the communication interface is connected to the system bus via the I / O interfaces. The processor of this computer device provides computing and control capabilities. The memory of this computer device includes a non-volatile storage medium and internal memory. The non-volatile storage medium stores an operating system, computer programs, and a database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium. The database of this computer device stores virtual machine construction data. The I / O interfaces of this computer device are used for information exchange between the processor and external devices. The communication interface of this computer device is used for communication with external terminals via a network connection. When the computer program is executed by the processor, it implements a virtual machine configuration method based on the C86 architecture. Those skilled in the art will understand that… Figure 1 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0069] Figure 2 This is a flowchart illustrating a virtual machine configuration method based on the C86 architecture provided by an embodiment of the present invention. This specification provides the operational steps described in the embodiments or flowcharts, but based on conventional or non-inventive methods, more or fewer operational steps may be included. The order of steps listed in the embodiments is merely one possible execution order among many and does not represent the only possible execution order. In actual system or device products, the methods shown in the embodiments or accompanying drawings can be executed sequentially or in parallel. Specifically, as shown... Figure 2 As shown, the method may include:

[0070] S201: Generate the first kernel cluster distribution information based on the host machine's system information;

[0071] S202: Form an optimization strategy based on the first kernel cluster distribution information and the preset quantization strategy;

[0072] S203: Obtain virtual machine configuration information using the optimization strategy.

[0073] The embodiments in this specification are for the C86 architecture. They generate first kernel cluster distribution information based on the host system information to clarify the distribution of kernel clusters in the processor and computing modules. Thus, when configuring virtual machines, scheduling optimization can be performed based on the first kernel cluster distribution information and a preset quantization strategy to form an optimization strategy. The virtual machine configuration information is obtained from the optimization strategy, and resource isolation and flexible resource configuration of the virtual machine are performed based on the virtual machine configuration information to reduce the scheduling overhead of the virtual machine.

[0074] It can be understood that, in some embodiments, a C86 processor may include several compute modules (DIEs), each DIE typically consisting of one or more core clusters and other sub-modules (such as memory controllers, I / O interfaces, etc.), see Appendix Figure 3 The diagram shown illustrates a partial architecture of a processor under the C86 architecture. Each core cluster can consist of multiple CPU cores and a shared L3 cache. However, for the C86 architecture, as... Figure 4 The diagram shown illustrates an existing virtual machine configuration. Under this configuration, virtual machines may exhibit irregular distribution; for example, virtual machine vCPUs may be distributed across DIEs or across kernel clusters. Figure 4 In this example, virtual machines VM1 and VM2 are distributed across kernel clusters 0 and 1. However, because the L3 caches are independent of each other, ... Figure 4 The existing virtual machine configuration shown will significantly impact the performance of some applications that require frequent data scheduling for processing.

[0075] Furthermore, in some embodiments, before generating the first kernel cluster distribution information based on the host machine's system information, the process further includes:

[0076] By obtaining dynamic operational information of the host machine, the system information of the host machine can be obtained.

[0077] In some embodiments, the host machine's system information can be used to construct the topology of hardware resources, thereby generating first kernel cluster distribution information based on the hardware resource topology. By reading the host machine's dynamic operating information, the host machine's system information can be obtained to characterize the host machine's hardware resource distribution. Specifically, dynamic operating information can be obtained in real time by running commands or programs to query the host machine system.

[0078] Specifically, in some embodiments, the host system information may include physical CPU information, such as CPU model, number of cores, number of threads, etc. The host system information may also include non-consistent memory access node information, such as the memory layout, CPU distribution and distance between nodes of non-consistent memory access nodes, etc. The host system information may also include L3 cache information, such as the layout information between non-consistent memory access nodes and L3 cache.

[0079] See attached document Figure 5 In some embodiments, generating first kernel cluster distribution information based on the host machine's system information includes:

[0080] S501: Construct the topology of hardware resources based on the system information of the host machine;

[0081] S502: Generate the first kernel cluster distribution information based on the topology of the hardware resources.

[0082] This can be understood as follows: In some embodiments, when constructing the hardware resource topology based on the host machine's system information, the topological relationship between the kernel cluster and the slots, inconsistent memory access nodes, and L3 cache is obtained by constructing the topology between the slots, inconsistent memory access nodes, and L3 cache. Specifically, refer to the appendix... Figure 6 In some embodiments, constructing the hardware resource topology based on the host machine's system information may include:

[0083] S601: Determine the first mapping relationship between the slot and the non-consistent memory access node and the second mapping relationship between the non-consistent memory access node and the L3 cache based on the system information of the host machine;

[0084] S602: Determine the topology of hardware resources at each level using the system information of the host machine;

[0085] S603: Based on the topology, determine the correspondence between the topologies of hardware resources at different levels using the first mapping relationship and the second mapping relationship.

[0086] It can be understood that, in some embodiments, physical CPU information, non-consistent memory access node information, and L3 cache information can be determined based on the host machine's system information. The slot topology can be constructed based on the physical CPU information. Furthermore, a first mapping relationship between the slot and the non-consistent memory access node and a second mapping relationship between the non-consistent memory access node and the L3 cache can be obtained based on the host machine's system information. Thus, the correspondence between the topological structures of hardware resources at different levels (e.g., slot-non-consistent memory access node-L3 cache) can be obtained based on the first mapping relationship and the second mapping relationship.

[0087] See attached document Figure 7 In some embodiments, based on the topology, determining the correspondence of hardware resource topologies between different levels using the first mapping relationship and the second mapping relationship may further include:

[0088] S701: Based on the first mapping relationship, construct an inconsistent memory access topology corresponding to the slot topology in the topology using the inconsistent memory access node information;

[0089] S702: Based on the second mapping relationship, construct a three-level cache topology corresponding to the non-consistent memory access topology using the three-level cache information.

[0090] In some embodiments, a slot topology can be constructed based on physical CPU information, a non-consistent memory access topology can be constructed based on non-consistent memory access node information (NUMA node information), and a level 3 cache topology can be constructed based on level 3 cache information (L3 cache information). However, the topologies constructed in this way are only the topology of a single level of hardware resources, and do not establish the correspondence between the topologies of hardware resources at a single level. Therefore, it is necessary to determine the mapping relationship of each slot on the non-consistent memory access node based on the first mapping relationship, construct the non-consistent memory access topology corresponding to the slot topology in the topology using the non-consistent memory access node information, and determine the mapping relationship of each non-consistent memory access node on the level 3 cache based on the second mapping relationship, construct the level 3 cache topology corresponding to the non-consistent memory access topology using the level 3 cache information. This allows for the rapid and accurate determination of the topology of hardware resources between different levels, resulting in a multi-level, complete hardware resource topology.

[0091] Furthermore, in some embodiments, it further includes:

[0092] The topology of the hardware resources is deduplicated based on the first and second mapping relationships.

[0093] It can be understood that in some embodiments, when constructing the topology of hardware resources, there may be duplicate links between different topology nodes. These duplicate links can be obtained based on the first mapping relationship and the second mapping relationship. Therefore, it is necessary to deduplicate the topology of hardware resources to avoid interference from duplicate links and to simplify the topology of hardware resources, which is convenient for generating the first kernel cluster distribution information in the future.

[0094] See attached document Figure 8 In some embodiments, generating first kernel cluster distribution information based on the topology of the hardware resources may include:

[0095] S801: Analyze the allocation strategy of the L3 cache and the mapping relationship between the L3 cache and the kernel cluster based on the topology of the hardware resources, so as to construct the distribution function of L3 cache-kernel cluster;

[0096] S802: Use the distribution function to obtain the distribution information of the first kernel cluster corresponding to the host machine.

[0097] It can be understood that, in some embodiments, reference is made to the appendix. Figure 9 The flowchart shown illustrates the process of generating and verifying the first kernel cluster distribution information. After constructing the hardware resource topology using dynamic runtime information based on physical CPU information, NUMA node information, and L3 cache information, the allocation strategy of the L3 cache and the mapping relationship between the L3 cache and the kernel cluster can be analyzed based on this topology. This allows for the determination of the distribution function between the L3 cache and the kernel cluster, which can also be understood as a mapping function. Based on this distribution function, the first kernel cluster distribution information corresponding to the host machine can be quickly obtained (this first kernel cluster distribution information corresponds to the attached...). Figure 9 (The temporary kernel cluster distribution table in the table). Specifically, in some embodiments, referring to the mapping relationship diagram shown in Table 1, where CPU is the processor, NODE is the non-uniform memory access node, SOCKET is the socket, CORE is the physical core in the CPU, L1d:L1i:L2:L3 is the multi-level cache hierarchy of the CPU, and ONLINE is the status information, the first kernel cluster distribution information as shown in Table 2 can be obtained through the distribution function.

[0098] Table 1. Schematic diagram of mapping relationship

[0099]

[0100]

[0101] Table 2. Schematic diagram of the distribution information of the first kernel cluster.

[0102]

[0103] For ease of understanding, in some embodiments, the distribution information of the first kernel cluster can be represented not only in tabular form but also in topological diagram form. This article does not limit the presentation form of the distribution information of the first kernel cluster.

[0104] See attached document Figure 10 In some embodiments, after generating the first kernel cluster distribution information based on the topology of the hardware resources, the process may further include:

[0105] S1001: The host machine's static hardware information is sampled using a random function to obtain the second kernel cluster distribution information; the second kernel cluster distribution information includes the sampling distribution information of at least one CPU core;

[0106] S1002: Compare whether the second kernel cluster distribution information is consistent with the first kernel cluster distribution information;

[0107] S1003: If they are inconsistent, the topology of the hardware resources is reconstructed to update the first kernel cluster distribution information so that the updated first kernel cluster distribution information is consistent with the second kernel cluster distribution information.

[0108] It can be understood that, in some embodiments, reference continues to be made to the appendix. Figure 9 As shown, the host machine's static hardware information can be obtained based on static configuration information using hardware information collection functions and random functions for sampling. Based on this static hardware information, a second kernel cluster distribution information (i.e., a kernel cluster relationship table) is obtained. This second kernel cluster distribution information includes the sampling distribution information (i.e., core configuration information) of at least one CPU core. Further, in some embodiments, the second kernel cluster distribution information can be used to verify the accuracy of the host machine's system information obtained from dynamic runtime information. During verification, the accuracy of the first kernel cluster distribution information is determined by comparing whether the second kernel cluster distribution information is consistent with the first kernel cluster distribution information. If they are consistent, the first kernel cluster distribution information is accurate, and the final kernel cluster distribution table is output. If they are inconsistent, the topology of the hardware resources is reconstructed using the method described in any of the above embodiments to update the first kernel cluster distribution information, so that the updated first kernel cluster distribution information is consistent with the second kernel cluster distribution information.

[0109] Furthermore, in some embodiments, the second kernel cluster distribution information includes sampling distribution information of one CPU core or sampling distribution information of multiple CPU cores.

[0110] In some embodiments, when the second kernel cluster distribution information includes the sampling distribution information of one CPU core, it can be used to verify the first kernel cluster distribution information. When the second kernel cluster distribution information includes the sampling distribution information of multiple CPU cores, in addition to verifying the first kernel cluster distribution information, in some embodiments, it can also be used to generate the complete kernel cluster distribution information of the host machine. In some embodiments, the host machine's static hardware information can also be used to generate the complete kernel cluster distribution information of the host machine; that is, the host machine's system information can be obtained not only from dynamic runtime information but also from a combination of dynamic runtime information and static hardware information. This is not limited in this regard. In some embodiments, the complete kernel cluster distribution information of the host machine can also be obtained in other ways, such as through a specified firmware interface or management tool. This is not limited in this regard.

[0111] See attached document Figure 11 In some embodiments, the optimization strategy formed based on the first kernel cluster distribution information and a preset quantization strategy may include:

[0112] S1101: Determine the optimized deployment configuration corresponding to the virtual machine based on the first kernel cluster distribution information and the preset quantization strategy;

[0113] S1102: Optimization strategy is formed based on the optimized deployment configuration of the virtual machine.

[0114] This can be understood as follows: In some embodiments, based on the first kernel cluster distribution information, the optimized deployment configuration corresponding to the virtual machine is determined through a preset quantization strategy. This preset quantization strategy is derived from the comprehensive construction requirements of the virtual machine. Specifically, refer to the appendix... Figure 12 The preset quantization strategy can be obtained through a large number of tests on the test virtual machine. When determining the optimized deployment configuration corresponding to the test virtual machine based on the first kernel cluster distribution information, it is implemented on the basis of kernel cluster distribution calculation. Specifically, the optimized deployment configuration corresponding to the test virtual machine is used to characterize the calling relationship between the test virtual machine and the CPU in the kernel cluster distribution. The calling relationship refers to whether the test virtual machine calls the CPU. That is, the optimized deployment configuration corresponding to the test virtual machine is based on the principle of not calling across kernel clusters. It automatically optimizes the allocation of CPU resources according to the CPU model (e.g., CPU characteristics and / or CPU physical structure) to complete the load optimization analysis. The automatic allocation optimization means that there is no cross-kernel cluster call, no CPU resource contention, and no duplicate CPU calls between the test virtual machines. This can avoid resource contention caused by different test virtual machines calling the same CPU at the same time, which would affect the test results.

[0115] In another possible implementation, the CPU to be used can be randomly assigned to the current test virtual machine. The optimized deployment configuration for the test virtual machine may be that the test virtual machine does not use the CPU, or the test virtual machine keeps using the CPU, thereby achieving the optimal automatic allocation of the CPU resources.

[0116] In another possible implementation, the current test virtual machine can be randomly assigned not to use the CPU (instead, other CPUs in the same kernel cluster can be used). The optimized deployment configuration for the test virtual machine may be that the test virtual machine does not use the CPU, or the test virtual machine needs to use the CPU, thereby achieving the optimal automatic allocation of the CPU resources.

[0117] After obtaining the optimized deployment configuration corresponding to the test virtual machine, the call relationship between the test virtual machine and the CPU, as represented by the optimized deployment configuration, is used to adjust the randomly assigned CPU for the test virtual machine (e.g., maintaining the call to that CPU, or not calling that CPU but calling another CPU). This allows for testing the network performance, disk I / O performance, and memory performance of the test virtual machine within this test environment, thus completing the virtualization performance test. Through numerous tests, the optimized deployment configuration corresponding to the test virtual machine can be quantitatively evaluated, yielding a preset quantitative strategy (corresponding to the attached...). Figure 12 (Strategy set in the middle).

[0118] Based on this, in some embodiments, during virtual machine virtualization optimization, the virtualization basic environment detection and optimization function is used to ensure the reliability of the virtualization environment. Then, the virtual machine creation function is used to automatically create virtual machines. When creating virtual machines, virtual machines suitable for business types are created based on policy sets, and virtual machine scheduling and resource allocation policies are generated to obtain virtual machine configuration information, ensuring that virtual machines can select appropriate hardware resources according to performance requirements and optimization policies.

[0119] Further, refer to the appendix Figure 13 The diagram showing the virtual machine configuration before optimization and the attached diagram. Figure 14 As shown in the diagram of the optimized virtual machine configuration, this configuration information avoids the problems of latency and cache hit rate reduction caused by cross-kernel cluster access in virtual machine scheduling, which prevents the full utilization of CPU performance potential. It ensures that the virtual machine selects appropriate hardware resources according to performance requirements and optimization strategies, thereby improving the overall performance of virtualization.

[0120] It should be noted that although the operation of the method of the present invention has been described in a specific order in the above embodiments and figures, this does not require or imply that the operations must be performed in that specific order, or that all the operations shown must be performed to achieve the desired result. Additionally or alternatively, certain steps may be omitted, multiple steps may be combined into one step, and / or one step may be broken down into multiple steps.

[0121] Corresponding to the above-described virtual machine configuration method based on the C86 architecture, some embodiments of this specification also provide a virtual machine configuration apparatus based on the C86 architecture, see reference. Figure 15 As shown, in some embodiments, the apparatus may include:

[0122] Generation module 1501 is used to generate the first kernel cluster distribution information based on the host machine's system information;

[0123] The forming module 1502 is used to form an optimization strategy based on the first kernel cluster distribution information and a preset quantization strategy;

[0124] Configuration module 1503 is used to obtain virtual machine configuration information using the optimization strategy.

[0125] For ease of description, the above devices are described in terms of function, divided into various units. Of course, in implementing this specification, the functions of each unit can be implemented in one or more software and / or hardware components.

[0126] It should be noted that the computer program product described in this specification is a software product that mainly implements the methods described in this specification through a computer program.

[0127] Those skilled in the art will understand that the embodiments of this specification can be provided as methods, systems, or computer program products. Therefore, the embodiments of this specification can take the form of entirely hardware embodiments, entirely software embodiments, or embodiments combining software and hardware aspects. Furthermore, the embodiments of this specification can take the form of computer program products implemented on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0128] The embodiments described in this specification can be described in the general context of computer-executable instructions, such as program modules, that are executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform a specific task or implement a specific abstract data type. The embodiments of this specification can also be practiced in distributed computing environments where tasks are performed by remote processors connected via a communication network. In distributed computing environments, program modules can reside in local and remote computer storage media, including storage devices.

[0129] It should also be understood that, in the embodiments of this specification, the term "and / or" is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, and B existing alone. Additionally, the character " / " in this document generally indicates that the preceding and following related objects have an "or" relationship.

[0130] The various embodiments in this specification are described in a progressive manner. Similar or identical parts between embodiments can be referred to interchangeably. Each embodiment focuses on describing the differences from other embodiments. In particular, the system embodiments are basically similar to the method embodiments, so the description is relatively simple; relevant parts can be referred to the descriptions in the method embodiments.

[0131] In the description of this specification, the references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., refer to specific features, structures, materials, or characteristics described in connection with that embodiment or example, which are included in at least one embodiment or example of the embodiments of this specification. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples. Moreover, without contradiction, those skilled in the art can combine and integrate the different embodiments or examples described in this specification, as well as the features of different embodiments or examples.

[0132] The above description is merely an embodiment of this application and is not intended to limit the scope of this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of the claims of this application.

Claims

1. A virtual machine configuration method based on C86 architecture, characterized in that, The method includes: Generate the first kernel cluster distribution information based on the host machine's system information; An optimization strategy is formed based on the distribution information of the first kernel cluster and the preset quantization strategy; The virtual machine configuration information is obtained using the optimization strategy described above; The first kernel cluster distribution information is generated based on the host machine's system information, including: The topology of hardware resources is constructed based on the system information of the host machine; Generate the first kernel cluster distribution information based on the topology of the hardware resources; Constructing the hardware resource topology based on the host machine's system information includes: The first mapping relationship between the slot and the non-consistent memory access node and the second mapping relationship between the non-consistent memory access node and the L3 cache are determined based on the system information of the host machine. The topology of hardware resources at each level is determined using the system information of the host machine; Based on the aforementioned topology, the correspondence between the topologies of hardware resources at different levels is determined using the first and second mapping relationships.

2. The method according to claim 1, characterized in that, Before generating the first kernel cluster distribution information based on the host machine's system information, the following further steps are included: By obtaining dynamic operational information of the host machine, the system information of the host machine can be obtained.

3. The method according to claim 1, characterized in that, Based on the aforementioned topology, the correspondence between the topologies of hardware resources at different levels is determined using the first and second mapping relationships, further including: Based on the first mapping relationship, an inconsistent memory access topology corresponding to the slot topology in the topology structure is constructed using the inconsistent memory access node information. Based on the second mapping relationship, a three-level cache topology corresponding to the non-consistent memory access topology is constructed using the three-level cache information.

4. The method according to claim 1, characterized in that, Further includes: The topology of the hardware resources is deduplicated based on the first and second mapping relationships.

5. The method according to claim 3, characterized in that, Generate first kernel cluster distribution information based on the topology of the hardware resources, including: Based on the topology analysis of the hardware resources, the allocation strategy of the L3 cache and the mapping relationship between the L3 cache and the kernel cluster are analyzed to construct the distribution function of L3 cache-kernel cluster; The distribution function is used to obtain the distribution information of the first kernel cluster corresponding to the host machine.

6. The method according to claim 1, characterized in that, After generating the first kernel cluster distribution information based on the topology of the hardware resources, the process further includes: The static hardware information of the host machine is sampled using a random function to obtain the second kernel cluster distribution information; the second kernel cluster distribution information includes the sampling distribution information of at least one CPU core; Compare whether the second kernel cluster distribution information is consistent with the first kernel cluster distribution information; If they are inconsistent, the topology of the hardware resources is reconstructed to update the distribution information of the first kernel cluster, so that the updated distribution information of the first kernel cluster is consistent with the distribution information of the second kernel cluster.

7. The method according to claim 6, characterized in that, The second kernel cluster distribution information includes the sampling distribution information of one CPU core or the sampling distribution information of multiple CPU cores.

8. The method according to claim 1, characterized in that, An optimization strategy is formed based on the distribution information of the first kernel cluster and a preset quantization strategy, including: The optimized deployment configuration for the virtual machine is determined based on the first kernel cluster distribution information and the preset quantization strategy. An optimization strategy is formed based on the optimized deployment configuration corresponding to the virtual machine.

9. A virtual machine configuration device based on the C86 architecture, characterized in that, The device includes: The generation module is used to generate the first kernel cluster distribution information based on the host machine's system information; A forming module is used to form an optimization strategy based on the first kernel cluster distribution information and a preset quantization strategy; The configuration module is used to obtain virtual machine configuration information using the optimization strategy; The generation module is further configured to: construct a hardware resource topology based on the host machine's system information; generate first kernel cluster distribution information based on the hardware resource topology; wherein, based on the host machine's system information, determine a first mapping relationship between slots and non-consistent memory access nodes and a second mapping relationship between non-consistent memory access nodes and L3 cache; determine the topology of hardware resources at each level using the host machine's system information; and, based on the topology, determine the correspondence between the topologies of hardware resources at different levels using the first and second mapping relationships.

10. A computer device comprising a memory, a processor, and a computer program stored in the memory, characterized in that, When the computer program is run by the processor, it executes the instructions of the method according to any one of claims 1-8.

11. A computer storage medium having a computer program stored thereon, characterized in that, When the computer program is run by the processor of the computer device, it executes the instructions of the method according to any one of claims 1-8.

12. A computer program product, characterized in that, The computer program product includes a computer program that, when executed by a processor, performs instructions according to any one of claims 1-8.