Skip to content

Commit 85c779d

Browse files
committed
[llc] -filetype=null: don't create .null if -o is not specified
The new behavior is consistent with llvm-mc -filetype=null.
1 parent 2513407 commit 85c779d

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

llvm/test/CodeGen/X86/null-streamer.ll

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
; Check the MCNullStreamer operates correctly, at least on a minimal test case.
22
;
3+
; RUN: rm -f %t
34
; RUN: llc -filetype=null -o %t -mtriple=i686-- %s
4-
; RUN: llc -filetype=null -o %t -mtriple=i686-cygwin %s
5+
; RUN: ls %t
56

67
source_filename = "test/CodeGen/X86/null-streamer.ll"
78

llvm/tools/llc/llc.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ static std::unique_ptr<ToolOutputFile> GetOutputStream(const char *TargetName,
224224
OutputFilename += ".o";
225225
break;
226226
case CGFT_Null:
227-
OutputFilename += ".null";
227+
OutputFilename = "-";
228228
break;
229229
}
230230
}

0 commit comments

Comments
 (0)