aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp
diff options
context:
space:
mode:
authorJunfeng Dong <jfdong@fb.com>2022-03-23 08:54:52 -0700
committerHongtao Yu <hoy@fb.com>2022-03-23 08:55:30 -0700
commit72acd042bad35f78232f17addc02196a7af1a6e9 (patch)
tree9c461e23a700c701526e5d7362a049a34448bac3 /clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp
parent3ea6727e33d24c54ea6afb8887846a1f9a1011c3 (diff)
downloadllvm-72acd042bad35f78232f17addc02196a7af1a6e9.zip
llvm-72acd042bad35f78232f17addc02196a7af1a6e9.tar.gz
llvm-72acd042bad35f78232f17addc02196a7af1a6e9.tar.bz2
Pass split-machine-functions to code generator when flto is used
-fsplit-machine-functions is an optimization in codegen phase. when -flto is use, clang generate IR bitcode in .o files, and linker will call into these codegen optimization passes. Current clang driver doesn't pass this option to linker when both -fsplit-machine-functions and -flto are used, so the optimization is silently ignored. My fix generates linker option -plugin-opt=-split-machine-functions for this case. It allows the linker to pass "split-machine-functions" to code generator to turn on that optimization. It works for both gold and lld. Reviewed By: hoy, wenlei Differential Revision: https://reviews.llvm.org/D121969
Diffstat (limited to 'clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp')
0 files changed, 0 insertions, 0 deletions