summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CodeGenTBAA.h
diff options
context:
space:
mode:
authorHal Finkel <hfinkel@anl.gov>2017-12-03 03:10:13 +0000
committerHal Finkel <hfinkel@anl.gov>2017-12-03 03:10:13 +0000
commita5986b9e91be95771a034b5efe400e99149f919c (patch)
tree6661a2270eb6f0e6bec286a186f18b382c23349e /clang/lib/CodeGen/CodeGenTBAA.h
parentf3470e1ed4f6322711f6fc059b834d2ce0094c2b (diff)
downloadbcm5719-llvm-a5986b9e91be95771a034b5efe400e99149f919c.tar.gz
bcm5719-llvm-a5986b9e91be95771a034b5efe400e99149f919c.zip
Revert "[CodeGen] Add initial support for union members in TBAA"
This reverts commit r319413. See PR35503. We can't use "union member" as the access type here like this. llvm-svn: 319629
Diffstat (limited to 'clang/lib/CodeGen/CodeGenTBAA.h')
-rw-r--r--clang/lib/CodeGen/CodeGenTBAA.h19
1 files changed, 3 insertions, 16 deletions
diff --git a/clang/lib/CodeGen/CodeGenTBAA.h b/clang/lib/CodeGen/CodeGenTBAA.h
index 7b3473fe63f..a5b1f66bcd1 100644
--- a/clang/lib/CodeGen/CodeGenTBAA.h
+++ b/clang/lib/CodeGen/CodeGenTBAA.h
@@ -34,10 +34,9 @@ class CGRecordLayout;
// TBAAAccessKind - A kind of TBAA memory access descriptor.
enum class TBAAAccessKind : unsigned {
- Ordinary, // An ordinary memory access.
- MayAlias, // An access that may alias with any other accesses.
- Incomplete, // Used to designate pointee values of incomplete types.
- UnionMember, // An access to a direct or indirect union member.
+ Ordinary,
+ MayAlias,
+ Incomplete,
};
// TBAAAccessInfo - Describes a memory access in terms of TBAA.
@@ -78,14 +77,6 @@ struct TBAAAccessInfo {
bool isIncomplete() const { return Kind == TBAAAccessKind::Incomplete; }
- static TBAAAccessInfo getUnionMemberInfo(llvm::MDNode *BaseType,
- uint64_t Offset, uint64_t Size) {
- return TBAAAccessInfo(TBAAAccessKind::UnionMember, BaseType,
- /* AccessType= */ nullptr, Offset, Size);
- }
-
- bool isUnionMember() const { return Kind == TBAAAccessKind::UnionMember; }
-
bool operator==(const TBAAAccessInfo &Other) const {
return Kind == Other.Kind &&
BaseType == Other.BaseType &&
@@ -157,10 +148,6 @@ class CodeGenTBAA {
/// considered to be equivalent to it.
llvm::MDNode *getChar();
- /// getUnionMemberType - Get metadata that represents the type of union
- /// members.
- llvm::MDNode *getUnionMemberType(uint64_t Size);
-
/// CollectFields - Collect information about the fields of a type for
/// !tbaa.struct metadata formation. Return false for an unsupported type.
bool CollectFields(uint64_t BaseOffset,
OpenPOWER on IntegriCloud