-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
This issue shall replace the current mechanism of trapping syscalls that is based on a heavy VMExit with ioeventfd. By using this mechanism, the VMM will be notified asynchronously that the app requires a syscall. This happens when the app writes to a specific mmio register. This is the mechanism used in vhost and for the virtqueue notification. This seems to perform better than user-space VMExits. The new mechanism would be:
- app guest writes to special mmio reg
- Event is triggered in the thread that processes eventfd
- The thread processes the request and tells the app guest that is done
- app guest resumes execution. Here I am sure how the VMM should tell the guest that the syscall is done.
- Implement eventfd in fpc linux unit (https://fpc-pascal.freepascal.narkive.com/w3YSd13n/using-eventfd)
- Add
struct kvm_ioeventfd - Implement
int ioeventfd__init(struct kvm *kvm) - Implement
static int ioeventfd__start(void)
[1] see virtio_mmio_init_ioeventfd() at https://github.com/clearlinux/kvmtool/blob/b5891a4337eb6744c8ac22cc02df3257961ae23e/virtio/mmio.c
[2] see ioeventfd__add_event() at https://github.com/clearlinux/kvmtool/blob/master/ioeventfd.c
[3] http://blog.allenx.org/2015/07/05/kvm-irqfd-and-ioeventfd
Metadata
Metadata
Assignees
Labels
No labels