This is the mail archive of the libc-help@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Assertion `mutex->__data.__owner


On Thu, Nov 24, 2011 at 7:56 AM, trisha yad <trisha1march@gmail.com> wrote:
> Today on my ARM Board one problem hit.
> pthread_mutex_lock.c:62: __pthread_mutex_lock: Assertion
> `mutex->__data.__owner == 0' failed.
> This happen in pthread_mutex_lock.c.
> May you pls let me know in which all cases it can happen.

It should only happen if:
* the atomic operation was *not* atomic and you took a lock owned by
another thread.
* another thread accidentally corrupted the mutex by writing into it
without holding the lock e.g. buffer overrun/underrun etc.
* you have a compiler bug that causes the threading library to be
incorrectly compiled and violate the ordering requirements the code
needs to be atomic.

Is it reproducible?

Cheers,
Carlos.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]