mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-08-22 10:29:35 +00:00
Use const vector references instead of a vector copy. Spotted by Devang.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@147694 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
547abbb40b
commit
fa03db0d2d
@ -1767,7 +1767,7 @@ void DwarfDebug::emitAccelNames() {
|
||||
for (StringMap<std::vector<DIE*> >::const_iterator
|
||||
GI = Names.begin(), GE = Names.end(); GI != GE; ++GI) {
|
||||
const char *Name = GI->getKeyData();
|
||||
std::vector<DIE *> Entities = GI->second;
|
||||
const std::vector<DIE *> &Entities = GI->second;
|
||||
for (std::vector<DIE *>::const_iterator DI = Entities.begin(),
|
||||
DE = Entities.end(); DI != DE; ++DI)
|
||||
AT.AddName(Name, (*DI));
|
||||
@ -1796,7 +1796,7 @@ void DwarfDebug::emitAccelObjC() {
|
||||
for (StringMap<std::vector<DIE*> >::const_iterator
|
||||
GI = Names.begin(), GE = Names.end(); GI != GE; ++GI) {
|
||||
const char *Name = GI->getKeyData();
|
||||
std::vector<DIE *> Entities = GI->second;
|
||||
const std::vector<DIE *> &Entities = GI->second;
|
||||
for (std::vector<DIE *>::const_iterator DI = Entities.begin(),
|
||||
DE = Entities.end(); DI != DE; ++DI)
|
||||
AT.AddName(Name, (*DI));
|
||||
@ -1825,7 +1825,7 @@ void DwarfDebug::emitAccelNamespaces() {
|
||||
for (StringMap<std::vector<DIE*> >::const_iterator
|
||||
GI = Names.begin(), GE = Names.end(); GI != GE; ++GI) {
|
||||
const char *Name = GI->getKeyData();
|
||||
std::vector<DIE *> Entities = GI->second;
|
||||
const std::vector<DIE *> &Entities = GI->second;
|
||||
for (std::vector<DIE *>::const_iterator DI = Entities.begin(),
|
||||
DE = Entities.end(); DI != DE; ++DI)
|
||||
AT.AddName(Name, (*DI));
|
||||
@ -1860,7 +1860,7 @@ void DwarfDebug::emitAccelTypes() {
|
||||
for (StringMap<std::vector<std::pair<DIE*, unsigned> > >::const_iterator
|
||||
GI = Names.begin(), GE = Names.end(); GI != GE; ++GI) {
|
||||
const char *Name = GI->getKeyData();
|
||||
std::vector<std::pair<DIE *, unsigned> > Entities = GI->second;
|
||||
const std::vector<std::pair<DIE *, unsigned> > &Entities = GI->second;
|
||||
for (std::vector<std::pair<DIE *, unsigned> >::const_iterator DI
|
||||
= Entities.begin(), DE = Entities.end(); DI !=DE; ++DI)
|
||||
AT.AddName(Name, (*DI).first, (*DI).second);
|
||||
|
Loading…
Reference in New Issue
Block a user