mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-12-13 14:35:54 +00:00
Only output code if file open is successful
llvm-svn: 890
This commit is contained in:
parent
6c1fee9a85
commit
236f063966
@ -86,8 +86,6 @@ public:
|
||||
|
||||
|
||||
virtual bool doPassFinalization(Module *M) {
|
||||
// TODO: This should be performed as a moduleCleanup function, but we don't
|
||||
// have one yet!
|
||||
Target.emitAssembly(M, *Out);
|
||||
|
||||
if (DeleteStream) delete Out;
|
||||
@ -147,11 +145,11 @@ int main(int argc, char **argv) {
|
||||
<< "! SKIPPING OUTPUT OF TRACE CODE\n";
|
||||
delete os;
|
||||
retCode = 1;
|
||||
} else {
|
||||
Passes.push_back(new PrintModulePass("", os,
|
||||
/*deleteStream*/ true,
|
||||
/*printAsBytecode*/ ! DebugTrace));
|
||||
}
|
||||
|
||||
Passes.push_back(new PrintModulePass("", os,
|
||||
/*deleteStream*/ true,
|
||||
/*printAsBytecode*/ ! DebugTrace));
|
||||
}
|
||||
|
||||
// If LLVM dumping after transformations is requested, add it to the pipeline
|
||||
|
Loading…
Reference in New Issue
Block a user