projects
/
platform
/
upstream
/
libgc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8d64dbd
)
Perform thread_suspend in loop as it may be interrupted (Darwin)
author
Jonathan Chambers
<joncham@gmail.com>
Tue, 24 Jul 2018 20:46:52 +0000
(16:46 -0400)
committer
Ivan Maidanski
<ivmai@mail.ru>
Fri, 27 Jul 2018 09:48:57 +0000
(12:48 +0300)
* darwin_stop_world.c (GC_stop_world): Retry thread_suspend() on
KERN_ABORTED.
darwin_stop_world.c
patch
|
blob
|
history
diff --git
a/darwin_stop_world.c
b/darwin_stop_world.c
index
fd04fcd
..
fe04a08
100644
(file)
--- a/
darwin_stop_world.c
+++ b/
darwin_stop_world.c
@@
-636,7
+636,9
@@
GC_INNER void GC_stop_world(void)
if ((p->flags & FINISHED) == 0 && !p->thread_blocked &&
p->stop_info.mach_thread != my_thread) {
- kern_result = thread_suspend(p->stop_info.mach_thread);
+ do {
+ kern_result = thread_suspend(p->stop_info.mach_thread);
+ } while (kern_result == KERN_ABORTED);
if (kern_result != KERN_SUCCESS)
ABORT("thread_suspend failed");
if (GC_on_thread_event)