summaryrefslogtreecommitdiffstats
path: root/clang/lib
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2010-10-15 00:01:39 +0000
committerDan Gohman <gohman@apple.com>2010-10-15 00:01:39 +0000
commitd65c1964393cd645310427f7d25ab9e46052f1b7 (patch)
tree6598d6f4e2a34e2b0631a5db7b3e32ffbe4b57a2 /clang/lib
parent72911e49fa5589b6e7820bef4061a16d8d0354e4 (diff)
downloadbcm5719-llvm-d65c1964393cd645310427f7d25ab9e46052f1b7.tar.gz
bcm5719-llvm-d65c1964393cd645310427f7d25ab9e46052f1b7.zip
Add a TBAA type for pointer types.
llvm-svn: 116544
Diffstat (limited to 'clang/lib')
-rw-r--r--clang/lib/CodeGen/CodeGenTBAA.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/clang/lib/CodeGen/CodeGenTBAA.cpp b/clang/lib/CodeGen/CodeGenTBAA.cpp
index bff9fa2605b..ed2b13f11cc 100644
--- a/clang/lib/CodeGen/CodeGenTBAA.cpp
+++ b/clang/lib/CodeGen/CodeGenTBAA.cpp
@@ -77,6 +77,10 @@ CodeGenTBAA::getTBAAInfo(QualType QTy) {
}
}
+ // For now, treat all pointers as equivalent to each other.
+ if (Ty->isPointerType())
+ return MetadataCache[Ty] = getTBAAInfoForNamedType("TBAA.pointer", Char);
+
// For now, handle any other kind of type conservatively.
return MetadataCache[Ty] = Char;
}
OpenPOWER on IntegriCloud