Re: [LTP] Re: PTHREAD_THREADS_MAX missing?
"Robert Williamson" <[email protected]>
| Newsgroups | gmane.comp.lib.phil |
|---|---|
| Message-ID | <OF129C1F8E.E2EB2CBF-ON85256CFC.00679F19-86256CFC.0067C914@pok.ibm.com> |
Although the LTP has no goal of becoming "POSIX compliant"....mostly b/c Linux itself is not....I agree that any test for POSIX threads should be. I added the following code, in hopes that it will be more "generic": #ifdef PTHREAD_THREADS_MAX #define PIDS PTHREAD_THREADS_MAX /* maximum thread allowed. */ #elif defined(PID_MAX_DEFAULT) #define PIDS PID_MAX_DEFAULT /* maximum pids allowed. */ #elif defined(PID_MAX) #define PIDS PID_MAX /* alternative way maximum pids may be defined */ #endif - Robbie Robert V. Williamson <[email protected]> Linux Test Project IBM Linux Technology Center Phone: (512) 838-9295 T/L: 678-9295 Fax: (512) 838-4603 Web: http://ltp.sourceforge.net IRC: #ltp on freenode.irc.net ==================== "Only two things are infinite, the universe and human stupidity, and I'm not sure about the former." -Albert Einstein Dan Kegel <[email protected]> To: Christoph Hellwig <[email protected]> Sent by: cc: [email protected], [email protected], [email protected] "'[email protected]'" <[email protected]> ceforge.net Subject: [LTP] Re: PTHREAD_THREADS_MAX missing? 04/02/2003 12:25 PM Christoph Hellwig wrote: > On Wed, Apr 02, 2003 at 10:36:03AM -0600, Steven Munroe wrote: > >>Has anyone run LTP against nptl recently? >> >>The ltp-20030324 version compile of trace_sched.c fails because >>PTHREAD_THREADS_MAX is not defined. Linuxthreads defines this in >>/sysdeps/unix/sysv/linux/bits/local_lim.h >> >>Should nptl define this (or similar) symbol? Or should this sort of thing be >>defined only in kernel headers (include/linux/threads.h)? > > > nptl has no hardcoded thread limits, see tst-sysconf.c. The kernel > doesn't have a hardcoded number of threads (well, except PID_MAX) > aswell. Furthermore, Posix does not require PTHREAD_THREADS_MAX be defined; see http://www.opengroup.org/onlinepubs/007904975/basedefs/pthread.h.html Looks like LTP needs to change trace_sched.c to be more posix-compliant. - Dan -- Dan Kegel http://www.kegel.com http://counter.li.org/cgi-bin/runscript/display-person.cgi?user=78045 ------------------------------------------------------- This SF.net email is sponsored by: ValueWeb: Dedicated Hosting for just $79/mo with 500 GB of bandwidth! No other company gives more support or power for your dedicated server http://click.atdmt.com/AFF/go/sdnxxaff00300020aff/direct/01/ _______________________________________________ Ltp-list mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/ltp-list