A non-transitory computer-readable storage medium, wherein the computer-readable storage medium stores instructions, and when the instructions are executed by at least a processor, the processor is caused to implement a host memory resource processing method for a data processing unit virtualization scenario, the method comprises:
- receiving a virtual machine creation request, wherein the virtual machine creation request is used to request creation of a virtual machine that complies with a memory configuration requirement of a target virtual machine;
- starting the target virtual machine according to the memory configuration requirement of the target virtual machine and creating two types of entries corresponding to the memory configuration requirement, wherein the two types of entries comprise a user available entry and a firmware reserved entry, a memory address of the user available entry indicates available memory of the target virtual machine, a memory address of the firmware reserved entry indicates system reserved memory, and a memory size corresponding to the firmware reserved entry is determined according to a preset first proportion and a memory size specified in the memory configuration requirement;
- and
- constructing a memory information table corresponding to the target virtual machine based on the two types of entries, and sending the memory information table to the target virtual machine, wherein the memory information table represents physical memory mapping information of the target virtual machine.