On Tue, May 28, 2013 at 05:35:55PM +0200, Julian Stecklina wrote: > On 05/28/2013 03:56 PM, Michael S. Tsirkin wrote: > > and in fact that was how vhost worked originally. > > There were some issues to be fixed before it worked > > without issues, but we do plan to go back to that I think. > > Do you know why they abandoned this execution model? > > Julian >
Yes I do. Two main issues: 1. Originally vhost used a shared workqueue for everything. It turned out that an access to userspace memory might sometimes block e.g. if it hit swap. When this happened the whole workqueue got blocked, and no guest could make progress. 2. workqueue was sticking to one CPU too aggressively E.g. there could be 10 free CPUs on the box, workqueue was still using the same one which queued the work even if that one was very busy. This all got sorted out in core workqueue code, so we should go back and try using the regular workqueue. -- MST