[PATCH] D105429: [JITLink][RISCV] Initial Support RISCV64 in JITLink

luxufan via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 5 05:08:35 PDT 2021


StephenFan created this revision.
StephenFan added reviewers: lhames, sgraenitz, MaskRay.
Herald added subscribers: vkmr, frasercrmck, evandro, luismarques, apazos, sameer.abuasal, s.egerton, Jim, benna, psnobl, jocewei, PkmX, the_o, brucehoult, MartinMosbeck, rogfer01, edward-jones, zzheng, jrtc27, shiva0217, kito-cheng, niosHD, sabuasal, simoncook, johnrusso, rbar, asb, hiraditya, mgorny.
StephenFan requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

This patch is the initial support, it implements translation from object file to JIT link graph, and very few relocations were supported. Currently, the test file ELF_pc_indirect.s is passed, the HelloWorld program(compiled with mno-relax flag) can be linked correctly and run on instruction emulator correctly.

In the downstream implementation, I have implemented the GOT, PLT function, and EHFrame and some optimization will be implement soon. I will organize the code in to patches, then gradually send it to upstream.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D105429

Files:
  llvm/include/llvm/ExecutionEngine/JITLink/ELF_riscv64.h
  llvm/lib/ExecutionEngine/JITLink/CMakeLists.txt
  llvm/lib/ExecutionEngine/JITLink/ELF.cpp
  llvm/lib/ExecutionEngine/JITLink/ELF_riscv64.cpp
  llvm/test/ExecutionEngine/JITLink/RISCV/ELF_pc_indirect.s

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D105429.356483.patch
Type: text/x-patch
Size: 16282 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210705/36cfe661/attachment.bin>


More information about the llvm-commits mailing list