IR: Use remove_if for Instruction::dropUnknownMetadata()
authorDuncan P. N. Exon Smith <dexonsmith@apple.com>
Fri, 24 Apr 2015 20:23:44 +0000 (20:23 +0000)
committerDuncan P. N. Exon Smith <dexonsmith@apple.com>
Fri, 24 Apr 2015 20:23:44 +0000 (20:23 +0000)
commit9cd7a4b72d2844550108d3da0b94b525428124fa
treee5fe4c7afabb089cb22c7e3ef3e423239d5198ff
parentd8c574a5a4f9b9aa8220f34842903a7049de917d
IR: Use remove_if for Instruction::dropUnknownMetadata()

Technically the operations are different -- the old logic moved items
from the back into the opened-up slots, instead of the usual
`remove_if()` logic of a slow and a fast iterator -- but unless a
profile tells us otherwise I prefer the simpler logic here.  Regardless,
there shouldn't be an observable function change.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235767 91177308-0d34-0410-b5e6-96231b3b80d8
lib/IR/Metadata.cpp