diff options
author | Justin Bogner <mail@justinbogner.com> | 2014-06-24 08:01:01 +0000 |
---|---|---|
committer | Justin Bogner <mail@justinbogner.com> | 2014-06-24 08:01:01 +0000 |
commit | ce8245b5fdfe700ec0fdda13a2e8257de60d70ec (patch) | |
tree | 1f7c50bf9b088fd7a6bc7e5fbead8023da8b31de | |
parent | 23fc9afa4d8daaddfac99ff8b6fe384b62b0549f (diff) | |
download | bcm5719-llvm-ce8245b5fdfe700ec0fdda13a2e8257de60d70ec.tar.gz bcm5719-llvm-ce8245b5fdfe700ec0fdda13a2e8257de60d70ec.zip |
Driver: Restore proper naming of crashdump files
Based on a review of r211411 by Jordan Rose.
llvm-svn: 211572
-rw-r--r-- | clang/lib/Driver/Driver.cpp | 3 | ||||
-rw-r--r-- | clang/test/Driver/crash-report-modules.m | 6 | ||||
-rw-r--r-- | clang/test/Driver/crash-report.c | 6 |
3 files changed, 8 insertions, 7 deletions
diff --git a/clang/lib/Driver/Driver.cpp b/clang/lib/Driver/Driver.cpp index 4698999cb77..d4c03130ba8 100644 --- a/clang/lib/Driver/Driver.cpp +++ b/clang/lib/Driver/Driver.cpp @@ -1303,7 +1303,8 @@ Action *Driver::ConstructPhaseAction(const ArgList &Args, phases::ID Phase, } else { OutputTy = Input->getType(); if (!Args.hasFlag(options::OPT_frewrite_includes, - options::OPT_fno_rewrite_includes, false)) + options::OPT_fno_rewrite_includes, false) && + !CCGenDiagnostics) OutputTy = types::getPreprocessedType(OutputTy); assert(OutputTy != types::TY_INVALID && "Cannot preprocess this input type!"); diff --git a/clang/test/Driver/crash-report-modules.m b/clang/test/Driver/crash-report-modules.m index 4487a3407b1..ff805ed453a 100644 --- a/clang/test/Driver/crash-report-modules.m +++ b/clang/test/Driver/crash-report-modules.m @@ -5,11 +5,11 @@ // RUN: %clang -fsyntax-only %s -I %S/Inputs/module \ // RUN: -fmodules -fmodules-cache-path=/tmp/ -DFOO=BAR 2>&1 | FileCheck %s -// RUN: FileCheck --check-prefix=CHECKSRC %s -input-file %t/crash-report-*.mi +// RUN: FileCheck --check-prefix=CHECKSRC %s -input-file %t/crash-report-*.m // RUN: FileCheck --check-prefix=CHECKSH %s -input-file %t/crash-report-*.sh // REQUIRES: crash-recovery -// because of the glob (*.mi, *.sh) +// because of the glob (*.m, *.sh) // REQUIRES: shell // FIXME: This XFAIL is cargo-culted from crash-report.c. Do we need it? @@ -19,7 +19,7 @@ const int x = MODULE_MACRO; // CHECK: Preprocessed source(s) and associated run script(s) are located at: -// CHECK-NEXT: note: diagnostic msg: {{.*}}.mi +// CHECK-NEXT: note: diagnostic msg: {{.*}}.m // CHECK-NEXT: note: diagnostic msg: {{.*}}.cache // CHECKSRC: @import simple; diff --git a/clang/test/Driver/crash-report.c b/clang/test/Driver/crash-report.c index 5a414e4d1ab..f3c2e472e41 100644 --- a/clang/test/Driver/crash-report.c +++ b/clang/test/Driver/crash-report.c @@ -6,11 +6,11 @@ // RUN: -Xclang -internal-isystem -Xclang /tmp/ \ // RUN: -Xclang -internal-externc-isystem -Xclang /tmp/ \ // RUN: -DFOO=BAR 2>&1 | FileCheck %s -// RUN: cat %t/crash-report-*.i | FileCheck --check-prefix=CHECKSRC %s +// RUN: cat %t/crash-report-*.c | FileCheck --check-prefix=CHECKSRC %s // RUN: cat %t/crash-report-*.sh | FileCheck --check-prefix=CHECKSH %s // REQUIRES: crash-recovery -// because of the glob (*.i, *.sh) +// because of the glob (*.c, *.sh) // REQUIRES: shell // RUN: not env FORCE_CLANG_DIAGNOSTICS_CRASH=1 %clang -fsyntax-only -x c /dev/null -lstdc++ 2>&1 | FileCheck %s @@ -20,7 +20,7 @@ #pragma clang __debug parser_crash // CHECK: Preprocessed source(s) and associated run script(s) are located at: -// CHECK-NEXT: note: diagnostic msg: {{.*}}.i +// CHECK-NEXT: note: diagnostic msg: {{.*}}.c FOO // CHECKSRC: FOO // CHECKSH: -cc1 |