This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH 5/6] nptl: Convert some rwlock tests to use libsupport
- From: Mike Crowe <mac at mcrowe dot com>
- To: Florian Weimer <fweimer at redhat dot com>, libc-alpha at sourceware dot org
- Cc: Adhemerval Zanella <adhemerval dot zanella at linaro dot org>
- Date: Mon, 8 Apr 2019 09:24:00 +0100
- Subject: Re: [PATCH 5/6] nptl: Convert some rwlock tests to use libsupport
- References: <cover.13c2d68f411f9010956e8e52edfbe168964e1e5c.1553797867.git-series.mac@mcrowe.com> <cover.13c2d68f411f9010956e8e52edfbe168964e1e5c.1553797867.git-series.mac@mcrowe.com> <286b598d77c33052867a27e071409e8c0e3ce8cf.1553797867.git-series.mac@mcrowe.com> <87o95k3e5o.fsf@oldenburg2.str.redhat.com> <20190406201530.wdhuxcbifseabyfy@mcrowe.com> <87d0lxszu3.fsf@oldenburg2.str.redhat.com>
On Monday 08 April 2019 at 09:47:32 +0200, Florian Weimer wrote:
> * Mike Crowe:
> > However, I'm less sure about this code from tst-rwlock7.c(do_test):
> >
> > size_t cnt;
> > for (cnt = 0; cnt < sizeof (kind) / sizeof (kind[0]); ++cnt)
> > {
> > pthread_rwlock_t r;
> > pthread_rwlockattr_t a;
> > if (pthread_rwlockattr_init (&a) != 0)
> > FAIL_EXIT1 ("round %Zu: rwlockattr_t failed\n", cnt);
> >
> > if (pthread_rwlockattr_setkind_np (&a, kind[cnt]) != 0)
> > FAIL_EXIT1 ("round %Zu: rwlockattr_setkind failed\n", cnt);
> > ...
> >
> > If the round numbers are important then I need to keep the messages. If
> > not, then I can also replace these with TEST_COMPARE. Do you have an
> > opinion on that?
>
> I don't think I've ever seen tst-rwlock7 fail, so I don't know if the
> round numbers are useful for diagnosing test failures.
The patch series I posted yesterday[1] leaves these messages showing the
round number (as above.) I'm happy to change them to use TEST_COMPARE
instead if required.
Thanks.
Mike.
[1] https://sourceware.org/ml/libc-alpha/2019-04/msg00161.html