|
|
|
usdumplock(3p) -- dump out information about a specific lock
|
|
usdumplock dumps information about lock in a readable form. This information is written to the file descriptor given by fd. The information printed includes where in memory the lock resides, whether it is locked or free, and the metering and debugging information (see usctllock(3P)). The argument str is simply printed as a string, and can be used to aid in identifying where usdumplock was called from.... |
|
usdumpsema(3p) -- dump out information about a specific semaphore
|
|
usdumpsema dumps information about sema in a readable form. This information is written to the file descriptor given by fd. The information printed includes where in memory the semaphore resides, what its count is, and the metering and debugging information (see usctlsema(3P)). The argument str is simply printed as a string, and can be used to aid in identifying where usdumpsema was called from. |
|
|
perl5/User::grent(3) -- by-name interface to Perl's built-in getgr*() functions
|
|
This module's default exports override the core getgrent(), getgruid(), and getgrnam() functions, replacing them with versions that return "User::grent" objects. This object has methods that return the similarly named structure field name from the C's passwd structure from grp.h; namely name, passwd, gid, and members (not mem). The first three return scalars, the last an array reference. You may also import all the structure fields directly into your namespace as regular variables using the ... |
|
perl5/User::pwent(3) -- by-name interface to Perl's built-in getpw*() functions
|
|
This module's default exports override the core getpwent(), getpwuid(), and getpwnam() functions, replacing them with versions that return "User::pwent" objects. This object has methods that return the similarly named structure field name from the C's passwd structure from pwd.h; namely name, passwd, uid, gid, quota, comment, gecos, dir, and shell. You may also import all the structure fields directly into your namespace as regular variables using the :FIELDS import tag. (Note that this stil... |
|
usfreelock(3p) -- free a lock
|
|
usfreelock frees all memory associated with the lock specified by lock. usfreelock will cause unpredictable results if lock is not a valid lock. |
|
usfreepollsema(3p) -- free a pollable semaphore
|
|
usfreepollsema frees the previously allocated pollable semaphore (via usnewpollsema(3P)) specified by sema. Before freeing a pollable semaphore all the file descriptors acquired for the semaphore must be closed. For processes in a single share group, all of which are sharing file descriptors, if one process calls usclospollsema(3P), all the file descriptors for all processes will be closed. If there are processes in the share group that are not sharing f... |
|
usfreesema(3p) -- free a semaphore
|
|
usfreesema frees the previously allocated semaphore (via usnewsema(3P)) specified by sema. Semaphores allocated via usnewpollsema(3P) should be freed using usfreespollsema(3P). |
|
usgetinfo(3p) -- exchange information though an arena
|
|
When unrelated processes decide to share an arena, it is often useful to be able to initially communicate the location of various data structures within the arena. A single word (doubleword in 64 bit mode) communication area is available inside the arena header block, accessible via the functions usgetinfo and usputinfo. Thus, a process that sets up the arena can initialize various locks, semaphores, and common data structures, and place a single pointer that any process that joins the arena can... |
|
usinit(3p) -- shared arena initialization
|
|
usinit is used to initialize a shared arena from which related or unrelated processes may allocate and share semaphores, locks and memory. Locks, semaphores and memory can then be allocated using the usptr_t returned by usinit. More than one call can be made to usinit to create separate arenas of locks and semaphores. In fact, calls to usinit may be made on behalf of a process: when sproc(2) is called, an aren... |
|
usinitlock(3p) -- initializes a lock
|
|
usinitlock initializes the lock specified by lock. All previous information associated with the lock (metering, debugging) is reinitialized. usinitlock should only be used for previously allocated locks. Locks are allocated using usnewlock(3P). usinitlock will cause unpredictable results if lock does not point to a valid lock. |
|
usinitsema(3p) -- initialize a semaphore
|
|
usinitsema initializes the semaphore specified by sema. The count of the semaphore is set to the value specified by val. A value of 0 implies no available resources, and the first process that attempts a 'P' operation (via uspsema) will block. This can be viewed as a synchronizing semaphore, since the goal is to always have a process block until another has completed an operation that the first process requires. Positive values for val can be used for tracking a collection of resources. The si... |
|
usleep(3c) -- suspend execution for an interval
|
|
The usleep() function suspends the current thread from execution for the number of microseconds specified by the seconds argument. Because of other activity, or because of the time spent in processing the call, the actual suspension time may be longer than the amount of time specified. The seconds argument must be less than 1,000,000. If the value of seconds is 0, the call has no effect. The usleep() function uses the high resolution sleep function: nanosleep() to suspend execution of a thread.... |
|
usmalloc(3p) -- shared arena memory allocator
|
|
These routines provide a simple general-purpose memory allocation package that allows the user to allocate from a shared arena (see usinit(3P)). All these functions are MP safe, multiple threads/processes may access them simultaneously and are guaranteed correct behavior. More than one call can be made to usinit(3P) to set up separate malloc arenas. The file name passed to usinit(3P) is used as a key to allow shared arenas to be created for use amongst unrelated processes. Once the arena is set ... |
|
usnewlock(3p) -- allocate and initialize a lock
|
|
usnewlock allocates a lock from the arena designated by handle (returned from usinit(3P)) and initializes it and all associated data. There are different types of locks; by default the fastest lock type for the class of machine the process is running on is allocated. See usconfig(3P) for other specifiable lock types. Metering and debugging are only enabled if the locks are of the debugging type (see usconfig(3P). There is a limit of a maximum of 4096 locks per shared area (for hardware supported... |
|
usnewpollsema(3p) -- allocate and initialize a pollable semaphore
|
|
usnewpollsema allocates a semaphore and initializes its count to the value specified by val. Initially, metering and debugging are off (and can be turned on through a call to usctlsema(3P)) and the history logging mechanism is set according to the global setting (see usconfig(3P)). The semaphore is allocated from the shared arena designated by handle as returned from usinit(3P). Pollable semaphores never block the caller. If the semaphore is unavailable when uspsema(3P) is called, the caller is ... |