mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-08-05 13:26:55 +00:00
rename getMDKind -> getMDKindID, make it autoinsert if an MD Kind
doesn't exist already, eliminate registerMDKind. Tidy up a bunch of random stuff. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92225 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -1119,7 +1119,7 @@ Instruction *DIFactory::InsertDbgValueIntrinsic(Value *V, Value *Offset,
|
||||
void DebugInfoFinder::processModule(Module &M) {
|
||||
|
||||
MetadataContext &TheMetadata = M.getContext().getMetadata();
|
||||
unsigned MDDbgKind = TheMetadata.getMDKind("dbg");
|
||||
unsigned MDDbgKind = TheMetadata.getMDKindID("dbg");
|
||||
|
||||
for (Module::iterator I = M.begin(), E = M.end(); I != E; ++I)
|
||||
for (Function::iterator FI = (*I).begin(), FE = (*I).end(); FI != FE; ++FI)
|
||||
@@ -1127,9 +1127,8 @@ void DebugInfoFinder::processModule(Module &M) {
|
||||
++BI) {
|
||||
if (DbgDeclareInst *DDI = dyn_cast<DbgDeclareInst>(BI))
|
||||
processDeclare(DDI);
|
||||
else if (MDDbgKind)
|
||||
if (MDNode *L = TheMetadata.getMD(MDDbgKind, BI))
|
||||
processLocation(DILocation(L));
|
||||
else if (MDNode *L = TheMetadata.getMD(MDDbgKind, BI))
|
||||
processLocation(DILocation(L));
|
||||
}
|
||||
|
||||
NamedMDNode *NMD = M.getNamedMetadata("llvm.dbg.gv");
|
||||
|
Reference in New Issue
Block a user