aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/CGDebugInfo.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2010-03-18 17:52:52 +0000
committerDouglas Gregor <dgregor@apple.com>2010-03-18 17:52:52 +0000
commit4ae8f298b1ea51b4c2234f9148e2e4349c9bdd23 (patch)
tree115d68779b45333b43c5c5937a41f292b58dc666 /lib/CodeGen/CGDebugInfo.cpp
parent7c647a1270cbe02f5e64cee9e3f3ddc176ed61e9 (diff)
Introduce the notion of a "preprocessing record", which keeps track of
the macro definitions and macro instantiations that are found during preprocessing. Preprocessing records are *not* generated by default; rather, we provide a PPCallbacks subclass that hooks into the existing callback mechanism to record this activity. The only client of preprocessing records is CIndex, which keeps track of macro definitions and instantations so that they can be exposed via cursors. At present, only token annotation uses these facilities, and only for macro instantiations; both will change in the near future. However, with this change, token annotation properly annotates macro instantiations that do not produce any tokens and instantiations of macros that are later undef'd, improving our consistency. Preprocessing directives that are not macro definitions are still handled by clang_annotateTokens() via re-lexing, so that we don't have to track every preprocessing directive in the preprocessing record. Performance impact of preprocessing records is still TBD, although it is limited to CIndex and therefore out of the path of the main compiler. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@98836 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGDebugInfo.cpp')
0 files changed, 0 insertions, 0 deletions