From 26326ad39694f0a35a2cdba8fe0d06abbedc3923 Mon Sep 17 00:00:00 2001 From: Yuchen Wu Date: Tue, 3 Dec 2013 00:57:11 +0000 Subject: llvm-cov: Removed output to STDOUT/specified file. Instead of asking the user to specify a single file to output coverage info and defaulting to STDOUT, llvm-cov now creates files for each source file with a naming system of: + ".llcov". This is what gcov does and although it can clutter the working directory with numerous coverage files, it will be easier to hook the llvm-cov output to tools which operate on this assumption (such as lcov). llvm-svn: 196184 --- llvm/tools/llvm-cov/llvm-cov.cpp | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) (limited to 'llvm/tools/llvm-cov/llvm-cov.cpp') diff --git a/llvm/tools/llvm-cov/llvm-cov.cpp b/llvm/tools/llvm-cov/llvm-cov.cpp index 5f6999e..7f4d53e 100644 --- a/llvm/tools/llvm-cov/llvm-cov.cpp +++ b/llvm/tools/llvm-cov/llvm-cov.cpp @@ -17,7 +17,6 @@ #include "llvm/Support/ManagedStatic.h" #include "llvm/Support/MemoryObject.h" #include "llvm/Support/PrettyStackTrace.h" -#include "llvm/Support/raw_ostream.h" #include "llvm/Support/Signals.h" #include "llvm/Support/system_error.h" using namespace llvm; @@ -31,10 +30,6 @@ InputGCNO("gcno", cl::desc(""), cl::init("")); static cl::opt InputGCDA("gcda", cl::desc(""), cl::init("")); -static cl::opt -OutputFile("o", cl::desc(""), cl::init("-")); - - //===----------------------------------------------------------------------===// int main(int argc, char **argv) { // Print a stack trace if we signal out. @@ -44,11 +39,6 @@ int main(int argc, char **argv) { cl::ParseCommandLineOptions(argc, argv, "llvm coverage tool\n"); - std::string ErrorInfo; - raw_fd_ostream OS(OutputFile.c_str(), ErrorInfo); - if (!ErrorInfo.empty()) - errs() << ErrorInfo << "\n"; - GCOVFile GF; if (InputGCNO.empty()) errs() << " " << argv[0] << ": No gcov input file!\n"; @@ -83,6 +73,6 @@ int main(int argc, char **argv) { FileInfo FI; GF.collectLineCounts(FI); - FI.print(OS, InputGCNO, InputGCDA); + FI.print(InputGCNO, InputGCDA); return 0; } -- cgit v1.1