llvm-project/clang/lib/AST
Chandler Carruth ff5a01a7b1 [ptr-traits] Switch from a really wasteful SmallDenseMap of
SmallVector<.., 16> (16!!!!) objects to a simple SmallVector of pairs.

This no longer de-duplicates the common function pointers used during
deallocation, but this doesn't really seem worth the complexity and
overhead of managing the map-of-vectors. Notably, there is no reason to
assume that functions have the 4-byte alignment that DenseMap relies on,
and indeed this prevents checking the alignment of the DenseMap keys
because we can't even meaningfully query the alignment of functions
using our existing alignment tools.

Generally, function pointers don't seem like a great idea for keys in
a DenseMap. =]

I chatted with Richard Smith about this a bit as well and have written
down a FIXME because this *does* waste some memory and in general seems
a very clumsy memory management strategy. He would like to see a more
fundamental fix eventually here that tries to build a better pattern.

llvm-svn: 256610
2015-12-30 03:00:23 +00:00
..
APValue.cpp Simplify creation of a bunch of ArrayRefs by using None, makeArrayRef or just letting them be implicitly created. 2014-08-27 06:28:36 +00:00
ASTConsumer.cpp Introduce a PCHContainerOperations interface (NFC). 2015-06-20 18:53:08 +00:00
ASTContext.cpp [ptr-traits] Switch from a really wasteful SmallDenseMap of 2015-12-30 03:00:23 +00:00
ASTDiagnostic.cpp Support __builtin_ms_va_list. 2015-09-17 20:55:33 +00:00
ASTDumper.cpp Avoid crash when dumping LocInfoType. 2015-12-28 17:19:12 +00:00
ASTImporter.cpp ArrayRef-ize TemplateParameterList. NFC 2015-12-27 07:16:27 +00:00
ASTTypeTraits.cpp Fix bug in DynTypedMatcher::constructVariadic() that would cause false negatives. 2014-10-06 13:14:30 +00:00
AttrImpl.cpp Devirtualize Attr and all subclasses. 2015-03-19 16:06:49 +00:00
CMakeLists.txt Move functions declared in Stmt{ObjC,CXX}.h and OpenMPClause.h into 2015-10-02 13:41:04 +00:00
CXXABI.h [MS ABI] Correctly mangle classes without names for linkage purposes 2015-08-31 18:48:39 +00:00
CXXInheritance.cpp unique_ptrify CXXBasePaths::DeclsFound & remove the then-unnecessary user-defined dtor 2015-08-18 23:56:00 +00:00
Comment.cpp Use llvm::makeArrayRef instead of explicitly calling ArrayRef constructor and mentioning the type. This works now that we have a conversion from ArrayRef<T*> to ArrayRef<const T*>. 2014-08-30 16:55:39 +00:00
CommentBriefParser.cpp
CommentCommandTraits.cpp Fix for PR21254 - Assertion in comment parser 2014-10-15 16:18:20 +00:00
CommentLexer.cpp Comment parsing: fix an assertion failure on a verbatim block terminated with "**/" 2015-04-15 23:45:43 +00:00
CommentParser.cpp [C++11] Use 'nullptr'. AST edition. 2014-05-12 05:36:57 +00:00
CommentSema.cpp [C++11] Use 'nullptr'. AST edition. 2014-05-12 05:36:57 +00:00
Decl.cpp [ptr-traits] Stop using two bogus types as stand-ins for flags 2015-12-30 02:51:00 +00:00
DeclBase.cpp [modules] Follow the C++ standard's rule for linkage of enumerators: they have 2015-11-13 03:52:13 +00:00
DeclCXX.cpp [TrailingObjects] Convert Decl* classes. 2015-12-29 22:13:13 +00:00
DeclFriend.cpp [TrailingObjects] Convert Decl* classes. 2015-12-29 22:13:13 +00:00
DeclGroup.cpp [TrailingObjects] Convert Decl* classes. 2015-12-29 22:13:13 +00:00
DeclObjC.cpp [TrailingObjects] Convert Decl* classes. 2015-12-29 22:13:13 +00:00
DeclOpenMP.cpp [TrailingObjects] Convert Decl* classes. 2015-12-29 22:13:13 +00:00
DeclPrinter.cpp [ATTR] Automatic line feed after pragma-like attribute. 2015-10-12 06:59:48 +00:00
DeclTemplate.cpp ArrayRef-ize TemplateParameterList. NFC 2015-12-27 07:16:27 +00:00
DeclarationName.cpp When pretty-printing a C++11 literal operator, don't insert whitespace between 2015-10-08 00:17:59 +00:00
Expr.cpp [TrailingObjects] Convert CastExpr and subclasses. 2015-12-30 02:27:28 +00:00
ExprCXX.cpp [TrailingObjects] Convert CastExpr and subclasses. 2015-12-30 02:27:28 +00:00
ExprClassification.cpp [MSVC] 'property' with an empty array in array subscript expression. 2015-11-25 12:01:00 +00:00
ExprConstant.cpp [TrailingObjects] Convert OffsetOfExpr. 2015-12-29 22:31:18 +00:00
ExprObjC.cpp Move functions declared in ExprObjC.h into ExprObjC.cpp. 2015-09-29 22:28:44 +00:00
ExternalASTSource.cpp Roll-back r250822. 2015-10-20 13:23:58 +00:00
InheritViz.cpp InheritViz: Hide implementation details 2015-03-09 15:03:20 +00:00
ItaniumCXXABI.cpp [MS ABI] Correctly mangle classes without names for linkage purposes 2015-08-31 18:48:39 +00:00
ItaniumMangle.cpp Replace llvm::utostr calls in Twine context with Twines. NFC. 2015-12-24 10:07:37 +00:00
Makefile
Mangle.cpp Remove and forbid raw_svector_ostream::flush() calls. 2015-08-13 18:12:56 +00:00
MicrosoftCXXABI.cpp [MS ABI] Mangle static anonymous unions 2015-10-22 07:15:56 +00:00
MicrosoftMangle.cpp [MS ABI] Invent a mangling for reference temporaries 2015-12-29 22:25:14 +00:00
NSAPI.cpp [OpenCL] Add new types for OpenCL 2.0. 2015-09-15 11:18:52 +00:00
NestedNameSpecifier.cpp Constify NestedNameSpecifier::dump and add a no-argument dump function suitable for calling from a debugger. 2015-12-27 14:34:22 +00:00
OpenMPClause.cpp [OpenMP] Parsing and sema support for map clause 2015-11-23 05:32:03 +00:00
ParentMap.cpp Switch users of the 'for (StmtRange range = stmt->children(); range; ++range)‘ pattern to range for loops. 2015-07-02 21:03:14 +00:00
RawCommentList.cpp Allow any comment to be a trailing comment when -fparse-all-comments is on. 2015-07-15 19:13:39 +00:00
RecordLayout.cpp CXXInfo memory should be released after calling the destructor 2014-05-24 07:19:25 +00:00
RecordLayoutBuilder.cpp [CUDA] Make vtable construction aware of host/device side of CUDA compilation. 2015-12-17 18:12:36 +00:00
SelectorLocationsKind.cpp
Stmt.cpp Use std::copy and std::transform instead of manual loops. NFC 2015-12-05 07:41:42 +00:00
StmtCXX.cpp [coroutines] Creation of promise object, lookup of operator co_await, building 2015-10-27 06:02:45 +00:00
StmtIterator.cpp [ptr-traits] Stop using two bogus types as stand-ins for flags 2015-12-30 02:51:00 +00:00
StmtObjC.cpp Move functions declared in Stmt{ObjC,CXX}.h and OpenMPClause.h into 2015-10-02 13:41:04 +00:00
StmtOpenMP.cpp [OPENMP 4.5] Parsing/sema for 'hint' clause of 'critical' directive. 2015-12-15 08:19:24 +00:00
StmtPrinter.cpp [TrailingObjects] Convert OffsetOfExpr. 2015-12-29 22:31:18 +00:00
StmtProfile.cpp [TrailingObjects] Convert OffsetOfExpr. 2015-12-29 22:31:18 +00:00
StmtViz.cpp
TemplateBase.cpp [TrailingObjects] Convert AST classes that had a ASTTemplateKWAndArgsInfo. 2015-12-29 18:15:14 +00:00
TemplateName.cpp [AST] ArrayRefize template argument packs. No functionality change intended. 2015-08-05 09:40:22 +00:00
Type.cpp Don't actually add the __unsafe_unretained qualifier in MRC; 2015-11-19 02:28:03 +00:00
TypeLoc.cpp Replace double-negated !SourceLocation.isInvalid() with SourceLocation.isValid(). 2015-10-03 05:15:57 +00:00
TypePrinter.cpp Print qualified display names when emitting CodeView 2015-12-16 02:04:40 +00:00
VTTBuilder.cpp Update for LLVM API change to make Small(Ptr)Set::insert return pair<iterator, bool> as per the C++ standard's associative container concept. 2014-11-19 07:49:47 +00:00
VTableBuilder.cpp [MS ABI] Let arbitrary entities participate in vftable ordering 2015-11-19 00:03:54 +00:00