• J
    vhost: cache used event for better performance · 809ecb9b
    Jason Wang 提交于
    When event index was enabled, we need to fetch used event from
    userspace memory each time. This userspace fetch (with memory
    barrier) could be saved sometime when 1) caching used event and 2)
    if used event is ahead of new and old to new updating does not cross
    it, we're sure there's no need to notify guest.
    
    This will be useful for heavy tx load e.g guest pktgen test with Linux
    driver shows ~3.5% improvement.
    Signed-off-by: NJason Wang <jasowang@redhat.com>
    Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
    809ecb9b
vhost.c 57.3 KB