forked from OSchip/llvm-project
CodeGenSchedule: Use resize instead of copying a vector
llvm-svn: 183465
This commit is contained in:
parent
a30936a33b
commit
f84a03a589
|
@ -1173,8 +1173,8 @@ pushVariant(const TransVariant &VInfo, bool IsRead) {
|
||||||
// Make N-1 copies of this transition's last sequence.
|
// Make N-1 copies of this transition's last sequence.
|
||||||
for (unsigned i = 1, e = SelectedRWs.size(); i != e; ++i) {
|
for (unsigned i = 1, e = SelectedRWs.size(); i != e; ++i) {
|
||||||
// Create a temporary copy the vector could reallocate.
|
// Create a temporary copy the vector could reallocate.
|
||||||
SmallVector<unsigned, 4> Tmp = RWSequences[OperIdx];
|
RWSequences.reserve(RWSequences.size() + 1);
|
||||||
RWSequences.push_back(Tmp);
|
RWSequences.push_back(RWSequences[OperIdx]);
|
||||||
}
|
}
|
||||||
// Push each of the N elements of the SelectedRWs onto a copy of the last
|
// Push each of the N elements of the SelectedRWs onto a copy of the last
|
||||||
// sequence (split the current operand into N operands).
|
// sequence (split the current operand into N operands).
|
||||||
|
|
Loading…
Reference in New Issue