The bhyve vLAPIC uses an instance-global flag to indicate when an error LVT is being delivered. This is to prevent infinite recursion if the error LVT itself is configured with an invalid vector. Such error-handling status could be passed as a function argument, rather than more complicated logic with "global" state.
This was inspired by the bhyve save/restore work, which called into question vLAPIC state outside the raw LAPIC page itself.
SmartOS ticket: OS-7777