]> granicus.if.org Git - clang/commitdiff
Use a different name for pointer types in tbaa, to be a little
authorDan Gohman <gohman@apple.com>
Fri, 15 Oct 2010 20:26:20 +0000 (20:26 +0000)
committerDan Gohman <gohman@apple.com>
Fri, 15 Oct 2010 20:26:20 +0000 (20:26 +0000)
more consistent with other names, and to look less like a magic name.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116616 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/CodeGenTBAA.cpp

index a1f38be12296f9055cd00c7b04ea4b0239fbc24f..02c95c0dce497b8409f20a44b4bfad04fb5235f8 100644 (file)
@@ -85,9 +85,10 @@ CodeGenTBAA::getTBAAInfo(QualType QTy) {
     }
   }
 
-  // For now, treat all pointers as equivalent to each other.
+  // TODO: Implement C++'s type "similarity" and consider dis-"similar"
+  // pointers distinct.
   if (Ty->isPointerType())
-    return MetadataCache[Ty] = getTBAAInfoForNamedType("TBAA.pointer", Char);
+    return MetadataCache[Ty] = getTBAAInfoForNamedType("any pointer", Char);
 
   // Enum types are distinct types. In C++ they have "underlying types",
   // however they aren't related for TBAA.