mini-VFS
loadable threads.

Threaded RPC
threaded Newsreader.

Things to Thread
Emacs
Perl
Gnu C
finger

do signals.


pthread_attr functions, alarms

-----------------------------------------------------------------
ARCH	: OS	: VER		:Location			:Done	: Date	: VER	:
-----------------------------------------------------------------
i386	:FreeBSD: 1.1		:freefall.cdrom.com	: Yes	: 931111: 
i386	:FreeBSD: 2.0		:					: Yes	: 		: 
i386	:NetBSD	: 0.9		:sunlamp.cs.berkele.: Yes	: 931111:
i386	:NetBSD	: 1.0		:					: Yes	: 		:
i386	:Linux	: 1.0		:sipb.mit.edu		: Yes	: 940129:
i386	:Linux	: 1.1		:					: Yes	: 		:
i386	:BSDi	: 1.1		:sipb.mit.edu		: Yes	: 
r2000	:Ultrix	: 4.2		:sipb.mit.edu		: Yes	: 931111:
sparc	:Solaris: 2.3		:					: Yes	:		:
sparc	:SunOS	: 4.1.3		:sipb.mit.edu		: Yes	: 940321:
hppa	:HP-UX	: 9.0		:sipb.mit.edu		: Yes	: 940321:
alpha	:OSF	: 1.0		:					: Yes	:

mc68020	:NetBSD	: 0.9		:					: No	:		:

IBMRT	:BSD	: 4.3		:sipb.mit.edu		: Yes	: 931111:



Here is a list of functions and what needs to be done to them:
-----------------------------------------------------------------
POSIX1						:Location	:Is M T	: Done	: Date	:
-----------------------------------------------------------------
TERMINAL
cfgetispeed
cfgetospeed
cfsetispeed
cfsetospeed
ctermid
isatty						:c			: Yes	: Yes	: ------:
ttyname						:pthread	: Maybe	: Yes	: 940415: 
tcdrain
tcflow
tcflush
tcgetattr
tcgetpgrp
tcsendbreak
tcsetattr
tcsetpgrp

MATH
abs							:c			: Yes	: Yes	: ------:
acos						:c			: Yes	: Yes	: ------:
asin						:c			: Yes	: Yes	: ------:
atan						:c			: Yes	: Yes	: ------:
atan2						:c			: Yes	: Yes	: ------:
ceil						:c			: Yes	: Yes	: ------:
cos							:c			: Yes	: Yes	: ------:
cosh						:c			: Yes	: Yes	: ------:
div 						:c			: Yes	: Yes	: ------:
exp 						:c			: Yes	: Yes	: ------:
fabs 						:c			: Yes	: Yes	: ------:
floor 						:c			: Yes	: Yes	: ------:
fmod 						:c			: Yes	: Yes	: ------:
frexp 						:c			: Yes	: Yes	: ------:
labs 						:c			: Yes	: Yes	: ------:
ldexp 						:c			: Yes	: Yes	: ------:
ldiv 						:c			: Yes	: Yes	: ------:
log							:c			: Yes	: Yes	: ------:
log10						:c			: Yes	: Yes	: ------:
modf						:c			: Yes	: Yes	: ------:
pow							:c			: Yes	: Yes	: ------:
sin							:c			: Yes	: Yes	: ------:
sinh						:c			: Yes	: Yes	: ------:
sqrt						:c			: Yes	: Yes	: ------:
tan							:c			: Yes	: Yes	: ------:
tanh						:c			: Yes	: Yes	: ------:

STRING
atof						:c			: Yes	: Yes	: ------:
atoi						:c			: Yes	: Yes	: ------:
atol						:c			: Yes	: Yes	: ------:
isalnum						:c			: Yes	: Yes	: ------:
isalpha						:c			: Yes	: Yes	: ------:
iscntrl						:c			: Yes	: Yes	: ------:
isdigit						:c			: Yes	: Yes	: ------:
isgraph						:c			: Yes	: Yes	: ------:
islower						:c			: Yes	: Yes	: ------:
isprint						:c			: Yes	: Yes	: ------:
ispunct						:c			: Yes	: Yes	: ------:
isspace						:c			: Yes	: Yes	: ------:
isupper						:c			: Yes	: Yes	: ------:
isxdigit					:c			: Yes	: Yes	: ------:
strcat						:c			: Yes	: Yes	: ------:
strchr						:c			: Yes	: Yes	: ------:
strcmp						:c			: Yes	: Yes	: ------:
strcoll
strcpy						:c			: Yes	: Yes	: ------:
strcspn
strlen						:c			: Yes	: Yes	: ------:
strncat						:c			: Yes	: Yes	: ------:
strncmp						:c			: Yes	: Yes	: ------:
strncpy						:c			: Yes	: Yes	: ------:
strpbrk
strrchr						:c			: Yes	: Yes	: ------:
strspn
strstr
strtod						:c			: Yes	: Yes	: ------:
strtok
strtol						:c			: Yes	: Yes	: ------:
strtoul						:c			: Yes	: Yes	: ------:
strxfrm
tolower						:c			: Yes	: Yes	: ------:
toupper						:c			: Yes	: Yes	: ------:

MEMORY
calloc						:c			: Yes	: Yes	: ------:
free						:pthread	: Yes	: Yes	: 931111:
malloc						:pthread	: Yes	: Yes	: 931111:
memchr						:c			: Yes	: Yes	: ------:
memcpy						:c			: Yes	: Yes	: ------:
memmove						
memset						:c			: Yes	: Yes	: ------:
realloc						:pthread	: Yes	: Yes	: 931111:

STDIO
fclose						:pthread	: Yes	: Yes	: 940108:
fdopen						:pthread	: Yes	: Yes	: 940108:
feof						:pthread	: Yes	: Yes	: 940108:
ferror						:pthread	: Yes	: Yes	: 940108:
fflush						:pthread	: Yes	: Yes	: 940108:
fgetc						:pthread	: Yes	: Yes	: 940108:
fgetpos						:pthread	: Yes	: Yes	: 940108:
fgets						:pthread	: Yes	: Yes	: 940108:
fileno						:pthread	: Yes	: Yes	: 940108:
fopen						:pthread	: Yes	: Yes	: 940108:
fprintf						:pthread	: Yes	: Yes	: 940108:
fputc						:pthread	: Yes	: Yes	: 940108:
fputs						:pthread	: Yes	: Yes	: 940108:
fread						:pthread	: Yes	: Yes	: 940108:
freopen						:pthread	: Yes	: Yes	: 940108:
fscanf						:pthread	: Yes	: Yes	: 940108:
fseek						:pthread	: Yes	: Yes	: 940108:
fsetpos						:pthread	: Yes	: Yes	: 940108:
fwrite						:pthread	: Yes	: Yes	: 940108:
getc						:pthread	: Yes	: Yes	: 940108:
getchar						:pthread	: Yes	: Yes	: 940108:
gets						:pthread	: Yes	: Yes	: 940108:
perror						:pthread	: Yes	: Yes	: 940108:
printf						:pthread	: Yes	: Yes	: 940108:
putc						:pthread	: Yes	: Yes	: 940108:
putchar						:pthread	: Yes	: Yes	: 940108:
puts						:pthread	: Yes	: Yes	: 940108:
rewind						:pthread	: Yes	: Yes	: 940108:
scanf						:pthread	: Yes	: Yes	: 940108:
setbuf						:pthread	: Yes	: Yes	: 940108:
setvbuf						:pthread	: Yes	: Yes	: 940108:
sprintf						:pthread	: Yes	: Yes	: 940108:
sscanf						:pthread	: Yes	: Yes	: 940108:
strerror					:pthread	: Yes	: Yes	: 940108:
ungetc						:pthread	: Yes	: Yes	: 940108:
vfprintf					:pthread	: Yes	: Yes	: 940108:
vprintf						:pthread	: Yes	: Yes	: 940108:
vsprintf					:pthread	: Yes	: Yes	: 940108:

TIME
asctime						:pthread	: Yes	: Yes	: 940902:
ctime						:pthread	: Yes	: Yes	: 940902:
difftime					:pthread	: Yes	: Yes	: 940902:
gmtime						:pthread	: Yes	: Yes	: 940902:
localtime					:pthread	: Yes	: Yes	: 940902:
mktime						:pthread	: Yes	: Yes	: 940902:
time						:pthread	: Yes	: Yes	: 940901:
tzset						:pthread	: Yes	: Yes	: 940902:

abort
alarm
assert						:c			: Yes	: Yes	: ------:
atexit
bsearch
clearerr
clock
cuserid
execl
execle
execlp
execv
execvp
fpathconf
getcwd
getegid
getenv
geteuid
getgid
getgrgid
getgrnam
getgroups
getlogin
getpgrp
getpid
getppid
getpwnam
getpwuid
getuid
kill
link
localeconv
mblen
mbstowcs
mbtowc
mkdir
mkfifo
pathconf
qsort
remove
rmdir
setgid
setlocale
setpgid
setsid
setuid
strftime
sysconf
system
times
tmpfile
tmpnam
umask
uname
unlink
utime
va_arg
va_end
va_start
wcstombs
wctomb

Process Creation/Termination
execve						:pthread	: Yes	: Yes	: 940418:
exit						:pthread	: Yes	: Yes	: 940905:
_exit						:pthread	: Yes	: Yes	: 940905:
fork						:pthread	: Yes	: Yes	: 940418:
wait						:pthread	: Yes	: Yes	: 940614:
waitpid						:pthread	: Yes	: Yes	: 940614:

Signals
raise
sigaction
sigaddset					:c			: Yes	: Yes	: 941018:
sigdelset					:c          : Yes   : Yes   : 941018:
sigemptyset					:c          : Yes   : Yes   : 941018:
sigfillset					:c          : Yes   : Yes   : 941018:
sigismember					:c          : Yes   : Yes   : 941018:
signal
sigpending
sigprocmask					:pthread	: Yes	: Yes	: 941018:
sigsuspend

Random Numbers
rand						:pthread	: Yes	: Yes	: 940908:
srand						:pthread	: Yes	: Yes	: 940908:

Other Special Routines
longjmp
pause
setjmp
siglongjmp
sigsetjmp
sleep						:pthread	: Yes	: Yes	: 940108:

DIR Routines
closedir					:pthread	: Yes	: Yes	: 940513:
opendir						:pthread	: Yes	: Yes	: 940513:
readdir						:pthread	: Yes	: Yes	: 940513:
rewinddir					:pthread	: Yes	: Yes	: 940513:

File Routines
access						:c			: Yes	: Yes	: ------:
chdir						:pthread	: Yes	: Yes	: 940729:
chmod						:pthread	: Yes	: Yes	: 940729:
chown						:pthread	: Yes	: Yes	: 940729:
rename						:pthread	: Yes	: Yes	: 940805:
stat						:pthread    : Yes   : Yes   : 940729:

FD Routines
close						:pthread	: Yes	: Yes	: 931111:
creat						:pthread	: Yes	: Yes	: 940730:
dup  						:pthread	: Yes	: Yes	: 931111:
dup2						:pthread	: Yes	: Yes	: 931111:
fcntl
fstat						:pthread	: Yes	: Yes	: 940512:
ftell
lseek						:pthread	: Yes	: Yes	: 940108:
open						:pthread	: Yes	: Yes	: 931111:
pipe						:pthread	: Yes	: Yes	: 940421:
read						:pthread	: Yes	: Yes	: 931111:
write						:pthread	: Yes	: Yes	: 931111:

Berkeley Sockets
accept						:pthread	: Yes	: Yes	: 931111:
bind						:pthread	: Yes	: Yes	: 931111:
connect						:pthread	: Yes	: Yes	: 931111:
listen						:pthread	: Yes	: Yes	: 931111:
readv						:pthread	: Yes	: Yes	: 940108:
recv						:pthread	: Yes	: Yes	: 940321:
recvfrom					:pthread	: Yes	: Yes	: 940321:
recvmsg						:pthread	: Yes	: Yes	: 940730:
send						:pthread	: Yes	: Yes	: 940321:
sendto						:pthread	: Yes	: Yes	: 940321:
sendmsg						:pthread	: Yes	: Yes	: 940730:
socket						:pthread	: Yes	: Yes	: 931111:
shutdown					:pthread	: Yes	: Yes	: 940807:
writev						:pthread	: Yes	: Yes	: 940108:
select						:pthread	: Yes	: Yes	: 941113:

Other Non POSIX Functions
fchown						:pthread	: Yes	: Yes	: 940729:
fchmod						:pthread	: Yes	: Yes	: 940729:
popen						:pthread	: Yes	: Yes	: 940621:
pclose						:pthread	: Yes	: Yes	: 940621:
usleep						:pthread	: Yes	: Yes	: 940805:
wait3						:pthread	: Yes	: Yes	: 940614:
random						:pthread	: Yes	: Yes	: 940918:
srandom						:pthread	: Yes	: Yes	: 940918:
initstate					:pthread	: Yes	: Yes	: 940918:
setstate					:pthread	: Yes	: Yes	: 940918:

-----------------------------------------------------------------
POSIX1a 					:Location			:Done	: Date	:
-----------------------------------------------------------------
getopt						:pthread	: No	: Yes	: 940515:

-----------------------------------------------------------------
POSIX4 D11					:Location			:Done	: Date	:
-----------------------------------------------------------------
nanosleep					:pthread	: Yes	: Yes	: 940805:

-----------------------------------------------------------------
POSIX4aD7					:Location			:Done	: Date	:
-----------------------------------------------------------------
flockfile					:pthread			: Yes	: 931111:
ftrylockfile				:pthread			: Yes	: 931111:
funlockfile					:pthread			: Yes	: 931111:
getc_unlocked				:pthread			: Yes	: 931111:
getchar_unlocked			:pthread			: Yes	: 931111:
putc_unlocked				:pthread			: Yes	: 931111:
putchar_unlocked			:pthread			: Yes	: 931111:
pthread_attr_init			:pthread			: Yes	: 940327:
pthread_attr_destroy		:pthread			: Yes	: 940327:
pthread_attr_setstacksize	:pthread			: Yes	: 940327:
pthread_attr_getstacksize	:pthread			: Yes	: 940327:
pthread_attr_setstackaddr	:pthread			: Yes	: 940327:
pthread_attr_getstackaddr	:pthread			: Yes	: 940327:
pthread_attr_setdetachstate	:pthread			: Yes	: 940327:
pthread_attr_getdetachstate	:pthread			: Yes	: 940327:
pthread_cond_broadcast		:pthread			: Yes	: 931111:
pthread_cond_destroy		:pthread			: Yes	: 931111:
pthread_cond_init			:pthread			: Yes	: 931111:
pthread_cond_signal			:pthread			: Yes	: 931111:
pthread_cond_wait			:pthread			: Yes	: 931111:
pthread_create				:pthread			: Yes	: 931111:
pthread_mutex_destroy		:pthread			: Yes	: 931111:
pthread_mutex_init			:pthread			: Yes	: 931111:
pthread_mutex_lock			:pthread			: Yes	: 931111:
pthread_mutex_trylock		:pthread			: Yes	: 931111:
pthread_mutex_unlock		:pthread			: Yes	: 931111:
pthread_exit				:pthread			: Yes	: 931111:
pthread_once				:pthread			: Yes	: 931213:
pthread_self				:pthread			: Yes	: 931111:
pthread_join				:pthread			: Yes	: 940117:
pthread_detach				:pthread			: Yes	: 940117:

-----------------------------------------------------------------
POSIX4aD8					:Location			:Done	: Date	:
-----------------------------------------------------------------
flockfile					:pthread			: Yes	: 931111:
ftrylockfile				:pthread			: Yes	: 931111:
funlockfile					:pthread			: Yes	: 931111:
getc_unlocked				:pthread			: Yes	: 931111:
getchar_unlocked			:pthread			: Yes	: 931111:
putc_unlocked				:pthread			: Yes	: 931111:
putchar_unlocked			:pthread			: Yes	: 931111:
sigwait						:pthread			: Yes	: 941018:
pthread_attr_destroy		:pthread			: Yes	: 940327:
pthread_attr_getinheritsched:pthread			: Yes	: 940905:
pthread_attr_getschedparam	:pthread			: Yes	: 941004:
pthread_attr_getschedpolicy	:pthread			: Yes	: 940905:
pthread_attr_getscope		:pthread			: Yes	: 940905:
pthread_attr_getstackaddr	:pthread			: Yes	: 940327:
pthread_attr_getstacksize	:pthread			: Yes	: 940327:
pthread_attr_getdetachstate	:pthread			: Yes	: 940327:
pthread_attr_init			:pthread			: Yes	: 940327:
pthread_attr_setinheritsched:pthread			: Yes	: 940905:
pthread_attr_setschedparam	:pthread			: Yes	: 941004:
pthread_attr_setschedpolicy	:pthread			: Yes	: 940905:
pthread_attr_setscope		:pthread			: Yes	: 940905:
pthread_attr_setstackaddr	:pthread			: Yes	: 940327:
pthread_attr_setstacksize	:pthread			: Yes	: 940327:
pthread_attr_setdetachstate	:pthread			: Yes	: 940327:
pthread_cleanup_push		:pthread			: Yes	: 940327:
pthread_cleanup_pop			:pthread			: Yes	: 940327:
pthread_conattr_destroy
pthread_conattr_init
pthread_cond_broadcast		:pthread			: Yes	: 931111:
pthread_cond_destroy		:pthread			: Yes	: 931111:
pthread_cond_init			:pthread			: Yes	: 940404:
pthread_cond_signal			:pthread			: Yes	: 931111:
pthread_cond_timedwait		:pthread			: Yes	: 940606:
pthread_cond_wait			:pthread			: Yes	: 931111:
pthread_create				:pthread			: Yes	: 931111:
pthread_equal				:pthread			: Yes	: 931111:
pthread_exit				:pthread			: Yes	: 931111:
pthread_getschedparam		:pthread			: Yes	: 940615:
pthread_getspecific			:pthread			: Yes	: 940404:
pthread_join				:pthread			: Yes	: 940117:
pthread_key_create			:pthread			: Yes	: 940404:
pthread_key_delete			:pthread			: Yes	: 940404:
pthread_kill				:pthread			: Yes	: 941018:
pthread_mutexattr_destroy	:pthread			: Yes	: 941031:
pthread_mutexattr_getprioceiling
pthread_mutexattr_getprotocol
pthread_mutexattr_init		:pthread			: Yes	: 941031:
pthread_mutexattr_setprioceiling
pthread_mutexattr_setprotocol
pthread_mutex_destroy		:pthread			: Yes	: 931111:
pthread_mutex_getprioceiling
pthread_mutex_init			:pthread			: Yes	: 940404:
pthread_mutex_lock			:pthread			: Yes	: 931111:
pthread_mutex_setprioceiling
pthread_mutex_trylock		:pthread			: Yes	: 931111:
pthread_mutex_unlock		:pthread			: Yes	: 931111:
pthread_once				:pthread			: Yes	: 931213:
pthread_self				:pthread			: Yes	: 931111:
pthread_setschedparam		:pthread			: Yes	: 940615:
pthread_setcancelstate
pthread_setcanceltype
pthread_setspecific			:pthread			: Yes	: 940404:
pthread_sigmask				:pthread			: Yes	: 941103
pthread_testcancel
pthread_yield				:pthread			: Yes	: 931111:

readdir_r					:pthread	     	: Yes	: 940513:
asctime_r					:pthread	: Yes	: Yes	: 940902:
ctime_r						:pthread	: Yes	: Yes	: 940902:
gmtime_r					:pthread	: Yes	: Yes	: 940902:
localtime_r					:pthread	: Yes	: Yes	: 940902:
rand_r						:pthread	: Yes	: Yes	: 940908:
strtok_r

* <name>_r routines are provided as thread safe alternative
to the <name> routine. I have made the <anme> routine thread
safe also but only for the context of the thread calling
the routine. The static data used by the calling thread has
been changed to thread specific data and will be cleaned up
when that thread exits.

pthread_detach				:pthread			: Yes	: 940117:
pthread_attr_setcleanup		:pthread			: Yes	:

-------------------------------------------------------------
SUN RPC					:Location			:Done	: Date	:
-------------------------------------------------------------

-------------------------------------------------------------
X11 XLIB				:Location			:Done	: Date	:
-------------------------------------------------------------

-------------------------------------------------------------
Kerberos				:Location			:Done	: Date	:
-------------------------------------------------------------

-------------------------------------------------------------
More Things to do
stdio: Remove all tempnam functionality (it's already threadsafe)
alarms,
benchmarks,
pthread_init,
OSF compatability,
 break machdep.h into engine.h and machdep.h.
make posix.h a system dependent file NOT a machine dependent file.
getsockname
make util.h only be included if PTHREAD_KERNEL is defined

Things to do for 1.60
Make pthreads compatible with OSF DCE threads
X Break, FreeBSD and NetBSD into distinct systems
X priorities
X pthread_getschedparam, pthread_setschedparam (the rest)
Finish all calls in pthread/unistd.h
\ signals	 	( Half way there )
X sigwait, pthread_kill, sigprocmask

pthread_cancel and some more signal support.
The code Sean has worked on needs to be rolled into the current tree
		Sean: I've been busy so I haven't responded
The resolver code should be working and a test for ctime would be
		very useful.
Make install should be tested.

Things to do for Dave McCracken dcm@atrium.com
fix code to ....
X >
X > *     Application-specified non-blocking.  The IO management routines have
X >       no provision for an application that sets non-blocking mode on a file.

Error: perror seems to get a duplicate symbol strerror

Things for steven

Clean up code to compile cleaner
Check make install to see if it actually works.

Things to do for Greg

sigmask()
kernel threads()
X read_timedwait()
X write_timedwait()

Things to do for GNAT

> Good Morning from Vienna !
> 
> I am using gnat-1.79 under Linux and for the
> new feature of tasks in the 1.79 version the pthreads library is necessary.
> We have a pthreads library, which has already been ported to Linux,
> (pthreads-1.27.tar.gz from the internet)
> but if we try to link a gnat-Ada program including Ada-task
> the following symbols remain undefined.
> 
> clock_gettime
X > pthread_mutexattr_init
> pthread_mutexattr_setprotocol
> pthread_mutexattr_setprio_ceiling
X > pthread_cond_timedwait
> pthread_condattr_init
> pthread_condattr_destroy
X > pthread_attr_setprio
X > pthread_attr_getprio
X > pthread_setprio
X > pthread_setschedattr
X > pthread_getschedattr
X > sigwait
X > pthread_kill
> 
> My question is, if you know anything about these symbols.
> Maybe we use a old pthread library, or do other things wrong.
> 

Other than clock_gettime, these are routines that I need to implement,
although this is the first request for any of them. I'm not familiar 
with GNAT so I don't know what it expects. I don't know what clock_gettime 
is for. It is not a POSIX thread routine.

The most important routines are pthread_cond_timedwait, sigwait, and 
pthread_kill. The other routines could be created to return the correct
return value but not do any real work. This will effect performance
but (hopefully) functionality.

I plan to contact the GNAT maintainers and see what exactly they need
to resole this problem, but it might be a few weeks.

CAP

Things to do for Linux
kernel thread mulitplexer

Things to do for BSDI
kernel thread mulitplexer

Things to do for NetBSD
Roll latest version (1_50) into source tree
Redo Copyrights and RCS ID strings.
	Done stdio
Port code to mc68000 machine


Things to do for 3.0
	Dynamicaly loadable threads.


