Skip to content

Commit ca4231e

Browse files
committed
Update the example to show that an archive can contain llvm bitcode.
llvm-svn: 75000
1 parent be75925 commit ca4231e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

llvm/docs/GoldPlugin.html

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,8 +127,9 @@
127127

128128
--- command lines ---
129129
$ llvm-gcc -flto a.c -c -o a.o # <-- a.o is LLVM bitcode file
130+
$ ar q a.a a.o # <-- a.a is an archive with LLVM bitcode
130131
$ llvm-gcc b.c -c -o b.o # <-- b.o is native object file
131-
$ llvm-gcc -use-gold-plugin a.o b.o -o main # <-- link with LLVMgold plugin
132+
$ llvm-gcc -use-gold-plugin a.a b.o -o main # <-- link with LLVMgold plugin
132133
</pre>
133134
<p>Gold informs the plugin that foo3 is never referenced outside the IR,
134135
leading LLVM to delete that function. However, unlike in the

0 commit comments

Comments
 (0)