<!--
{
  "availability" : [
    "macOS: 27.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Hypervisor",
  "identifier" : "/documentation/Hypervisor/hv_vcpu_get_wait_for_interrupt_time(_:_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "Hypervisor"
    ],
    "preciseIdentifier" : "c:@F@hv_vcpu_get_wait_for_interrupt_time"
  },
  "title" : "hv_vcpu_get_wait_for_interrupt_time(_:_:)"
}
-->

# hv_vcpu_get_wait_for_interrupt_time(_:_:)

```
func hv_vcpu_get_wait_for_interrupt_time(_ vcpu: hv_vcpu_t, _ time: UnsafeMutablePointer<UInt64>) -> hv_return_t
```

## Parameters

`vcpu`

ID of the vcpu instance.

`time`

Pointer to wait time value (written on success).

## Return Value

HV_SUCCESS on success, error code otherwise.

## Discussion\abstract Returns the cumulative wait time of a vCPU spent at WFI instruction while waiting for interrupts in the units of mach_absolute_time().
\discussion Must be called by the owning thread.
Returns HV_UNSUPPORTED if the VM was created without a GIC device (hv_gic_create).

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)