Patent ID: 9519573
Filing Date: 2016-12-13
CPC Classification: G06F

Claim Text:
1. A method for creating a software performance testing environment on a virtual machine system, the virtual machine system running at least one virtual machine (VM) on a single hardware platform, the single hardware platform having a central processor unit (CPU) configured to simulate a target environment on which software is to be run, said method comprising: obtaining, at the CPU, a hard disk read/write request triggered by a virtual CPU of the virtual machine, and in response to obtaining said triggered request, notifying a virtual CPU scheduler to record a CPU time duration t in response to detecting completion of hard disk read/write processing corresponding to the hard disk read/write request, predicting, by the CPU, a hard disk read/write latency t corresponding to the hard disk read/write request in a target environment, said latency t based a time when the hard disk read/write processing is completed; notifying, by the CPU, the virtual CPU scheduler to determine a CPU processing time already consumed by the virtual CPU in the current CPU schedule period based on the recorded CPU time duration t adjusting, by the CPU, a system clock of the virtual machine forward based on the determined CPU processing time already consumed by the virtual CPU in the current CPU schedule period, wherein in response to said detecting completion of hard disk read/write processing corresponding to the hard disk read/write request, said predicting a hard disk read/write latency t corresponding to the hard disk read/write request in a target environment comprises: determining that the hard disk read/write request belongs to a hard disk read/write request that would not occur in the target environment, and predicting that, in the target environment, the hard disk read/write latency t corresponding to the hard disk read/write request is equal to 0, wherein the determining that the hard disk read/write request belongs to a hard disk read/write request that would not occur in the target environment comprises: wherein in response to obtaining a hard disk read/write request triggered by a virtual CPU of the virtual machine, and said notifying a virtual CPU scheduler to record a CPU time duration t notifying the virtual CPU scheduler to cause the virtual CPU to suspend its work; and wherein said determining that the hard disk read/write request belongs to a hard disk read/write request that would not occur in the target environment, and predicting that, in the target environment, the hard disk read/write latency t corresponding to the hard disk read/write request is equal to 0 further comprises: notifying the virtual CPU scheduler to cause the suspended virtual CPU to resume its work; wherein said notifying the virtual CPU scheduler to determine a CPU processing time already consumed by the virtual CPU in the current CPU schedule period based on the recorded CPU time duration t notifying the virtual CPU scheduler to set the CPU processing time already consumed by the virtual CPU in the current CPU schedule period to t