Revert r114712 due to failure on darwin buildbot.

llvm-svn: 114713
This commit is contained in:
Nick Lewycky 2010-09-24 00:46:53 +00:00
parent e351fed104
commit 6e1ce29b01
1 changed files with 4 additions and 10 deletions

View File

@ -1151,22 +1151,16 @@ const char *Driver::GetNamedOutputPath(Compilation &C,
const char *BaseInput,
bool AtTopLevel) const {
llvm::PrettyStackTraceString CrashInfo("Computing output path");
// Default to writing to stdout.
if (AtTopLevel && isa<PreprocessJobAction>(JA)) {
if (Arg *DepOutput = C.getArgs().getLastArg(options::OPT_MF))
return C.addResultFile(DepOutput->getValue(C.getArgs()));
if (Arg *FinalOutput = C.getArgs().getLastArg(options::OPT_o))
return C.addResultFile(FinalOutput->getValue(C.getArgs()));
return "-";
}
// Output to a user requested destination?
if (AtTopLevel && !isa<DsymutilJobAction>(JA)) {
if (Arg *FinalOutput = C.getArgs().getLastArg(options::OPT_o))
return C.addResultFile(FinalOutput->getValue(C.getArgs()));
}
// Default to writing to stdout?
if (AtTopLevel && isa<PreprocessJobAction>(JA))
return "-";
// Output to a temporary file?
if (!AtTopLevel && !C.getArgs().hasArg(options::OPT_save_temps)) {
std::string TmpName =