[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kdevelop-bugs
Subject:    [Bug 252659] deadlock due to ForegroundLock
From:       David Nolden <david.nolden.kde () art-master ! de>
Date:       2010-12-01 17:29:44
Message-ID: 20101201172944.89EEF75E9D () immanuel ! kde ! org
[Download RAW message or body]

https://bugs.kde.org/show_bug.cgi?id=252659





--- Comment #10 from David Nolden <david nolden kde art-master de>  2010-12-01 18:29:41 ---
Good luck trying to reproduce something that happens once in a week. You don't
know in what exact order the mutex was accessed before the problem appeared,
and this might be a very tiny race condition.

In turn, it doesn't make any sense to report a bug which you cannot reproduce,
and also, it isn't 100% sure that it's a bug in QMutex. The only way to answer
that question is by using a working replacement, and seeing whether the
replacement works better.

After having seen the internal code of QMutex, it's really not that unprobable
that it's buggy. It's a huge pile of spin-locks, wait-conditions, etc., instead
of being a simple wrapper around pthread mutex. Furthermore, the state I've
found the internals of QMutex in when debugging the deadlock seemed invalid (no
registered holder, only one thread accessing the mutex but waiting on the
wait-condition -> impossible). The code I've put around the mutex in KDevelop
indicates exactly the same thing. It's just 42 lines of code(lock...,
tryLock..., and unlock...), read them finally and convince yourself.

Anyway the primary sense of using the pthread mutex is bisecting the problem
between KDevelop and Qt. If  the outcome is that QMutex is buggy, it means we
have to report the problem, and/or switch our uses of QMutex in KDevelop to
something else.

-- 
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

_______________________________________________
KDevelop-bugs mailing list
KDevelop-bugs@kdevelop.org
https://barney.cs.uni-potsdam.de/mailman/listinfo/kdevelop-bugs
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic