Commit bc7d684c authored by Dan Povey's avatar Dan Povey
Browse files

trunk: change to kaldi-mutex.cc to be tolerant of the gcc/Haswell bug...

trunk: change to kaldi-mutex.cc to be tolerant of the gcc/Haswell bug described at http://lists.opensuse.org/opensuse-bugs/2014-03/msg00137.html

git-svn-id: https://svn.code.sf.net/p/kaldi/code/trunk@4335 5e6a8d80-dfce-4ca6-a32a-6e07a63d50c8
parent 9fbe2e33
......@@ -38,8 +38,15 @@ Mutex::Mutex() {
Mutex::~Mutex() {
int ret;
if ( (ret = pthread_mutex_destroy(&mutex_)) != 0) {
KALDI_ERR << "Cannot destroy pthread mutex, error is: "
<< strerror(ret);
if (ret != 16) {
KALDI_ERR << "Cannot destroy pthread mutex, error is: "
<< strerror(ret);
} else {
KALDI_WARN << "Error destroying pthread mutex; ignoring it as it could be "
<< "a known issue that affects Haswell processors, see "
<< "http://lists.opensuse.org/opensuse-bugs/2014-03/msg00137.html "
<< "If your processor is not Haswell, this is a bug.";
}
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment