From: Chris Lattner Date: Mon, 11 May 2009 22:45:37 +0000 (+0000) Subject: pull a bunch of options out of clang-cc.cpp. This doesn't include X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=482c682256f7893381c13e770f21ba9a260a5736;p=clang pull a bunch of options out of clang-cc.cpp. This doesn't include options that the driver swizzles. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@71487 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/docs/tools/Makefile b/docs/tools/Makefile index 48a4e704ad..90eb7768f5 100644 --- a/docs/tools/Makefile +++ b/docs/tools/Makefile @@ -63,7 +63,7 @@ endif $(DST_HTML_DIR)%.html: %.pod $(DST_HTML_DIR)/.dir pod2html --css=manpage.css --htmlroot=. \ - --podpath=. --noindex --infile=$< --outfile=$@ --title=$* + --podpath=. --infile=$< --outfile=$@ --title=$* $(DST_MAN_DIR)%.1: %.pod $(DST_MAN_DIR)/.dir pod2man --release "clang 1.0" --center="Clang Tools Documentation" $< $@ diff --git a/docs/tools/clang.pod b/docs/tools/clang.pod index 3a2c2a4c48..7be5a23064 100644 --- a/docs/tools/clang.pod +++ b/docs/tools/clang.pod @@ -49,16 +49,17 @@ parse errors. The output of this stage is an "Abstract Syntax Tree" (AST). =item B -This stage translates an AST into low-level intermediate code or machine code -(depending on the optimization level). This phase is responsible for optimizing -the generated code and handling target-specfic code generation. The output of -this stage is typically called a ".s" file. +This stage translates an AST into low-level intermediate code (known as "LLVM +IR") and ultimately to machine code (depending on the optimization level). This +phase is responsible for optimizing the generated code and handling +target-specfic code generation. The output of this stage is typically called a +".s" file or "assembly" file. =item B This stage runs the target assembler to translate the output of the compiler into a target object file. The output of this stage is typically called a ".o" -file. +file or "object" file. =item B @@ -69,7 +70,7 @@ executable or dynamic library. The output of this stage is typically called an =back The Clang compiler supports a large number of options to control each of these -stages. In addition to compilation of code, Clang also supports other tools. +stages. In addition to compilation of code, Clang also supports other tools: B @@ -131,14 +132,6 @@ Print the commands to run for this compilation. Display available options. -=item B<-ObjC++> - -Treat source input files as Objective-C++ inputs. - -=item B<-ObjC> - -Treat source input files as Objective-C inputs. - =item B<-Qunused-arguments> Don't emit warning for unused driver arguments. @@ -203,25 +196,134 @@ Save intermediate compilation results. Time individual commands. +=item B<-ftime-report> + +Print timing summary of each stage of compilation. + =item B<-v> Show commands to run and use verbose output. +=back + + + +=head2 Target Selection Options + +=over + +-triple +-arch +-mmacosx-version-min=10.3.9 +-miphoneos-version-min + + +=back + + + +=head2 Language Selection and Mode Options + +=over + =item B<-x> I Treat subsequent input files as having type I. +=item B<-ObjC++> + +Treat source input files as Objective-C++ inputs. + +=item B<-ObjC> + +Treat source input files as Objective-C inputs. + +B<-std>=I + + +-ffreestanding +-fno-builtin +-fmath-errno +-fobjc-gc-only +-fobjc-gc +-fpascal-strings +-fms-extensions +-fwritable-strings +-fno-lax-vector-conversions +-fblocks +-trigraphs + =back +=head2 Code Generation Options + +=over + +-fexceptions +-fobjc-nonfragile-abi +-fgnu-runtime +-fnext-runtime +-ftrapv +-fvisibility +-Os, O0, O1, O2, O3, O4 +-fno-common +-g +-mcpu + +=back + + + + +=head2 Diagnostics Options + +=over + +-fshow-column +-fshow-source-location +-fcaret-diagnostics +-fdiagnostics-fixit-info +-fdiagnostics-print-source-range-info +-fprint-source-range-info +-fdiagnostics-show-option +-fmessage-length + + +=back =head2 Preprocessor Options =over +=item B<-xyz> + +Frob + +-D +-U +-include +-imacros + + + +-nostdinc +-F +-I +-idirafter +-iquote +-isystem +-iprefix +-iwithprefix +-iwithprefixbefore +-isysroot + + + + =back @@ -235,6 +337,8 @@ Treat subsequent input files as having type I. + + =head2 Code Generation and Optimization Options =over @@ -242,6 +346,10 @@ Treat subsequent input files as having type I. =back + + + + =head2 Assembler Options =over @@ -249,6 +357,10 @@ Treat subsequent input files as having type I. =back + + + + =head2 Linker Options =over @@ -256,6 +368,17 @@ Treat subsequent input files as having type I. =back + + + +=head2 Static Analyzer Options + +=over + +=back + + + =head1 ENVIRONMENT =over @@ -280,10 +403,11 @@ B These environment variables specify additional paths, as for CPATH, which are only used when processing the appropriate language. -=item B (Apple only) +=item B If -mmacosx-version-min is unspecified, the default deployment target -is read from this environment variable. +is read from this environment variable. This option only affects darwin +targets. =back @@ -296,7 +420,7 @@ the compiler, along with information to reproduce. =head1 SEE ALSO -as(1), ld(1) + as(1), ld(1) =head1 AUTHOR