forked from OSchip/llvm-project
b29c7fdb61
Summary:
The termination function duplicated the functionality of the
__attribute((destructor))-annotated function __kmp_internal_end_fini,
and we have no indication that this doesn't work.
The function might cause issues with link-time optimization turned on:
until very recently, none of the usual linkers was reporting functions
named in -Wl,-fini as used to the LTO plugin, so it might be dropped.
If the function is dropped, -Wl,-fini=__kmp_internal_end_fini doesn't
do what we want: with ld.bfd and lld it drops the FINI attribute from
.dynamic and with gold we get FINI = 0x0, which leads to a crash on
cleanup. This can be reproduced by building with
-DLLVM_ENABLE_PROJECTS="clang;openmp" \
-DLLVM_ENABLE_LTO=Thin \
-DLLVM_USE_LINKER=gold
The issue in lld has been fixed in
|
||
---|---|---|
.. | ||
LibompCheckFortranFlag.cmake | ||
LibompCheckLinkerFlag.cmake | ||
LibompDefinitions.cmake | ||
LibompExports.cmake | ||
LibompGetArchitecture.cmake | ||
LibompHandleFlags.cmake | ||
LibompMicroTests.cmake | ||
LibompUtils.cmake | ||
config-ix.cmake |