diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2016-07-23 20:41:05 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2016-07-23 20:41:05 +0000 |
commit | 01095a5d43bbfde13731688ddcf6048ebb8b7721 (patch) | |
tree | 4def12e759965de927d963ac65840d663ef9d1ea /docs/LinkTimeOptimization.rst | |
parent | f0f4822ed4b66e3579e92a89f368f8fb860e218e (diff) |
Diffstat (limited to 'docs/LinkTimeOptimization.rst')
-rw-r--r-- | docs/LinkTimeOptimization.rst | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/docs/LinkTimeOptimization.rst b/docs/LinkTimeOptimization.rst index 55a7486874a31..9c1e5607596bb 100644 --- a/docs/LinkTimeOptimization.rst +++ b/docs/LinkTimeOptimization.rst @@ -87,9 +87,9 @@ To compile, run: .. code-block:: console - % clang -emit-llvm -c a.c -o a.o # <-- a.o is LLVM bitcode file + % clang -flto -c a.c -o a.o # <-- a.o is LLVM bitcode file % clang -c main.c -o main.o # <-- main.o is native object file - % clang a.o main.o -o main # <-- standard link command without modifications + % clang -flto a.o main.o -o main # <-- standard link command with -flto * In this example, the linker recognizes that ``foo2()`` is an externally visible symbol defined in LLVM bitcode file. The linker completes its usual |