]> granicus.if.org Git - clang/commitdiff
Add # of block pointer types to -print-stats.
authorDaniel Dunbar <daniel@zuster.org>
Fri, 26 Sep 2008 03:23:00 +0000 (03:23 +0000)
committerDaniel Dunbar <daniel@zuster.org>
Fri, 26 Sep 2008 03:23:00 +0000 (03:23 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@56638 91177308-0d34-0410-b5e6-96231b3b80d8

lib/AST/ASTContext.cpp

index b0ce9eb26dad0ee68fbe6037058e133978dc0ca9..feb1bad4f95943d38f3b1ddc3abf99c57171c41a 100644 (file)
@@ -54,7 +54,7 @@ void ASTContext::PrintStats() const {
   fprintf(stderr, "*** AST Context Stats:\n");
   fprintf(stderr, "  %d types total.\n", (int)Types.size());
   unsigned NumBuiltin = 0, NumPointer = 0, NumArray = 0, NumFunctionP = 0;
-  unsigned NumVector = 0, NumComplex = 0;
+  unsigned NumVector = 0, NumComplex = 0, NumBlockPointer = 0;
   unsigned NumFunctionNP = 0, NumTypeName = 0, NumTagged = 0, NumReference = 0;
   
   unsigned NumTagStruct = 0, NumTagUnion = 0, NumTagEnum = 0, NumTagClass = 0;
@@ -68,6 +68,8 @@ void ASTContext::PrintStats() const {
       ++NumBuiltin;
     else if (isa<PointerType>(T))
       ++NumPointer;
+    else if (isa<BlockPointerType>(T))
+      ++NumBlockPointer;
     else if (isa<ReferenceType>(T))
       ++NumReference;
     else if (isa<ComplexType>(T))
@@ -109,6 +111,7 @@ void ASTContext::PrintStats() const {
 
   fprintf(stderr, "    %d builtin types\n", NumBuiltin);
   fprintf(stderr, "    %d pointer types\n", NumPointer);
+  fprintf(stderr, "    %d block pointer types\n", NumBlockPointer);
   fprintf(stderr, "    %d reference types\n", NumReference);
   fprintf(stderr, "    %d complex types\n", NumComplex);
   fprintf(stderr, "    %d array types\n", NumArray);