Factbites
 Where results make sense
About us   |   Why use us?   |   Reviews   |   PR   |   Contact us  

Topic: Mutexes


In the News (Tue 16 Jul 19)

  
  Mutexes
In addition mutexes may be used internally by underlying code, for example the memory allocation package, so careful analysis of the whole system would be needed to be sure that priority inversion cannot occur.
Recursive mutexes allow a thread to make arbitrary changes to a data structure, then in a recursive call lock the mutex again while the data structure is still inconsistent.
Mutexes serve as a mutual exclusion mechanism between threads, and cannot be used to synchronize between threads and the interrupt handling subsystem.
ecos.sourceware.org /docs-latest/ref/kernel-mutexes.html   (2055 words)

  
  ./_Man_Solaris_2.6_html/html3t/mutex.3t.html
Mutexes can be used to synchronize threads between processes if the mutexes are allocated in writable memory and shared among the cooperating processes (see mmap.2 and have been initialized for this task.
Mutexes are either intra-process or inter-process, depending upon the argument passed implicitly or explicitly to the initialization of that mutex.
POSIX mutexes, threads, and condition variables use attributes objects in the same manner; they are initialized with the configuration of an attributes object (see pthread_mutexattr_init.3t The pthread_mutex_init() function initializes the mutex referenced by mp with attributes specified by attr.
www.cs.rit.edu /~hpb/Man/_Man_Solaris_2.6_html/html3t/mutex.3t.html   (1891 words)

  
 Concepts   (Site not responding. Last check: 2007-10-10)
In general a mutex object with an unspecified locking strategy is unsafe, and it requires programmer discipline to use the mutex object properly.
If the associated mutex object is already locked by some other thread, places the current thread in the Blocked state until the associated mutex is unlocked, after which the current thread is placed in the Ready state, eventually to be returned to the Running state.
If the associated mutex object is already locked by the same thread the behavior is dependent on the locking strategy of the associated mutex object.
www.boost.org /doc/html/threads/concepts.html   (1439 words)

  
 D. Kalinsky Associates - Whitepaper "Mutexes Battle Priority Inversions"
mutex is used to prevent Tasks C and D from running while Tasks A and B are competing for access to the printer.
Priority inheritance mutexes are prone to mutual deadlocks.
Mutexes are a specialized kind of semaphore designed to prevent unbounded priority inversions.
www.kalinskyassociates.com /Wpaper2.html   (3220 words)

  
 kernel - real-time multitasking kernel, embedded realtime kernel, mutex
Since the mutex knows its current owner, it is possible to promote the priority of the owner whenever a higher-priority task starts waiting on the mutex.
If the mutex ceiling is set to the priority of the highest task that can possibly get it, then inheritance is effectively disabled and the mutex operates purely in ceiling mode.
When releasing a mutex, the task priority is demoted to the greatest of: (1) the highest ceiling among remaining owned mutexes, (2) the highest waiting task priority among remaining owned mutexes with inheritance enabled, or (3) the task's normal priority, normpri.
www.smxinfo.com /articles/techppr/mutex.htm   (2917 words)

  
 The GNU C Library   (Site not responding. Last check: 2007-10-10)
A mutex is a MUTual EXclusion device, and is useful for protecting shared data structures from concurrent modifications, and implementing critical sections and monitors.
A thread attempting to lock a mutex that is already locked by another thread is suspended until the owning thread unlocks the mutex first.
This way, the status of mutexes at cancellation points is predictable, allowing cancellation handlers to unlock precisely those mutexes that need to be unlocked before the thread stops executing.
www.gnu.org /software/libc/manual/html_node/Mutexes.html   (801 words)

  
 locks
This constructs a mutex with default attributes (appropriate for the environment), and leaves the mutex in an unlocked state.
Otherwise the referenced mutex is locked in a manner defined appropriately for each lock (which may block execution of this thread).
Otherwise the referenced mutex is locked in a manner defined appropriately for each lock, but in a non-blocking manner that may not succeed.
home.twcny.rr.com /hinnant/cpp_extensions/threads_move.html   (3614 words)

  
 What is mutex? - A Word Definition From the Webopedia Computer Dictionary
In computer programming, a mutex is a program object that allows multiple program threads to share the same resource, such as file access, but not simultaneously.
The mutex is set to unlock when the data is no longer needed or the routine is finished.
MuTeX was written by Andrea Steinbach and Angelika Schofer, as a master's thesis at Rheinische Friedrich-Wilhelms University.
www.webopedia.com /TERM/M/mutex.html   (148 words)

  
 Unix man pages: PTHREAD_MUTEX (3)   (Site not responding. Last check: 2007-10-10)
If the mutex is of the ``fast'' kind, the calling thread is suspended until the mutex is unlocked, thus effectively causing the calling thread to deadlock.
If the mutex is of the ``recursive'' kind, pthread_mutex_lock succeeds and returns immediately, recording the number of times the calling thread has locked the mutex.
On ``error checking'' mutexes, pthread_mutex_unlock actu- ally checks at run-time that the mutex is locked on entrance, and that it was locked by the same thread that is now calling pthread_mutex_unlock.
www.security-protocols.com /unixmanpages/pthread_mutex_trylock.3.html   (822 words)

  
 Mutual exclusion - Wikipedia, the free encyclopedia
Mutual exclusion (often abbreviated to mutex) algorithms are used in concurrent programming to avoid the simultaneous use of a common resource, such as a global variable, by pieces of computer code called critical sections.
A mutex is also a common name for a program object that negotiates mutual exclusion among threads, also called a lock.
On a uniprocessor system the common way to achieve mutual exclusion is to disable interrupts for the smallest possible number of instructions that will prevent corruption of the shared data structure, the so-called "critical region".
en.wikipedia.org /wiki/Mutual_exclusion   (540 words)

  
 Mutexes | paulbridger.net
A mutex is an OS-level synchronisation primitive that can be used to ensure a section of code can only be executed by one thread at a time.
Furthermore, the mutex may only be unlocked by the thread that locked it.
If an exception were thrown while we had locked the mutex, the scoped_lock would be destroyed during the normal stack unwinding process and the mutex would be automatically freed.
paulbridger.net /mutexes   (429 words)

  
 Common threads: POSIX threads explained, Part 2
As soon as thread "b" releases the mutex (via a pthread_mutex_unlock() call), thread "a" will be able to lock the mutex (in other words, it will return from the pthread_mutex_lock() call with the mutex locked).
The data structure is in effect "frozen" until the mutex is unlocked.
Mutexes will insert a "memory barrier," which ensures that the writes to main memory occur in the order the threads lock the mutex.
www-106.ibm.com /developerworks/linux/library/l-posix2   (2715 words)

  
 UNIX man pages : mutex ()   (Site not responding. Last check: 2007-10-10)
Mutual exclusion locks (mutexes) prevent multiple threads from simultaneously executing critical sections of code which access shared data (that is, mutexes are used to seri- alize the execution of threads).
Initialization Mutexes are either intra-process or inter-process, depending upon the argument passed implicitly or explicitly to the initialization of that mutex.
Since the memory for such a mutex must be allocated dynamically, the mutex needs to be explicitly initialized with the appropri- ate attribute that indicates inter-process use.
www.cs.umbc.edu /cgi-bin/man-cgi?mutex   (634 words)

  
 Zaval.org -> Resources -> Library -> Recursive mutexes by David Butenhof
While recursive mutexes may seem a convenience for debugging, in fact it's the opposite -- you're better off with a "strict" debugging mutex (like the POSIX error-check attribute) that checks, tracks, and enforces ownership restrictions a "normal" mutex may ignore in favor of runtime efficiency.
And in particular the idea that one could support a range of potentiallyf useful and non-standard fundamental mutex behaviors without substantially complicating a simple and fast "inline lock" code path or invalidating basic POSIX semantics; that is, all the complication would be kept out of the main and common lock code.
Recursive mutexes can be a great tool for prototyping thread support in an existing library, exactly because it lets you defer the hard part: the call path and data dependency analysis of the library.
zaval.org /resources/library/butenhof1.html   (1656 words)

  
 CSMutx
The mutex version is only marginally slower in the background and can be faster than the CS version, in the background case, when the depth is low.
The relative performance of mutexes and critical sections is explained by the fact, stated earlier, that critical sections are first tested in user space.
Mutexes, and, by extension, events and semaphores, perform well even when a large number of threads are contending for them.
world.std.com /~jmhart/csmutx.htm   (4851 words)

  
 [No title]
Dynamic creation of mutexes can be implemented using a pre-allocated pool of mutex objects, involving some extra code to manipulate the pool and an additional configuration option to define the size of the pool.
An important issue for mutex locks is the handling of priority inversion, where a high priority thread is prevented from running because it needs a lock owned by a lower priority thread.
As a further complication, some mutexes may be hidden inside a component rather than being an explicit part of the application.
www.redhat.com /support/wpapers/cygnus_ecos/limits.html   (1087 words)

  
 POSIX Threads Programming
Mutexes: The second class of functions deal with synchronization, called a "mutex", which is an abbreviation for "mutual exclusion".
Mutex variables are one of the primary means of implementing thread synchronization and for protecting shared data when multiple writes occur.
If the mutex is already locked by another thread, this call will block the calling thread until the mutex is unlocked.
www.llnl.gov /computing/tutorials/pthreads   (5352 words)

  
 Info Node: (libc.info)Mutexes
None of the mutex functions is a cancellation point, not even `pthread_mutex_lock', in spite of the fact that it can suspend a thread for arbitrary durations.
If the mutex is of the "recursive" type, `pthread_mutex_lock' succeeds and returns immediately, recording the number of times the calling thread has locked the mutex.
On "error checking" mutexes, `pthread_mutex_unlock' actually checks at run-time that the mutex is locked on entrance, and that it was locked by the same thread that is now calling `pthread_mutex_unlock'.
mulliken.chem.hope.edu /cgi-bin/info2www.cgi?(libc)Mutexes   (1132 words)

  
 CA Security Advisor Center Glossary
Mutex is a program object that allows multiple threads to share the same resource.
The mutex is unlocked when it is no longer needed or the thread is terminated.
The difference between mutex and semaphore is that a mutex is owned by the thread which locked it (that is, only the process which locked the mutex can unlock it).
www3.ca.com /securityadvisor/glossary.aspx   (15653 words)

  
 SWI-Prolog 5.2.4 Reference Manual: Section 6.4
Mutexes are used to realise related updates to the Prolog database.
The predicate call_cleanup/[2-3] is another way to guarantee that the mutex is unlocked while retaining non-determinism.
As mutex_lock/1, but if the mutex is held by another thread, this predicates fails immediately.
www.brics.dk /~pdm/Prolog/Manual/threadsync.html   (422 words)

  
 Mutexes
Mutexes are used to help determine when a belief state is unreachable.
The mutexes are only used to improve our heuristics, so it is reasonable to compute only a subset of the mutexes.
A possible reason induced mutexes don't help as much in these domains is that all the actions have at most two effects, an unconditional and conditional effect.
www.cs.cmu.edu /afs/cs.cmu.edu/project/jair/pub/volume26/bryce06a-html/node26.html   (436 words)

  
 Portable Threads - Concepts and Abstractions   (Site not responding. Last check: 2007-10-10)
Threads, Mutexes, Condition Variables (CV), and Messages are the four data abstractions founding the package.
Do it before destroying their associated mutex, as this is not currently done automatically.
CV are not automagically destroyed upon the destruction of their associated mutex.
www.cs.brandeis.edu /~bruncott/PTL/threads_13.html   (430 words)

  
 Guidelines
mutex is reacquired before the interlock lock and no other mutexes may be held while blocked, this does not result in any lock order reversals due to the first property.
Sleep mutexes require a context in case they block, however, so sleep mutexes may not be used in interrupt handlers that do not run in a thread context.
Spin mutexes may also need to be used in non-interrupt contexts or in threaded interrupt handlers to protect data structures shared with non-threaded interrupt handlers.
www.usenix.org /events/bsdcon02/full_papers/baldwin/baldwin_html/node6.html   (1641 words)

  
 Mutexes
The Mutex class uses more system resources than the Monitor class, but it can be marshaled across application domain boundaries, it can be used with multiple waits, and it can be used to synchronize threads in different processes.
Mutexes have thread affinity; that is, the mutex can be released only by the thread that owns it.
Mutexes are of two types: local mutexes and named system mutexes.
msdn2.microsoft.com /en-us/library/hw29w7t1.aspx   (629 words)

  
 Mutexes SIG
The purpose of the Mutexes SIG is to provide a forum to discuss the strategy for solving the mutex conundrum in the Linux 2.6 kernel.
In the short term, it may be a combination of RT Mutex and FUSYN.
Sven Dietrich (sdietrich@mvista.com) is the organizing contact for the Mutexes SIG meeting at OLS.
developer.osdl.org /dev/mutexes   (301 words)

  
 LWN: Semaphores and mutexes
One problem had to do with performance; the mutex patch was supposed to be faster, but that was not the case in the posted version (which lacked architecture-specific implementations).
Ingo's mutexes are derived from the code used in the realtime preemption patch, of course, but they have been heavily modified to avoid the objections which greeted David's patch.
Hence even assuming that the mutex code does not bring direct code advantages (which i'm disputing :-), the mutex code is far simpler and thus easier to improve.
www.lwn.net /Articles/165039   (1163 words)

  
 ILU Reference Manual - Threads and Event Loops
ILU uses mutex and condition variables to organize its thread synchronization; mutexes are even used for the plan for how single-threaded code works.
Just after the mutex is acquired, the invariant is known to hold; it will continue to hold until the code holding the mutex changes variables involved in the invariant; such code must restore the invariant before releasing the mutex.
That is, a thread may enter mutex B while holding mutex A only if A < B (we have a few carefully managed exceptions to this rule, involving connection mutexes).
www2.parc.com /istl/projects/http-ng/ilu-sources/doc/manual_9.html   (2873 words)

  
 Migrate Win32 C/C++ application to Linux on POWER, Part 2: Mutexes
The error is not due to the locked mutex.
Mutexes are system-wide objects which multiple processes can see.
Mutexes have names, and only one mutex of a given name can exist on a machine at a time.
www-128.ibm.com /developerworks/eserver/library/es-win32linux.html   (1814 words)

  
 Linux Mutexes
Mutexes are a method used to be sure two threads, including the parent thread, do not attempt to access memory at the same time.
Mutexes ensure that memory accesses to the same memory are mutually exclusive.
Condition variables are used to convey information about the state of shared data which is associated with a mutex.
www.comptechdoc.org /os/linux/programming/c/linux_pgcmutex.html   (312 words)

  
 Replacing spinlocks by mutexes in the 'Premptible Linux Kernel'
The kernel patches presented hereafter can be downloaded (under the license GPL 2) and can be added to a Linux 2.4 Kernel, that has already been patched with the Preemptible Kernel Patch, in order to be able to serve time-critical processes with less latency and a higher predictability.
EVP2 is a mutex implementation with a priority inversion protocol which works fine, if every process holds not more than one mutex at the same time.
Both mutex protocol implementations are described in detail in the following extract of Dirk Grambow's diploma thesis (ID 17/2002) (pdf), (zipped Postscript), 2002, in German.
inf3-www.informatik.unibw-muenchen.de /research/linux/mutex   (756 words)

  
 mod_perl: APR::ThreadMutex - Perl API for APR thread mutexES
Destroy the mutex and free the memory associated with the lock.
If the mutex is already locked, the current thread will be put to sleep until the lock becomes available.
Use of the Camel for Perl is a trademark of O'Reilly and Associates, and is used by permission.
perl.apache.org /docs/2.0/api/APR/ThreadMutex.html   (250 words)

Try your search on: Qwika (all wikis)

Factbites
  About us   |   Why use us?   |   Reviews   |   Press   |   Contact us  
Copyright © 2005-2007 www.factbites.com Usage implies agreement with terms.