Only expect timeouts on powerpc with NetBSD
Submitted by: pho
This commit is contained in:
parent
a81c27fd8c
commit
190e1b1c9b
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=274572
@ -117,9 +117,11 @@ ATF_TC(mutex2);
|
||||
ATF_TC_HEAD(mutex2, tc)
|
||||
{
|
||||
atf_tc_set_md_var(tc, "descr", "Checks mutexes");
|
||||
#ifdef __NetBSD__
|
||||
#if defined(__powerpc__)
|
||||
atf_tc_set_md_var(tc, "timeout", "40");
|
||||
#endif
|
||||
#endif
|
||||
}
|
||||
ATF_TC_BODY(mutex2, tc)
|
||||
{
|
||||
@ -129,8 +131,10 @@ ATF_TC_BODY(mutex2, tc)
|
||||
|
||||
printf("1: Mutex-test 2\n");
|
||||
|
||||
#ifdef __NetBSD__
|
||||
#if defined(__powerpc__)
|
||||
atf_tc_expect_timeout("PR port-powerpc/44387");
|
||||
#endif
|
||||
#endif
|
||||
|
||||
PTHREAD_REQUIRE(pthread_mutex_init(&mutex, NULL));
|
||||
@ -158,6 +162,7 @@ ATF_TC_BODY(mutex2, tc)
|
||||
global_x, (long)joinval);
|
||||
ATF_REQUIRE_EQ(global_x, 20000000);
|
||||
|
||||
#ifdef __NetBSD__
|
||||
#if defined(__powerpc__)
|
||||
/* XXX force a timeout in ppc case since an un-triggered race
|
||||
otherwise looks like a "failure" */
|
||||
@ -165,6 +170,7 @@ ATF_TC_BODY(mutex2, tc)
|
||||
complain about unexpected success */
|
||||
sleep(41);
|
||||
#endif
|
||||
#endif
|
||||
}
|
||||
|
||||
static void *
|
||||
@ -188,9 +194,11 @@ ATF_TC_HEAD(mutex3, tc)
|
||||
{
|
||||
atf_tc_set_md_var(tc, "descr", "Checks mutexes using a static "
|
||||
"initializer");
|
||||
#ifdef __NetBSD__
|
||||
#if defined(__powerpc__)
|
||||
atf_tc_set_md_var(tc, "timeout", "40");
|
||||
#endif
|
||||
#endif
|
||||
}
|
||||
ATF_TC_BODY(mutex3, tc)
|
||||
{
|
||||
@ -200,8 +208,10 @@ ATF_TC_BODY(mutex3, tc)
|
||||
|
||||
printf("1: Mutex-test 3\n");
|
||||
|
||||
#ifdef __NetBSD__
|
||||
#if defined(__powerpc__)
|
||||
atf_tc_expect_timeout("PR port-powerpc/44387");
|
||||
#endif
|
||||
#endif
|
||||
|
||||
global_x = 0;
|
||||
@ -227,6 +237,7 @@ ATF_TC_BODY(mutex3, tc)
|
||||
global_x, (long)joinval);
|
||||
ATF_REQUIRE_EQ(global_x, 20000000);
|
||||
|
||||
#ifdef __NetBSD__
|
||||
#if defined(__powerpc__)
|
||||
/* XXX force a timeout in ppc case since an un-triggered race
|
||||
otherwise looks like a "failure" */
|
||||
@ -234,6 +245,7 @@ ATF_TC_BODY(mutex3, tc)
|
||||
complain about unexpected success */
|
||||
sleep(41);
|
||||
#endif
|
||||
#endif
|
||||
}
|
||||
|
||||
static void *
|
||||
|
Loading…
Reference in New Issue
Block a user