blob: b378a58a6fa93124ef15a3319ad84ad1a2008025 [file] [log] [blame]
Teresa Johnsonbbd10b42016-05-17 14:45:30 +00001; Check that changing the output path via prefix-replace works
Teresa Johnson1e7d4ab2016-05-17 15:26:13 +00002; Use of '/' in paths created here make this unsuitable for Windows.
3; XFAIL: win32
Teresa Johnsonbbd10b42016-05-17 14:45:30 +00004; RUN: mkdir -p %T/oldpath
5; RUN: opt -module-summary %s -o %T/oldpath/prefix_replace.o
6; Ensure that there is no existing file at the new path, so we properly
7; test the creation of the new file there.
8; RUN: rm -f %T/newpath/prefix_replace.o.thinlto.bc
9
10; RUN: llvm-lto -thinlto-action=thinlink -o %t.index.bc %T/oldpath/prefix_replace.o
11; RUN: llvm-lto -thinlto-action=distributedindexes -thinlto-prefix-replace="%T/oldpath/:%T/newpath/" -thinlto-index %t.index.bc %T/oldpath/prefix_replace.o
12
13; RUN: ls %T/newpath/prefix_replace.o.thinlto.bc
14
15define void @f() {
16entry:
17 ret void
18}