0.8.0.12:
[sbcl.git] / src / runtime / x86-linux-os.c
index 9b46107..d943e6f 100644 (file)
@@ -20,6 +20,7 @@
 #include <sys/file.h>
 #include <sys/types.h>
 #include <unistd.h>
+#include <errno.h>
 
 #include "./signal.h"
 #include "os.h"
@@ -127,6 +128,11 @@ struct thread *arch_os_get_current_thread() {
     return all_threads;
 #endif
 }
+struct thread *debug_get_fs() {
+    register u32 fs;
+    __asm__("movl %%fs,%0" : "=r" (fs)  : );
+    return fs;
+}
 
 /* free any arch/os-specific resources used by thread, which is now
  * defunct.  Not called on live threads