wfit
Wait For Interrupt with Timeout
WFIT <Wn>
Waits for an interrupt or a timeout.
Pseudocode Operation
timeout ← Wn
while (timeout > 0 AND interrupt_not_pending()) {
timeout ← timeout - 1
enter_low_power_state()
}
Wn ← timeout
Example
WFIT w1
Encoding
Binary Layout
11010101000000110001
31:12
0000
11:8
001
7:5
Rd
4:0
Operands
-
Wn
Timeout
Related
More in Base (v8.7)
Reference
View in Arm A64 ISA Reference ↗
Arm A64 ISA
Instruction Forms
| Encoding | Instruction | ISA | Bit pattern | ||
|---|---|---|---|---|---|
| 0xD5031020 | WFIT <Xt> | A64 | 11010101000000110001 | 0000 | 001 | Rd |
Description
Wait For Interrupt with Timeout is a hint instruction that indicates that the PE can enter a low-power state and remain there until either a local timeout event or a wakeup event occurs. For more information, see Wait For Interrupt. As described in Wait For Interrupt, the execution of a WFIT instruction that would otherwise cause entry to a low-power state can be trapped to a higher Exception level.
Operation
integer localtimeout = UInt(X[d, 64]);
if Halted() && ConstrainUnpredictableBool(Unpredictable_WFxTDEBUG) then
EndOfInstruction();
Hint_WFI(localtimeout, WFxType_WFIT);