aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam/sys.h
diff options
context:
space:
mode:
authorLukas Larsson <[email protected]>2014-12-04 11:04:23 +0100
committerLukas Larsson <[email protected]>2014-12-19 10:39:52 +0100
commitb8a2313263d0f120dacbe82ced5c99545bbd15a3 (patch)
treed77376ce678171c430740e00904a32044f350bb0 /erts/emulator/beam/sys.h
parentd6d1ef4787951070dd152daf44eff2003b7f2ed2 (diff)
downloadotp-b8a2313263d0f120dacbe82ced5c99545bbd15a3.tar.gz
otp-b8a2313263d0f120dacbe82ced5c99545bbd15a3.tar.bz2
otp-b8a2313263d0f120dacbe82ced5c99545bbd15a3.zip
erts: Introduce thread suspend functions
These functions allow any thread to suspend any other thread immediately and then resume all threads. This is useful when doing a crash dump in order to get a more accurate picture of what state the system is in.
Diffstat (limited to 'erts/emulator/beam/sys.h')
-rw-r--r--erts/emulator/beam/sys.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/erts/emulator/beam/sys.h b/erts/emulator/beam/sys.h
index c29d4b3777..bdc5237815 100644
--- a/erts/emulator/beam/sys.h
+++ b/erts/emulator/beam/sys.h
@@ -784,6 +784,11 @@ int erts_sys_unsetenv(char *key);
char *erts_read_env(char *key);
void erts_free_read_env(void *value);
+#if defined(ERTS_THR_HAVE_SIG_FUNCS) && !defined(ETHR_UNUSABLE_SIGUSRX)
+extern void sys_thr_resume(erts_tid_t tid);
+extern void sys_thr_suspend(erts_tid_t tid);
+#endif
+
/* utils.c */
/* Options to sys_alloc_opt */