mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-25 21:18:19 +00:00
switch from pointer equality comparison to MDNode::getMostGenericTBAA
when merging two TBAA tags, pointed out by Nuno. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171627 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -46,6 +46,7 @@
|
||||
#include "llvm/IR/Instructions.h"
|
||||
#include "llvm/IR/IntrinsicInst.h"
|
||||
#include "llvm/IR/LLVMContext.h"
|
||||
#include "llvm/IR/Metadata.h"
|
||||
#include "llvm/Support/CFG.h"
|
||||
#include "llvm/Support/CommandLine.h"
|
||||
#include "llvm/Support/Debug.h"
|
||||
@@ -816,10 +817,11 @@ void LICM::PromoteAliasSet(AliasSet &AS,
|
||||
if (LoopUses.empty()) {
|
||||
// On the first load/store, just take its TBAA tag.
|
||||
TBAATag = Use->getMetadata(LLVMContext::MD_tbaa);
|
||||
} else if (TBAATag && TBAATag != Use->getMetadata(LLVMContext::MD_tbaa)) {
|
||||
TBAATag = 0;
|
||||
} else if (TBAATag) {
|
||||
TBAATag = MDNode::getMostGenericTBAA(TBAATag,
|
||||
Use->getMetadata(LLVMContext::MD_tbaa));
|
||||
}
|
||||
|
||||
|
||||
LoopUses.push_back(Use);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user