[DTrace-devel] [PATCH] test: Lengthen the delay in USDT defer trigger.

eugene.loh at oracle.com eugene.loh at oracle.com
Wed Dec 11 07:21:31 UTC 2024


From: Eugene Loh <eugene.loh at oracle.com>

The trigger usdt-tst-defer.c expects that, as soon as probe foo is
enabled, so too are the foo and bar is-enabled probes as well as
the bar probe.  Since they are not turned on absolutely concurrently,
the trigger actually has a microsleep after foo is enabled and
before further activity is resumed.  Nonetheless, there is evidence
in occasional test runs that some events are missed.

Since there are no guarantees how concurrently these probes are
turned on, lengthen the delay.

Signed-off-by: Eugene Loh <eugene.loh at oracle.com>
---
 test/triggers/usdt-tst-defer.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/test/triggers/usdt-tst-defer.c b/test/triggers/usdt-tst-defer.c
index 2df5401b2..51125de2b 100644
--- a/test/triggers/usdt-tst-defer.c
+++ b/test/triggers/usdt-tst-defer.c
@@ -57,7 +57,7 @@ main(int argc, char **argv)
 	}
 
 	/* wait for probes to get set up */
-	usleep(100000);
+	usleep(500 * 1000);
 
 	/* in phase 2, just loop over probe "bar" a fixed number of times */
 	for (i = 0; i < 10; i++) {
-- 
2.43.5




More information about the DTrace-devel mailing list