|
From: | Zhou Jie |
Subject: | Re: [Qemu-devel] [PATCH] hw/net/opencores_eth: Allocating Large sized arrays to heap |
Date: | Wed, 27 Apr 2016 09:03:37 +0800 |
User-agent: | Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.7.2 |
On 2016/4/26 12:12, Max Filippov wrote:
Hi Zhou, On Tue, Apr 26, 2016 at 6:35 AM, Zhou Jie <address@hidden> wrote:open_eth_start_xmit has a huge stack usage of 65536 bytes approx. Moving large arrays to heap to reduce stack usage.It's an exception, not the rule when full 65536 byte long buffer might be needed. Can we do a little better change and not allocate and free this buffer every time unconditionally, but instead make buf smaller (1536 bytes, maximal frame length when HUGEN bit is not set in MODER) and only do allocation when that's not enough?
Thank you for your suggestion. I will modify this patch. Sincerely, Zhou Jie -- ------------------------------------------------ 周潔 Dept 1 No. 6 Wenzhu Road, Nanjing, 210012, China TEL:+86+25-86630566-8557 FUJITSU INTERNAL:7998-8557 address@hidden ------------------------------------------------
[Prev in Thread] | Current Thread | [Next in Thread] |