Lines Matching +refs:clang +refs:prefix +refs:header
12 Using Precompiled Headers with ``clang``
15 The Clang compiler frontend, ``clang -cc1``, supports two command line options
18 To generate PCH files using ``clang -cc1``, use the option :option:`-emit-pch`:
22 $ clang -cc1 test.h -emit-pch -o test.h.pch
24 This option is transparently used by ``clang`` when generating PCH files. The
27 file can then be used as a prefix header with the :option:`-include-pch`
32 $ clang -cc1 -include-pch test.h.pch test.c -o test.s
42 header (PCH file). Then, when compiling the source files in the project, we
43 load the PCH file first (as a prefix header), which acts as a stand-in for that
46 A precompiled header implementation improves performance when:
49 headers stored within the PCH file. Thus, a precompiled header design
51 should not vary with the size of the precompiled header file.
63 headers. In particular, there can only be one precompiled header and it must
79 larger AST file does not lead to longer AST load times. The actual header data
89 simple "Hello, World!" program that includes the Apple ``Cocoa.h`` header
90 (which is built as a precompiled header), this option illustrates how little of
91 the actual precompiled header is required:
110 precompiled header. These statistics can be useful to determine whether the
147 an AST file. For example, a precompiled header built for a 32-bit x86 target
165 precompiled header (and vice-versa).
168 The full path of the header that was used to generate the AST file.
209 instantiation history inside the header itself.
213 the controlling macro for the header (e.g., when the preprocessor identified
214 that the contents of the header dependent on a macro like
224 defined by the end of the header used to build the AST file, along with the
266 within the precompiled header where that declaration is described.
291 ``p->x``, where ``p``'s type is defined in the precompiled header), Clang
456 of reparsing required after a change to the file, a form of precompiled header
463 compilation of that translation unit may already use a precompiled header: in
465 header that refers to the original precompiled header. This drastically
469 Chained precompiled headers get their name because each precompiled header can
470 depend on one other precompiled header, forming a chain of dependencies. A
471 translation unit will then include the precompiled header that starts the chain
474 precompiled header can provide information that overrides the information
475 provided by the precompiled headers it depends on, just like a header file
476 ``B.h`` that includes another header ``A.h`` can modify the state produced by
485 grow upward. Each precompiled header records the maximum ID number it has
486 assigned in each category. Then, when a new precompiled header is generated
487 that depends on (chains to) another precompiled header, it will start
492 When writing a chained precompiled header, Clang attempts to write only
493 information that has changed from the precompiled header on which it is
496 most-recent precompiled header. If no entry is found, lookup then proceeds
497 to the identifier table in the precompiled header it depends on, and so one.
502 There are various ways in which a later precompiled header can modify the
503 entities described in an earlier precompiled header. For example, later
507 stored in the chained precompiled header file and will be loaded along with
515 Modules generalize the chained precompiled header model yet further, from a