[JITLink] Introduce target flags for Symbol and prepare ObjectLinkingLayer to account...
authorStefan Gränitz <stefan.graenitz@gmail.com>
Wed, 22 Mar 2023 19:21:59 +0000 (20:21 +0100)
committerStefan Gränitz <stefan.graenitz@gmail.com>
Wed, 22 Mar 2023 19:44:43 +0000 (20:44 +0100)
commitcf8dc9dfe9eb66621cb7c860bf81b29699415c66
tree471c994faaab216cada8dcf0d43a48598d9edcb9
parent587b3713309b03f73d2affba8a9a992a70aff174
[JITLink] Introduce target flags for Symbol and prepare ObjectLinkingLayer to account for them

AArch32 branch offsets explicitly encode the target instruction subset (Arm/Thumb) in their least significant bit. We want this bit set (or clear) in addreses we hand out, but the addresses in the LinkGraph should be the real/physical addresses.

This patch allows ELFLinkGraphBuilder's to set target-specific flags in jitlink::Symbol and prepares ObjectLinkingLayer to account for them.

Reviewed By: lhames

Differential Revision: https://reviews.llvm.org/D146641
llvm/include/llvm/ExecutionEngine/JITLink/JITLink.h
llvm/lib/ExecutionEngine/JITLink/ELFLinkGraphBuilder.h
llvm/lib/ExecutionEngine/Orc/ObjectLinkingLayer.cpp