mirror of
https://github.com/intel/llvm.git
synced 2026-02-08 08:57:43 +08:00
[CodeGen] Have a special function to get TBAA info for may-alias accesses
This is part of D37826 reworked to be a separate patch to simplify review. Differential Revision: https://reviews.llvm.org/D38408 llvm-svn: 314660
This commit is contained in:
@@ -599,6 +599,12 @@ llvm::MDNode *CodeGenModule::getTBAAStructTagInfo(QualType BaseTy,
|
||||
return TBAA->getTBAAStructTagInfo(BaseTy, AccessN, O);
|
||||
}
|
||||
|
||||
llvm::MDNode *CodeGenModule::getTBAAMayAliasTypeInfo() {
|
||||
if (!TBAA)
|
||||
return nullptr;
|
||||
return TBAA->getMayAliasTypeInfo();
|
||||
}
|
||||
|
||||
/// Decorate the instruction with a TBAA tag. For both scalar TBAA
|
||||
/// and struct-path aware TBAA, the tag has the same format:
|
||||
/// base type, access type and offset.
|
||||
|
||||
Reference in New Issue
Block a user