DPDK patches and discussions
 help / color / mirror / Atom feed
From: Bruce Richardson <bruce.richardson@intel.com>
To: fengchengwen <fengchengwen@huawei.com>
Cc: <dev@dpdk.org>, <stable@dpdk.org>
Subject: Re: [PATCH v3] test: improve resiliency of malloc autotest
Date: Fri, 7 Feb 2025 08:47:58 +0000	[thread overview]
Message-ID: <Z6XIvuxbNHvcqRQP@bricha3-mobl1.ger.corp.intel.com> (raw)
In-Reply-To: <3ab6643a-6bcf-49b8-9ae1-88bc6dd89170@huawei.com>

On Fri, Feb 07, 2025 at 03:44:56PM +0800, fengchengwen wrote:
> On 2025/2/6 19:40, Bruce Richardson wrote:
> > On Fri, Jan 24, 2025 at 03:18:11PM +0800, fengchengwen wrote:
> >> The new impl don't support re-test, how about add a wrap:
> >> 1. rename test_multi_alloc_statistics with do_test_multi_alloc_statistics, and make it take socket as parameter
> >> 2. create a new function test_multi_alloc_statistics {
> >>     // prepare a new malloc heap
> >>     ret = do_test_multi_alloc_statistics(socket);
> >>     // free the heap
> >>     return ret;
> >> }
> >>
> > 
> > Can you clarify the issues being seen on re-test? I have just run
> > malloc_autotest multiple times within the same dpdk-test instance and not
> > seen any issues.
> 
> If the middle logic fail, for example:
> 
> 	if ((post_stats.heap_totalsz_bytes != pre_stats.heap_totalsz_bytes) ||
> 			(post_stats.heap_freesz_bytes != pre_stats.heap_freesz_bytes) ||
> 			(post_stats.heap_allocsz_bytes != pre_stats.heap_allocsz_bytes) ||
> 			(post_stats.alloc_count != pre_stats.alloc_count) ||
> 			(post_stats.free_count != pre_stats.free_count)) {
> 		printf("Malloc statistics are incorrect - freed alloc\n");
> 		return -1;
> 	}
> 
> If the above if branch taken, then retest, the rte_malloc_heap_create(__func__) will
> failed because already exist the heap.
> 
Ok, retest on failure is broken. Got it. Will rework.

  reply	other threads:[~2025-02-07  8:48 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-17 12:59 [PATCH] " Bruce Richardson
2025-01-17 13:52 ` [PATCH v2] " Bruce Richardson
2025-01-17 14:20   ` Dmitry Kozlyuk
2025-01-17 14:26     ` Bruce Richardson
2025-01-17 16:57       ` Stephen Hemminger
2025-01-17 14:40 ` [PATCH v3] " Bruce Richardson
2025-01-24  7:18   ` fengchengwen
2025-02-06 11:40     ` Bruce Richardson
2025-02-07  7:44       ` fengchengwen
2025-02-07  8:47         ` Bruce Richardson [this message]
2025-02-07 14:31 ` [PATCH] " Bruce Richardson
2025-02-07 14:32 ` [PATCH v4] " Bruce Richardson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Z6XIvuxbNHvcqRQP@bricha3-mobl1.ger.corp.intel.com \
    --to=bruce.richardson@intel.com \
    --cc=dev@dpdk.org \
    --cc=fengchengwen@huawei.com \
    --cc=stable@dpdk.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).