1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-25 12:12:47 +01:00
llvm-mirror/test/tools/llvm-profdata/input-dir.test
Xinliang David Li 4eb4c0a05c Fix test failure on Win
llvm-svn: 276202
2016-07-20 22:53:39 +00:00

23 lines
713 B
Plaintext

# Create an input file.
RUN: echo "#" > %t.input
RUN: echo "%t.dir1" >> %t.input
RUN: echo "2,%t.dir2" >> %t.input
RUN: mkdir -p %t.dir1
RUN: mkdir -p %t.dir2/subdir
RUN: echo ' ' > %t.dir1/bar
RUN: echo ' ' > %t.dir1/foo
RUN: echo ' ' > %t.dir2/bar
RUN: echo ' ' > %t.dir2/foo
RUN: echo ' ' > %t.dir2/subdir/baz
RUN: llvm-profdata merge -f %t.input -dump-input-file-list -o /dev/null | FileCheck %s
RUN: llvm-profdata merge -weighted-input=2,%t.dir2 -dump-input-file-list -o /dev/null %t.dir1 | FileCheck %s
CHECK-DAG: 1,{{.*}}.dir1{{[/\\]}}bar
CHECK-DAG: 1,{{.*}}.dir1{{[/\\]}}foo
CHECK-DAG: 2,{{.*}}.dir2{{[/\\]}}bar
CHECK-DAG: 2,{{.*}}.dir2{{[/\\]}}foo
CHECK-DAG: 2,{{.*}}.dir2{{[/\\]}}subdir{{[/\\]}}baz