hv_vcpu_run_until(_:_:)
Executes a vCPU until it reaches the deadline defined in absolute time units you provide.
Declaration
func hv_vcpu_run_until(_ vcpu: hv_vcpuid_t, _ deadline: UInt64) -> hv_return_tParameters
- vcpu:
The instance of the vCPU.
- deadline:
The timer deadline in mach absolute time units. Use the special value Hv_deadline_forever to specify a deadline that never expires.
Return Value
HV_SUCCESS if the operation was successful, otherwise an error code specified in hv_return_t.
Discussion
If the deadline you specify is other than HV_DEADLINE_FOREVER, this call uses the VMX preemption timer. If the hardware doesn’t support the VMX preemption timer, it returns HV_UNSUPPORTED.
This function supersedes hv_vcpu_run(_:) on Intel-based Mac computers. Unlike hv_vcpu_run(_:), it doesn’t return on transparently handled VMEXITs.