forked from OSchip/llvm-project
Fix doc for `-opt-bisect-limit`: the LTO option is linker specific
llvm-svn: 294725
This commit is contained in:
parent
b4442f34cd
commit
a826244bb1
|
@ -60,12 +60,15 @@ like this:
|
||||||
clang -O2 -mllvm -opt-bisect-limit=256 my_file.c
|
clang -O2 -mllvm -opt-bisect-limit=256 my_file.c
|
||||||
|
|
||||||
The -opt-bisect-limit option may also be applied to link-time optimizations by
|
The -opt-bisect-limit option may also be applied to link-time optimizations by
|
||||||
using a prefix to indicate that this is a plug-in option for the linker. The
|
using a prefix to indicate that this is a plug-in option for the linker. The
|
||||||
following syntax will set a bisect limit for LTO transformations:
|
following syntax will set a bisect limit for LTO transformations:
|
||||||
|
|
||||||
::
|
::
|
||||||
|
|
||||||
|
# When using Gold or lld
|
||||||
clang -flto -Wl,-plugin-opt,-opt-bisect-limit=256 my_file.o my_other_file.o
|
clang -flto -Wl,-plugin-opt,-opt-bisect-limit=256 my_file.o my_other_file.o
|
||||||
|
# When using ld64 (macOS)
|
||||||
|
clang -flto -Wl,-mllvm,-opt-bisect-limit=256 my_file.o my_other_file.o
|
||||||
|
|
||||||
LTO passes are run by a library instance invoked by the linker. Therefore any
|
LTO passes are run by a library instance invoked by the linker. Therefore any
|
||||||
passes run in the primary driver compilation phase are not affected by options
|
passes run in the primary driver compilation phase are not affected by options
|
||||||
|
|
Loading…
Reference in New Issue