From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50181) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1avFUp-0004hT-AB for qemu-devel@nongnu.org; Tue, 26 Apr 2016 22:46:36 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1avFUk-00051d-Bc for qemu-devel@nongnu.org; Tue, 26 Apr 2016 22:46:35 -0400 Received: from mail-lf0-x234.google.com ([2a00:1450:4010:c07::234]:36084) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1avFUk-00051X-3x for qemu-devel@nongnu.org; Tue, 26 Apr 2016 22:46:30 -0400 Received: by mail-lf0-x234.google.com with SMTP id u64so35838574lff.3 for ; Tue, 26 Apr 2016 19:46:29 -0700 (PDT) Date: Wed, 27 Apr 2016 05:46:26 +0300 From: Max Filippov Message-ID: <20160427024626.GB17756@octofox.metropolis> References: <1461722868-11624-1-git-send-email-zhoujie2011@cn.fujitsu.com> <57202190.9070106@cn.fujitsu.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <57202190.9070106@cn.fujitsu.com> Subject: Re: [Qemu-devel] [PATCH v2] hw/net/opencores_eth: Allocating Large sized arrays to heap List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Zhou Jie Cc: qemu-devel@nongnu.org Hi Zhou, On Wed, Apr 27, 2016 at 10:18:56AM +0800, Zhou Jie wrote: > When I committed another patch which named as > "hw/net/virtio-net: Allocating Large sized arrays to heap" . > > Christian Borntraeger said that 16k is usually perfectly fine > for a userspace stack and doing allocations in a hot path > might actually hurt performance. > > Although the size is 65536 bytes here, > I think open_eth_start_xmit is in a hot path. > So, it is OK, if you think that this patch should not be applied. With Linux as guest OS we shouldn't see any allocations as it doesn't send huge packets, so I think this patch is fine. I can take it through the xtensa tree if you don't have other plan. -- Thanks. -- Max