forked from OSchip/llvm-project
Hopefully fixes test failures for msvc.
Looks like llvm::sys::path::filename() was canonicalizing my paths before emitting them for FileCheck to stumble over. Fix a style nit with r219460 while I'm at it. llvm-svn: 219464
This commit is contained in:
parent
d30d8f4658
commit
a4ec57c2c5
|
@ -3242,8 +3242,7 @@ void Clang::ConstructJob(Compilation &C, const JobAction &JA,
|
|||
if (Output.isFilename()) {
|
||||
CmdArgs.push_back("-coverage-file");
|
||||
SmallString<128> CoverageFilename;
|
||||
Arg *FinalOutput = C.getArgs().getLastArg(options::OPT_o);
|
||||
if (FinalOutput) {
|
||||
if (Arg *FinalOutput = C.getArgs().getLastArg(options::OPT_o)) {
|
||||
CoverageFilename = FinalOutput->getValue();
|
||||
} else {
|
||||
CoverageFilename = llvm::sys::path::filename(Output.getBaseInput());
|
||||
|
|
|
@ -78,10 +78,10 @@
|
|||
// RUN: %clang -### -S -fprofile-arcs -no-integrated-as %s -o foo/bar.o 2>&1 | FileCheck -check-prefix=CHECK-GCNO-LOCATION-REL-PATH %s
|
||||
// RUN: %clang -### -c -fprofile-arcs %s -o foo/bar.o 2>&1 | FileCheck -check-prefix=CHECK-GCNO-LOCATION-REL-PATH %s
|
||||
// RUN: %clang -### -c -fprofile-arcs -no-integrated-as %s -o foo/bar.o 2>&1 | FileCheck -check-prefix=CHECK-GCNO-LOCATION-REL-PATH %s
|
||||
// CHECK-GCNO-DEFAULT-LOCATION: "-coverage-file" "{{.*}}/clang_f_opts.c"
|
||||
// CHECK-GCNO-DEFAULT-LOCATION-NOT: "-coverage-file" "/tmp/{{.*}}/clang_f_opts.c"
|
||||
// CHECK-GCNO-LOCATION: "-coverage-file" "/foo/bar.o"
|
||||
// CHECK-GCNO-LOCATION-REL-PATH: "-coverage-file" "{{.*}}/foo/bar.o"
|
||||
// CHECK-GCNO-DEFAULT-LOCATION: "-coverage-file" "{{.*}}{{[/\\]}}clang_f_opts.c"
|
||||
// CHECK-GCNO-DEFAULT-LOCATION-NOT: "-coverage-file" "{{[/\\]}}tmp{{[/\\]}}{{.*}}{{[/\\]}}clang_f_opts.c"
|
||||
// CHECK-GCNO-LOCATION: "-coverage-file" "{{[/\\]}}foo{{[/\\]}}bar.o"
|
||||
// CHECK-GCNO-LOCATION-REL-PATH: "-coverage-file" "{{.*}}{{[/\\]}}foo{{[/\\]}}bar.o"
|
||||
|
||||
// RUN: %clang -### -S -fvectorize %s 2>&1 | FileCheck -check-prefix=CHECK-VECTORIZE %s
|
||||
// RUN: %clang -### -S -fno-vectorize -fvectorize %s 2>&1 | FileCheck -check-prefix=CHECK-VECTORIZE %s
|
||||
|
|
Loading…
Reference in New Issue