[all-commits] [llvm/llvm-project] 9d701c: [ORC] Fix fallout from switch to _objc_map/load_im...
lhames via All-commits
all-commits at lists.llvm.org
Tue Apr 11 16:48:40 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 9d701c8a8d65a830c3d454479b13a50dcc097b57
https://github.com/llvm/llvm-project/commit/9d701c8a8d65a830c3d454479b13a50dcc097b57
Author: Lang Hames <lhames at gmail.com>
Date: 2023-04-11 (Tue, 11 Apr 2023)
Changed paths:
M compiler-rt/lib/orc/macho_platform.cpp
M compiler-rt/test/lit.common.cfg.py
M compiler-rt/test/orc/TestCases/Darwin/x86-64/trivial-swift-types-section.S
M llvm/include/llvm/ExecutionEngine/Orc/MachOPlatform.h
M llvm/lib/ExecutionEngine/Orc/MachOPlatform.cpp
Log Message:
-----------
[ORC] Fix fallout from switch to _objc_map/load_images-based registration.
In f448d44663a we switched to calling _objc_map_images and _objc_load_images
for MachO language metadata registration. This patch fixes some bugs arising
from that change:
(1) __objc_imageinfo processing was moved to a post-allocation pass, but this
prevents us from discarding the redundant copies. This commit moves
processing back to a pre-prune pass and inserts a symbol for the uniqued
__objc_image section. Runtime objects use an edge pointing to this symbol
to access the address.
(2) We were assuming that _objc_map_images & _objc_load_images were available
in the Objective-C runtime on 10.15, but these functions didn't become
available until later. This commit bumps the macOS version requirement to
13.1 where the functions should be available.
(3) The ORC-RT trivial-swift-types-section.S test was missing an
__objc_unwindinfo section, which triggered an assert that should have
been an error. The assert has been turned into an error, and the testcase
has been updated to include an __objc_imageinfo.
rdar://107846455
More information about the All-commits
mailing list