[GISel]: Fix undefined behavior in IRTranslator
authorAditya Nandakumar <aditya_nandakumar@apple.com>
Wed, 17 May 2017 17:41:55 +0000 (17:41 +0000)
committerAditya Nandakumar <aditya_nandakumar@apple.com>
Wed, 17 May 2017 17:41:55 +0000 (17:41 +0000)
commitbe9299371038c881248296a2051b66c977dbd419
tree6d8a35e661c52861652d200596bf0025c30235f3
parent3f55f7e02d447bdbf6500840e85bb6dd8a72516c
[GISel]: Fix undefined behavior in IRTranslator

Make sure IRTranslator->MachineIRBuilder->DebugLoc doesn't
outlive the DILocation. Clear it at the end of
IRTranslator::runOnMachineFunction

llvm-svn: 303277
llvm/lib/CodeGen/GlobalISel/IRTranslator.cpp