mirror of
https://github.com/RPCSX/llvm.git
synced 2025-01-26 22:45:05 +00:00
[Utils] Simplify combineMetadata
Use a range-based for loop, no functional change is intended. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@276600 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
6b25086f00
commit
2d83d8a394
@ -1586,10 +1586,10 @@ void llvm::combineMetadata(Instruction *K, const Instruction *J,
|
||||
SmallVector<std::pair<unsigned, MDNode *>, 4> Metadata;
|
||||
K->dropUnknownNonDebugMetadata(KnownIDs);
|
||||
K->getAllMetadataOtherThanDebugLoc(Metadata);
|
||||
for (unsigned i = 0, n = Metadata.size(); i < n; ++i) {
|
||||
unsigned Kind = Metadata[i].first;
|
||||
for (const auto &MD : Metadata) {
|
||||
unsigned Kind = MD.first;
|
||||
MDNode *JMD = J->getMetadata(Kind);
|
||||
MDNode *KMD = Metadata[i].second;
|
||||
MDNode *KMD = MD.second;
|
||||
|
||||
switch (Kind) {
|
||||
default:
|
||||
|
Loading…
x
Reference in New Issue
Block a user