diff --git a/clang/examples/PrintFunctionNames/PrintFunctionNames.cpp b/clang/examples/PrintFunctionNames/PrintFunctionNames.cpp index a103c63704af..5b7b66a4f7ff 100644 --- a/clang/examples/PrintFunctionNames/PrintFunctionNames.cpp +++ b/clang/examples/PrintFunctionNames/PrintFunctionNames.cpp @@ -7,8 +7,8 @@ // //===----------------------------------------------------------------------===// // -// Example clang-cc plugin which simply prints the names of all the top-level -// decls in the input file. +// Example clang plugin which simply prints the names of all the top-level decls +// in the input file. // //===----------------------------------------------------------------------===// diff --git a/clang/examples/PrintFunctionNames/README.txt b/clang/examples/PrintFunctionNames/README.txt index 2859eeff5579..ee6f7e865e91 100644 --- a/clang/examples/PrintFunctionNames/README.txt +++ b/clang/examples/PrintFunctionNames/README.txt @@ -1,4 +1,4 @@ -This is a simple example demonstrating how to use clang-cc's facility for +This is a simple example demonstrating how to use clang's facility for providing AST consumers using a plugin. You will probably need to build clang so that it exports all symbols (disable @@ -6,5 +6,5 @@ TOOL_NO_EXPORT in the tools/clang Makefile). Once the plugin is built, you can run it using: -- -$ clang-cc -load path/to/PrintFunctionNames.so -plugin=print-fns some-input-file.c +$ clang -cc1 -load path/to/PrintFunctionNames.so -plugin=print-fns some-input-file.c -- diff --git a/clang/include/clang/Frontend/ASTConsumers.h b/clang/include/clang/Frontend/ASTConsumers.h index 26efa9745600..20bf83ee0456 100644 --- a/clang/include/clang/Frontend/ASTConsumers.h +++ b/clang/include/clang/Frontend/ASTConsumers.h @@ -94,9 +94,9 @@ ASTConsumer *CreateHTMLPrinter(llvm::raw_ostream *OS, Preprocessor &PP, bool SyntaxHighlight = true, bool HighlightMacros = true); -// PCH generator: generates a precompiled header file; this file can be -// used later with the PCHReader (clang-cc option -include-pch) -// to speed up compile times. +// PCH generator: generates a precompiled header file; this file can be used +// later with the PCHReader (clang -cc1 option -include-pch) to speed up compile +// times. ASTConsumer *CreatePCHGenerator(const Preprocessor &PP, llvm::raw_ostream *OS, const char *isysroot = 0); diff --git a/clang/lib/Frontend/CompilerInstance.cpp b/clang/lib/Frontend/CompilerInstance.cpp index f36a56032b29..2a6a8a8750d2 100644 --- a/clang/lib/Frontend/CompilerInstance.cpp +++ b/clang/lib/Frontend/CompilerInstance.cpp @@ -95,7 +95,7 @@ static void SetUpBuildDumpLog(const DiagnosticOptions &DiagOpts, return; } - (*OS) << "clang-cc command line arguments: "; + (*OS) << "clang -cc1 command line arguments: "; for (unsigned i = 0; i != argc; ++i) (*OS) << argv[i] << ' '; (*OS) << '\n'; diff --git a/clang/utils/TestUtils/pch-test.pl b/clang/utils/TestUtils/pch-test.pl index 2e17117a2a29..e097c5c00c09 100755 --- a/clang/utils/TestUtils/pch-test.pl +++ b/clang/utils/TestUtils/pch-test.pl @@ -1,7 +1,7 @@ #!/usr/bin/perl -w # This tiny little script, which should be run from the clang -# directory (with clang-cc in your patch), tries to take each +# directory (with clang in your patch), tries to take each # compilable Clang test and build a PCH file from that test, then read # and dump the contents of the PCH file just created. use POSIX; @@ -17,12 +17,12 @@ sub testfiles($$) { @files = `ls test/*/*.$suffix`; foreach $file (@files) { chomp($file); - my $code = system("clang-cc -fsyntax-only -x $language $file > /dev/null 2>&1"); + my $code = system("clang- -fsyntax-only -x $language $file > /dev/null 2>&1"); if ($code == 0) { print("."); - $code = system("clang-cc -emit-pch -x $language -o $file.pch $file > /dev/null 2>&1"); + $code = system("clang -cc1 -emit-pch -x $language -o $file.pch $file > /dev/null 2>&1"); if ($code == 0) { - $code = system("clang-cc -include-pch $file.pch -x $language -ast-dump /dev/null > /dev/null 2>&1"); + $code = system("clang -cc1 -include-pch $file.pch -x $language -ast-dump /dev/null > /dev/null 2>&1"); if ($code == 0) { $passed++; } elsif (($code & 0xFF) == SIGINT) { diff --git a/clang/www/analyzer/installation.html b/clang/www/analyzer/installation.html index 81f45514fc01..d2be711a4860 100644 --- a/clang/www/analyzer/installation.html +++ b/clang/www/analyzer/installation.html @@ -87,13 +87,13 @@ source code.

  • Try it out (assuming you add llvm/Debug/bin to your path):
  • -

    Note: Here clang-cc is the "low-level" frontend - executable that is similar in purpose to cc1. Clang also has a high-level compiler driver that acts as a drop-in - replacement for gcc.

    Note that the C front-end uses LLVM, but does not depend on llvm-gcc. If you @@ -159,10 +149,8 @@ Visual Studio:

  • Build Clang:
  • Try it out (assuming you added llvm/debug/bin to your path). (See the running examples from above.)
  • @@ -175,13 +163,11 @@ Visual Studio:

    to the latest code base, use the svn update command in both the llvm and llvm\tools\clang directories, as they are separate repositories.

    -

    High-Level Compiler Driver (Drop-in Substitute for GCC)

    +

    Clang Compiler Driver (Drop-in Substitute for GCC)

    -

    While the clang-cc executable is a low-level frontend executable -that can perform code generation, program analysis, and other actions, it is not -designed to be a drop-in replacement for GCC's cc. For this purpose, -use the high-level driver, aptly named clang. Here are some -examples of how to use the high-level driver: +

    The clang tool is the compiler driver and front-end, which is +designed to be a drop-in replacement for the gcc command. Here are +some examples of how to use the high-level driver:

    @@ -201,12 +187,6 @@ hello world
     
     

    Examples of using Clang

    -

    The high-level driver clang is designed to understand most of GCC's -options, and the lower-level clang-cc executable also directly takes -many of GCC's options. You can see which options clang-cc accepts with -'clang-cc --help'. Here are a few examples of using clang and -clang-cc:

    -