From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [announce] KVM/NET, paravirtual network device Date: Thu, 11 Jan 2007 19:49:49 +0200 Message-ID: <45A678BD.3020401@qumranet.com> References: <20070111001010.GA28779@elte.hu> <45A5F382.7050207@qumranet.com> <45A67653.9000406@plausible.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: kvm-devel Return-path: To: Andy Ross In-Reply-To: <45A67653.9000406-DKCljQvcl/LNLxjTenLetw@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org Errors-To: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org List-Id: kvm.vger.kernel.org Andy Ross wrote: > Avi Kivity wrote: > > Ingo Molnar wrote: > > > | Qemu via RTL-8029 emulation : 2.84 MB/sec | > > > | KVM via RTL-8029 emulation : 7.41 MB/sec | > > > | KVM-para via KVM/NET device (mtu=1500) : 303.35 MB/sec | > > > > That's about a 5000% improvement :) > > > > Amazing, both the bandwidth results and the speed in which it was > > reached. I'm really at a loss for words. > > Is maybe a better question to ask what it is that makes the Qemu > hardware emulation so slow? > To send a packet through ne2k, you need about 44 pio writes. at ~10us per pio write, that's about 2k packets/sec, or 3MB/sec. RTL8029 is about twice as fast. A pv interface can send multiple packets per hypercall. Working backward from Ingo's numbers, 300 MB/sec = 200k packets/sec = 2 packets/hypercall. Or perhaps his hardware is faster and he does 1 packet/hypercall. Or maybe I need to take the memcpy time into account at this bandwidth :) -- Do not meddle in the internals of kernels, for they are subtle and quick to panic. ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV