diff options
author | Douglas Gregor <dgregor@apple.com> | 2012-10-11 17:41:54 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2012-10-11 17:41:54 +0000 |
commit | 3ab50fe3fc8311fb68c4f5eb97e9bb3d0041bf1a (patch) | |
tree | 7ca68fb742508c859da0e4714b7d3f142f433f22 /include/clang/Serialization | |
parent | e9652bf15246d6e08e953b52cdb7812ddb8a43e0 (diff) |
Introduce a simple "hint" scheme to eliminate the quadratic behavior
associated with deserializing macro history for an identifier.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@165729 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Serialization')
-rw-r--r-- | include/clang/Serialization/ASTReader.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/clang/Serialization/ASTReader.h b/include/clang/Serialization/ASTReader.h index 2a9afc92e9..4e8531a820 100644 --- a/include/clang/Serialization/ASTReader.h +++ b/include/clang/Serialization/ASTReader.h @@ -1433,7 +1433,7 @@ public: unsigned LocalID); /// \brief Retrieve the macro with the given ID. - MacroInfo *getMacro(serialization::MacroID ID); + MacroInfo *getMacro(serialization::MacroID ID, MacroInfo *Hint = 0); /// \brief Retrieve the global macro ID corresponding to the given local /// ID within the given module file. @@ -1582,7 +1582,7 @@ public: Expr *ReadSubExpr(); /// \brief Reads the macro record located at the given offset. - void ReadMacroRecord(ModuleFile &F, uint64_t Offset); + void ReadMacroRecord(ModuleFile &F, uint64_t Offset, MacroInfo *Hint = 0); /// \brief Determine the global preprocessed entity ID that corresponds to /// the given local ID within the given module. |