forked from OSchip/llvm-project
Add missing cleanup code for cached indirect lock pool.
This change fixes one issue reported at https://llvm.org/bugs/show_bug.cgi?id=26184 There was missing cleanup code for the cached indirect lock pool. The change will fix the reported case where it tries to initialize a lock after runtime cleanup/reinitialization, but it is still possible that the user program runs into another problem because most test programs have a call to __kmpc_set_lock after cleanup/reinitialization without calling __kmpc_init_lock causing a crash/hang. llvm-svn: 258528
This commit is contained in:
parent
7b413c6c63
commit
3bd88d4c15
|
|
@ -3578,6 +3578,7 @@ __kmp_cleanup_indirect_user_locks()
|
|||
__kmp_free(ll->lock);
|
||||
ll->lock = NULL;
|
||||
}
|
||||
__kmp_indirect_lock_pool[k] = NULL;
|
||||
}
|
||||
// Clean up the remaining undestroyed locks.
|
||||
for (i = 0; i < __kmp_i_lock_table.next; i++) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue