1
0

reloc.h 663 B

12345678910111213141516171819202122
  1. #if defined __riscv_float_abi_soft
  2. #define RISCV_FP_SUFFIX "-sf"
  3. #elif defined __riscv_float_abi_single
  4. #define RISCV_FP_SUFFIX "-sp"
  5. #elif defined __riscv_float_abi_double
  6. #define RISCV_FP_SUFFIX ""
  7. #endif
  8. #define LDSO_ARCH "riscv32" RISCV_FP_SUFFIX
  9. #define TPOFF_K 0
  10. #define REL_SYMBOLIC R_RISCV_32
  11. #define REL_PLT R_RISCV_JUMP_SLOT
  12. #define REL_RELATIVE R_RISCV_RELATIVE
  13. #define REL_COPY R_RISCV_COPY
  14. #define REL_DTPMOD R_RISCV_TLS_DTPMOD32
  15. #define REL_DTPOFF R_RISCV_TLS_DTPREL32
  16. #define REL_TPOFF R_RISCV_TLS_TPREL32
  17. #define CRTJMP(pc,sp) __asm__ __volatile__( \
  18. "mv sp, %1 ; jr %0" : : "r"(pc), "r"(sp) : "memory" )