[all-commits] [llvm/llvm-project] 89f546: [JITLink][RISCV] Support GOT/PLT relocations

luxufan via All-commits all-commits at lists.llvm.org
Fri Aug 27 20:59:31 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 89f546f6ba1c21041f1e44657cb9980baf4cd4e6
      https://github.com/llvm/llvm-project/commit/89f546f6ba1c21041f1e44657cb9980baf4cd4e6
  Author: luxufan <932494295 at qq.com>
  Date:   2021-08-28 (Sat, 28 Aug 2021)

  Changed paths:
    M llvm/include/llvm/ExecutionEngine/JITLink/riscv.h
    M llvm/lib/ExecutionEngine/JITLink/ELF_riscv.cpp
    A llvm/test/ExecutionEngine/JITLink/RISCV/ELF_riscv32_got_plt_reloc.s
    A llvm/test/ExecutionEngine/JITLink/RISCV/ELF_riscv64_got_plt_reloc.s

  Log Message:
  -----------
  [JITLink][RISCV] Support GOT/PLT relocations

This patch add the R_RISCV_GOT_HI20 and R_RISCV_CALL_PLT relocation support. And the basic got/plt was implemented. Because of riscv32 and riscv64 has different pointer size, the got entry size and instructions of plt entry is different. This patch is the basic support, the optimization pass at preFixup stage has not been implemented.

Reviewed By: lhames

Differential Revision: https://reviews.llvm.org/D107688




More information about the All-commits mailing list