bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: PTHREAD_MUTEX_ADAPTIVE_NP undefined in Gecko


From: Riccardo Mottola
Subject: Re: PTHREAD_MUTEX_ADAPTIVE_NP undefined in Gecko
Date: Tue, 9 Feb 2021 13:04:54 +0100
User-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:60.0) Gecko/20100101 SeaMonkey/2.53.6

Hi Richardm,


Richard Braun wrote:
The _NP suffix means non-posix, and is generally used for system-specific
features. The use of "adaptive" mutexes is probably just an optimization,
so it should be completely safe to just comment it out on systems where
the macro doesn't exist (assuming it's a macro).

thank you, it must be optional:

#if (defined(LINUX) && (__GLIBC__ > 2) || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2)) || \
    (defined(FREEBSD) && __FreeBSD_version > 700055)
    rv = pthread_mutexattr_settype(&_pt_mattr, PTHREAD_MUTEX_ADAPTIVE_NP);
    PR_ASSERT(0 == rv);
#endif

does HURD define LINUX? somehow counterintuitive, I'd expect only GNU, but not LINUX: would help in these situations

Riccardo




reply via email to

[Prev in Thread] Current Thread [Next in Thread]