xref: /aosp_15_r20/external/llvm/test/tools/gold/X86/thinlto_prefix_replace.ll (revision 9880d6810fe72a1726cb53787c6711e909410d58)
1; Check that changing the output path via thinlto-prefix-replace works
2; RUN: mkdir -p %T/oldpath
3; RUN: opt -module-summary %s -o %T/oldpath/thinlto_prefix_replace.o
4; Ensure that there is no existing file at the new path, so we properly
5; test the creation of the new file there.
6; RUN: rm -f %T/newpath/thinlto_prefix_replace.o.thinlto.bc
7; RUN: %gold -plugin %llvmshlibdir/LLVMgold.so \
8; RUN:    --plugin-opt=thinlto \
9; RUN:    --plugin-opt=thinlto-index-only \
10; RUN:    --plugin-opt=thinlto-prefix-replace="%T/oldpath/;%T/newpath/" \
11; RUN:    -shared %T/oldpath/thinlto_prefix_replace.o -o %T/thinlto_prefix_replace
12; RUN: ls %T/newpath/thinlto_prefix_replace.o.thinlto.bc
13
14define void @f() {
15entry:
16  ret void
17}
18