[llvm-commits] [llvm] r59586 - in /llvm/trunk: include/llvm/CompilerDriver/Tools.td test/LLVMC/emit-llvm.c
Daniel Dunbar
daniel at zuster.org
Tue Nov 18 20:15:58 PST 2008
Author: ddunbar
Date: Tue Nov 18 22:15:56 2008
New Revision: 59586
URL: http://llvm.org/viewvc/llvm-project?rev=59586&view=rev
Log:
LLVMC2: -emit-llvm stops compilation.
Added:
llvm/trunk/test/LLVMC/emit-llvm.c
Modified:
llvm/trunk/include/llvm/CompilerDriver/Tools.td
Modified: llvm/trunk/include/llvm/CompilerDriver/Tools.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/CompilerDriver/Tools.td?rev=59586&r1=59585&r2=59586&view=diff
==============================================================================
--- llvm/trunk/include/llvm/CompilerDriver/Tools.td (original)
+++ llvm/trunk/include/llvm/CompilerDriver/Tools.td Tue Nov 18 22:15:56 2008
@@ -25,6 +25,8 @@
"llvm-gcc -c -x c $INFILE",
(default),
"llvm-gcc -c -x c $INFILE -o $OUTFILE -emit-llvm")),
+ (switch_option "emit-llvm", (stop_compilation),
+ (help "Emit LLVM intermediate files instead of native object files")),
(switch_option "E", (stop_compilation),
(help "Stop after the preprocessing stage, do not run the compiler")),
(switch_option "fsyntax-only", (stop_compilation),
Added: llvm/trunk/test/LLVMC/emit-llvm.c
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/LLVMC/emit-llvm.c?rev=59586&view=auto
==============================================================================
--- llvm/trunk/test/LLVMC/emit-llvm.c (added)
+++ llvm/trunk/test/LLVMC/emit-llvm.c Tue Nov 18 22:15:56 2008
@@ -0,0 +1,4 @@
+// RUN: llvmc2 -c -emit-llvm -o - %s | llvm-dis | grep "@f0()" | count 1
+
+int f0(void) {
+}
More information about the llvm-commits
mailing list