DPDK patches and discussions
 help / color / mirror / Atom feed
From: Ruifeng Wang <ruifeng.wang@arm.com>
To: aconole@redhat.com, maicolgabriel@hotmail.com
Cc: dev@dpdk.org, gavin.hu@arm.com, honnappa.nagarahalli@arm.com,
	juraj.linkes@pantheon.tech, nd@arm.com,
	Ruifeng Wang <ruifeng.wang@arm.com>
Subject: [dpdk-dev] [PATCH 2/4] test/cycles: increase threshold for containers on aarch64
Date: Fri, 24 Apr 2020 15:43:54 +0800	[thread overview]
Message-ID: <20200424074356.193204-3-ruifeng.wang@arm.com> (raw)
In-Reply-To: <20200424074356.193204-1-ruifeng.wang@arm.com>

rte_delay_us_xxx could have more deviation than expected when system
load is high. Test case failures were observed on Travis CI which run
unit test in container for aarch64.

Use looser criteria for cycle tests on aarch64.

Signed-off-by: Ruifeng Wang <ruifeng.wang@arm.com>
Reviewed-by: Gavin Hu <gavin.hu@arm.com>
---
 app/test/test_cycles.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/app/test/test_cycles.c b/app/test/test_cycles.c
index 015a9290f..52bc9af81 100644
--- a/app/test/test_cycles.c
+++ b/app/test/test_cycles.c
@@ -30,6 +30,13 @@ check_wait_one_second(void)
 	uint64_t hz = rte_get_timer_hz();
 	uint64_t max_inc = (hz / 100); /* 10 ms max between 2 reads */
 
+#if defined(RTE_ARCH_ARM64)
+	/* When testing in containers, 'delay' could have less accuracy
+	 * if system is busy.
+	 */
+	max_inc = 3 * max_inc;
+#endif
+
 	/* check that waiting 1 second is precise */
 	prev_cycles = rte_get_timer_cycles();
 	rte_delay_us(1000000);
-- 
2.17.1


  parent reply	other threads:[~2020-04-24  7:44 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-24  7:43 [dpdk-dev] [PATCH 0/4] arm64 CI stabilize Ruifeng Wang
2020-04-24  7:43 ` [dpdk-dev] [PATCH 1/4] test/cycles: restore original delay function Ruifeng Wang
2020-04-24  7:43 ` Ruifeng Wang [this message]
2020-04-24  7:43 ` [dpdk-dev] [PATCH 3/4] ci: expose test time out argument Ruifeng Wang
2020-04-24  7:43 ` [dpdk-dev] [PATCH 4/4] ci: increase time out multiplier for containers on aarch64 Ruifeng Wang
2020-07-27 10:16 ` [dpdk-dev] [PATCH v2] test/cycles: restore original delay function Ruifeng Wang
2020-07-27 10:21 ` Ruifeng Wang
2020-07-27 12:21   ` David Marchand

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=20200424074356.193204-3-ruifeng.wang@arm.com \
    --to=ruifeng.wang@arm.com \
    --cc=aconole@redhat.com \
    --cc=dev@dpdk.org \
    --cc=gavin.hu@arm.com \
    --cc=honnappa.nagarahalli@arm.com \
    --cc=juraj.linkes@pantheon.tech \
    --cc=maicolgabriel@hotmail.com \
    --cc=nd@arm.com \
    /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).