3 #if __BYTE_ORDER == __BIG_ENDIAN
4 #define ENDIAN_SUFFIX "eb"
6 #define ENDIAN_SUFFIX ""
9 #if __SH_FPU_ANY__ || __SH4__
12 #define FP_SUFFIX "-nofpu"
16 #define ABI_SUFFIX "-fdpic"
21 #define LDSO_ARCH "sh" ENDIAN_SUFFIX FP_SUFFIX ABI_SUFFIX
25 #define REL_SYMBOLIC R_SH_DIR32
26 #define REL_OFFSET R_SH_REL32
27 #define REL_GOT R_SH_GLOB_DAT
28 #define REL_PLT R_SH_JMP_SLOT
29 #define REL_RELATIVE R_SH_RELATIVE
30 #define REL_COPY R_SH_COPY
31 #define REL_DTPMOD R_SH_TLS_DTPMOD32
32 #define REL_DTPOFF R_SH_TLS_DTPOFF32
33 #define REL_TPOFF R_SH_TLS_TPOFF32
35 #define DL_NOMMU_SUPPORT 1
38 #define REL_FUNCDESC R_SH_FUNCDESC
39 #define REL_FUNCDESC_VAL R_SH_FUNCDESC_VALUE
42 #define FDPIC_CONSTDISP_FLAG 0x100
43 #define CRTJMP(pc,sp) do { \
44 register size_t r8 __asm__("r8") = ((size_t *)(sp))[-2]; \
45 __asm__ __volatile__( "jmp @%0 ; mov %1,r15" \
46 : : "r"(pc), "r"(sp), "r"(r8) : "memory" ); } while(0)
47 #define GETFUNCSYM(fp, sym, got) __asm__ ( \
48 "mov.l 1f,%0 ; add %1,%0 ; bra 2f ; nop ; .align 2 \n" \
49 "1: .long " #sym "@GOTOFFFUNCDESC \n2:" \
50 : "=&r"(*fp) : "r"(got) : "memory" )
52 #define CRTJMP(pc,sp) __asm__ __volatile__( \
53 "jmp @%0 ; mov %1,r15" : : "r"(pc), "r"(sp) : "memory" )