summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
df57a67)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@250266
91177308-0d34-0410-b5e6-
96231b3b80d8
getAssembler().getEmitter().encodeInstruction(Inst, VecOS, Fixups, STI);
// Add the fixups and data.
getAssembler().getEmitter().encodeInstruction(Inst, VecOS, Fixups, STI);
// Add the fixups and data.
- for (unsigned i = 0, e = Fixups.size(); i != e; ++i) {
- Fixups[i].setOffset(Fixups[i].getOffset() + DF->getContents().size());
- DF->getFixups().push_back(Fixups[i]);
+ for (MCFixup &Fixup : Fixups) {
+ Fixup.setOffset(Fixup.getOffset() + DF->getContents().size());
+ DF->getFixups().push_back(Fixup);
}
DF->getContents().append(Code.begin(), Code.end());
}
}
DF->getContents().append(Code.begin(), Code.end());
}
// Set the fragment atom associations by tracking the last seen atom defining
// symbol.
// Set the fragment atom associations by tracking the last seen atom defining
// symbol.
- for (MCAssembler::iterator it = getAssembler().begin(),
- ie = getAssembler().end(); it != ie; ++it) {
+ for (MCSection &Sec : getAssembler()) {
const MCSymbol *CurrentAtom = nullptr;
const MCSymbol *CurrentAtom = nullptr;
- for (MCSection::iterator it2 = it->begin(), ie2 = it->end(); it2 != ie2;
- ++it2) {
- if (const MCSymbol *Symbol = DefiningSymbolMap.lookup(&*it2))
+ for (MCFragment &Frag : Sec) {
+ if (const MCSymbol *Symbol = DefiningSymbolMap.lookup(&Frag))
- it2->setAtom(CurrentAtom);
+ Frag.setAtom(CurrentAtom);