summaryrefslogtreecommitdiffstats
path: root/lib/libc_r
Commit message (Collapse)AuthorAgeFilesLines
...
* libc/${MACHINE_ARCH} include directory is required by Alpha,kan2003-07-021-1/+1
| | | | add it to CFLAGS.
* Axe AINC.ru2003-07-011-1/+0
| | | | Submitted by: bde
* Sanity check fd before using it as an array index.netchild2003-06-091-1/+2
| | | | | Noticed by: ted@NLnetLabs.nl (Ted Lindgreen) Approved by: ru
* The .Fn functioncharnier2003-06-081-3/+6
|
* Make this compile without warnings on 64-bit architectures:marcel2003-06-041-6/+7
| | | | | Don't cast thread_self() to int. Cast to uintptr_t. Pull in the predefined printf format from <inttypes.h>
* Make this compile without warnings on 64-bit architectures:marcel2003-06-041-1/+1
| | | | | In recurse(), cast the pointer difference to int to match the format. The difference is expected to fit in an int.
* If the library is not able to create a thread because resourcesmtm2003-06-041-0/+4
| | | | | | don't allow it at the moment, the correct thing to do is try again. Otherwise, libthr would fail this test because it doesn't allow an unlimited number of concurrent threads per application.
* Update for amd64 after repocopy from i386/peter2003-06-021-2/+1
|
* Port libc_r to amd64, and turn it back on for amd64. It passes all ofpeter2003-06-021-0/+18
| | | | the same src/lib/libc_r/test/* tests that the other platforms pass.
* Revert accidental change: don't change the thread library for testing torwatson2003-06-021-1/+1
| | | | | | libthr. Oops, sorry about that. Submitted by: "Simon L. Nielsen" <simon@nitro.dk>
* Include string.h for memset().rwatson2003-06-012-1/+2
|
* Fixed another bug in the threaded close() call; clear theru2003-05-311-0/+4
| | | | | | | | | stale stdio descriptors flags. PR: bin/51535 Submitted by: Enache Adrian <enache@rdslink.ro> Reviewed by: deischen Approved by: re (scottl)
* If an application closes one of its stdio descriptors (0..2),ru2003-05-311-2/+4
| | | | | | | | | | | | | | | | | an excessive close() on one of these descriptors would cause a memory for this descriptor to be allocated in the internal descriptor table. When this descriptor gets used again, e.g. through the call to open() or socket(), the descriptor would be erroneously left in the blocking mode, and the whole application would get stuck on a blocking operation, e.g., in accept(2). Prevent this bug from happening by disallowing close() against non-active descriptors (return -1 and set errno to EBADF in this case). Reviewed by: deischen Approved by: re (scottl)
* mdoc(7) fixes.ru2003-05-241-19/+27
| | | | Approved by: re (blanket)
* Add stub implementations of pthread_[gs]etconcurrency to libc_r andjdp2003-04-204-0/+170
| | | | | | | | | libthr. No changes were made to libpthread by request of deischen, who will soon commit a real implementation for that library. PR: standards/50848 Submitted by: Sergey A. Osokin <osa@freebsd.org.ru> MFC after: 1 week
* - Define a _spinunlock() function so that threading implementations may dojeff2003-03-261-0/+6
| | | | | | more complicated things than just setting the lock to 0. - Implement stubs for this function in libc and the two threading libraries that are currently in the tree.
* The .Fn function. Use .Xr where appropriate.charnier2003-03-2431-73/+139
|
* Fix threaded applications on ia64 that are linked dynamicly. We didmarcel2003-03-051-0/+1
| | | | | | | | | | | | | | | | | not save (restore) the global pointer (GP) in the jmpbuf in setjmp (longjmp) because it's not needed in general. GP is considered a scratch register at callsites and hence is always restored after a call (when it's possible that the call resolves to a symbol in a different loadmodule; otherwise GP does not have to be saved and restored at all), including calls to setjmp/longjmp. There's just one problem with this now that we use setjmp/longjmp for context switching: A new context must have GP defined properly for the thread's entry point. This means that we need to put GP in the jmpbuf and consequently that we have to restore is in longjmp. This automaticly requires us to save it as well. When setjmp/longjmp isn't used for context switching, this can be reverted again.
* Don't cast an int to a pointer type without (possibly) widening themarcel2003-03-051-1/+1
| | | | | | | | | | | integral type to the size of a pointer type when it's known that the cast is valid. On ia64 such casts are generally bad news and has led us (=peter :-) to make such casts fatal. By casting to intptr_t before casting to a pointer type, this now compiles cleanly in LP64 architectures. Note that the final cast has been changed to void* (instead of siginfo_t*) to make it explicit that we're not trying to pass a siginfo_t pointer but rather trying to pass an int when the prototype says it should be a pointer.
* Fixed a typo in MLINKS.ru2003-02-241-1/+1
|
* mdoc(7) police: Scheduled sweep.ru2003-02-2413-154/+124
|
* Enable just committed manual pages, update MLINKSphantom2003-02-131-0/+13
|
* Add AUTHORS sectionphantom2003-02-131-0/+6
|
* Finally! Document all undocumented functions in libc_r.phantom2003-02-1310-0/+696
| | | | | | | | | | | | | | | | | | | | Add manual pages for following functions: . pthread_attr_setcreatesuspend_np(3) . pthread_main_np(3) . pthread_multi_np(3) . pthread_single_np(3) . pthread_mutexattr_getkind_np(3) . pthread_mutexattr_setkind_np(3) . pthread_resume_all_np(3) . pthread_resume_np(3) . pthread_set_name_np(3) . pthread_suspend_all_np(3) . pthread_suspend_np(3) . pthread_switch_add_np(3) . pthread_switch_delete_np(3) MFC after: 3 days
* Break important implementation detail note into IMPLEMENTATION DETAILSphantom2003-02-131-3/+7
| | | | | | section. Add cross reference to pthread_attr_getstack() function. MFC after: 1 day
* Add cross reference for pthread_attr_get_np()phantom2003-02-131-0/+1
|
* Rehash MLINKS: add missing ones for recently added pthread_attr_{get,set}stack()phantom2003-02-131-3/+2
| | | | functions and remove links for 3 non-existent functions
* Actually link in the attr_{set,get}stack.alfred2003-02-111-0/+2
|
* Add pthread_attr_getstack() and pthread_attr_setstack().alfred2003-02-103-0/+125
| | | | Submitted by: Craig Rodrigues <rodrigc@attbi.com>
* The .Fn functioncharnier2003-02-0611-29/+58
|
* Document additional behaviour of this function (seephantom2003-02-031-2/+12
| | | | rev 1.3 of uthread_attr_get_np.c)
* Improve pthread_attr_get_np() by enabling it to return thread's real stackphantom2003-02-031-1/+9
| | | | | | address instead of specified by pthread_attr_t passed to pthread_create(). Suggested by: deischen
* remove #ifdef _THREAD_SAFEfjoe2003-01-241-2/+0
|
* Add a missing word.tjr2003-01-151-1/+1
|
* Document the named semaphore functions. This could still use a bittjr2003-01-151-18/+165
| | | | of polishing.
* Back out previous; sharing semaphores between processes only workstjr2003-01-141-8/+16
| | | | in certain special cases.
* Sharing semaphores between processes works now, so remove the stale commentstjr2003-01-141-16/+8
| | | | | about it always returning EPERM. Document that ENFILE occurs when the limit on kernel semaphores is reached.
* Cross reference sem(4) so users know which kernel options are requiredtjr2003-01-145-5/+10
| | | | to use these semaphore functions.
* Increase the scheduler stack to 4 pages. This should prevent a stackdeischen2003-01-111-1/+1
| | | | | | overflow when dumping thread info (generated by receipt of SIGINFO). Reported by: jmallet
* pthread_attr_get_np() now takes 'pthread_t' (not 'pthread_t *')fjoe2003-01-072-9/+8
| | | | to be consistent with other pthread_XXX functions
* Port libc_r to ia64. We need to do things slightly differentmarcel2003-01-064-0/+44
| | | | | | | | | | | because we have 2 stacks per thread: the regular downward memory stack and the irregular upward register stack. This implementation lets both stacks grow toward each other. An alternative scheme is to have them grow away from each other. The alternate scheme has the advantage that both stack grow toward guard pages. Since libc_r is virtually dead and we really want the *context stuff for thread switching, we don't try to be perfect, just functional.
* Add MD definitions for sparc64. This is based on work by des.tmm2003-01-051-0/+29
|
* Add an implementation of _atomic_lock for sparc64. This was submitted bytmm2003-01-051-0/+45
| | | | | des; I tweaked it slightly by extending the membar and making it match the style of the rest of the sparc64 assembler code.
* Fix typos in comment.deischen2002-12-281-2/+2
| | | | Submitted by: Craig Rodrigues <rodrigc@attbi.com>
* english(4) police.schweikh2002-12-273-3/+3
|
* mdoc(7) police: Deal with self-xrefs.ru2002-12-242-4/+5
|
* Make accept(), connect(), recvfrom(), recvmsg(), sendmsg(),ru2002-12-196-6/+80
| | | | | | and sendto() cancelation points, as required by POSIX.1-2001. Reviewed by: deischen
* mdoc(7) police: overhaul.ru2002-12-091-12/+12
|
* Implement the lock with a cmpxchg instruction instead of a xchg.marcel2002-11-161-2/+3
| | | | | | | | | | Both are atomic, but the cmpxchg has memory ordering hints. We give this acquire semantics. NOTE: The unlock in libc_r is implemented by a "normal" assign statement. This is not correct on ia64 due to the memory ordering characteristics of the architecture. We need release semantics for an unlock.
* When about to do an execve(), don't reset the O_NONBLOCK flag on any filearchie2002-11-151-0/+4
| | | | | | | | | descriptors that have the close-on-exec flag set, as that will have no effect anyway and might screw something else up if the file descriptor happens to be shared with another process. PR: standards/43335 MFC after: 1 week
OpenPOWER on IntegriCloud