diff options
Diffstat (limited to 'libpthread/nptl/sysdeps/unix/sysv/linux')
-rw-r--r-- | libpthread/nptl/sysdeps/unix/sysv/linux/arm/Makefile.arch | 6 | ||||
-rw-r--r-- | libpthread/nptl/sysdeps/unix/sysv/linux/arm/unwind-resume.c | 8 |
2 files changed, 13 insertions, 1 deletions
diff --git a/libpthread/nptl/sysdeps/unix/sysv/linux/arm/Makefile.arch b/libpthread/nptl/sysdeps/unix/sysv/linux/arm/Makefile.arch index 7dfaacc9d..5c8d634cd 100644 --- a/libpthread/nptl/sysdeps/unix/sysv/linux/arm/Makefile.arch +++ b/libpthread/nptl/sysdeps/unix/sysv/linux/arm/Makefile.arch @@ -18,7 +18,11 @@ endif CFLAGS-pthread_once.c = -DNOT_IN_libc=1 -DIS_IN_libpthread=1 CFLAGS-lowlevellock.c = -DNOT_IN_libc=1 -DIS_IN_libpthread=1 -ASFLAGS-pt-vfork.S = -DNOT_IN_libc=1 -DIS_IN_libpthread=1 +ASFLAGS-pt-vfork.S = -DNOT_IN_libc=1 -DIS_IN_libpthread=1 -marm +# We always compile it in arm mode because of SAVE_PID macro +# This macro should be alternatively implemented in THUMB +# assembly. +ASFLAGS-vfork.S = -marm CFLAGS += $(SSP_ALL_CFLAGS) #CFLAGS:=$(CFLAGS:-O1=-O2) diff --git a/libpthread/nptl/sysdeps/unix/sysv/linux/arm/unwind-resume.c b/libpthread/nptl/sysdeps/unix/sysv/linux/arm/unwind-resume.c index 8188249ef..fb842f97d 100644 --- a/libpthread/nptl/sysdeps/unix/sysv/linux/arm/unwind-resume.c +++ b/libpthread/nptl/sysdeps/unix/sysv/linux/arm/unwind-resume.c @@ -19,6 +19,7 @@ #include <dlfcn.h> #include <stdio.h> +#include <stdlib.h> #include <unwind.h> #define __libc_dlopen(x) dlopen(x, (RTLD_LOCAL | RTLD_LAZY)) @@ -54,6 +55,9 @@ init (void) assembly. */ __asm__ ( +#ifdef __thumb__ +" .code 32\n" +#endif " .globl _Unwind_Resume\n" " .type _Unwind_Resume, %function\n" "_Unwind_Resume:\n" @@ -74,6 +78,10 @@ __asm__ ( "1: .word _GLOBAL_OFFSET_TABLE_ - 3b - 8\n" "2: .word libgcc_s_resume(GOTOFF)\n" " .size _Unwind_Resume, .-_Unwind_Resume\n" +#ifdef __thumb__ +" .code 16\n" +#endif + ); _Unwind_Reason_Code |