aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Bitcode/Reader/MetadataLoader.cpp
diff options
context:
space:
mode:
authorJoseph Huber <jhuber6@vols.utk.edu>2023-06-14 18:59:29 -0500
committerJoseph Huber <jhuber6@vols.utk.edu>2023-06-15 07:06:43 -0500
commita09bec6459331e7f949c2ed3df6102de52d25f5d (patch)
treeacbc5b35e61aa6a6b71e64e344acb8db38ee50ac /llvm/lib/Bitcode/Reader/MetadataLoader.cpp
parent4e4bd29061de5e7790e47e78ec90e41e2ee7ee30 (diff)
downloadllvm-a09bec6459331e7f949c2ed3df6102de52d25f5d.zip
llvm-a09bec6459331e7f949c2ed3df6102de52d25f5d.tar.gz
llvm-a09bec6459331e7f949c2ed3df6102de52d25f5d.tar.bz2
[libc] Move the definitions of the standard IO streams to the platform
This patch moves the definitions of the standard IO streams to the platform file definition. This is necessary because previously we had a level of indirection where the stream's `FILE *` was initialized based on the pointer to the internal `__llvm_libc` version. This cannot be resolved ahead of time by the linker because the address will not be known until runtime. This caused the previous implementation to emit a global constructor to initialize the pointer to the actual `FILE *`. By moving these definitions so that we can bind their address to the original file type we can avoid this global constructor. This file keeps the entrypoints, but makes them empty files only containing an external reference. This is so they still appear as entrypoints and get emitted as declarations in the generated headers. Reviewed By: lntue, sivachandra Differential Revision: https://reviews.llvm.org/D152983
Diffstat (limited to 'llvm/lib/Bitcode/Reader/MetadataLoader.cpp')
0 files changed, 0 insertions, 0 deletions