nutanix / libvfio-user

framework for emulating devices in userspace
BSD 3-Clause "New" or "Revised" License
162 stars 51 forks source link

avoid vfu_log() in SGL hot path #705

Closed jlevon closed 2 years ago

jlevon commented 2 years ago

Even though in non-debug, we don't actually log anything here, even assembling the arguments to vfu_log() has a performance impact. Hide them behind a DEBUG_SGL define - even in a DEBUG build, they are particularly noisy and low-value.

Signed-off-by: John Levon john.levon@nutanix.com