Skip to content

Commit dcbd219

Browse files
Update DecoderEmitter.cpp
1 parent 466e392 commit dcbd219

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

llvm/utils/TableGen/DecoderEmitter.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1893,7 +1893,7 @@ OperandInfo getOpInfo(const Record *TypeRecord) {
18931893
bool HasCompleteDecoder =
18941894
HasCompleteDecoderBit ? HasCompleteDecoderBit->getValue() : true;
18951895

1896-
return OperandInfo(Decoder, HasCompleteDecoder);
1896+
return OperandInfo(std::move(Decoder), HasCompleteDecoder);
18971897
}
18981898

18991899
static void parseVarLenInstOperand(const Record &Def,
@@ -2024,7 +2024,7 @@ populateInstruction(const CodeGenTarget &Target, const Record &EncodingDef,
20242024
EncodingDef.getValueAsBit("hasCompleteDecoder");
20252025
InsnOperands.push_back(
20262026
OperandInfo(std::string(InstDecoder), HasCompleteInstDecoder));
2027-
Operands[Opc] = InsnOperands;
2027+
Operands[Opc] = std::move(InsnOperands);
20282028
return Bits.getNumBits();
20292029
}
20302030

@@ -2059,7 +2059,7 @@ populateInstruction(const CodeGenTarget &Target, const Record &EncodingDef,
20592059
MyName = Op.Name;
20602060

20612061
TiedNames[MyName] = TiedName;
2062-
TiedNames[TiedName] = MyName;
2062+
TiedNames[TiedName] = std::move(MyName);
20632063
}
20642064
}
20652065
}
@@ -2112,7 +2112,7 @@ populateInstruction(const CodeGenTarget &Target, const Record &EncodingDef,
21122112

21132113
addOneOperandFields(EncodingDef, Bits, TiedNames, SubOpName,
21142114
SubOpInfo);
2115-
InsnOperands.push_back(SubOpInfo);
2115+
InsnOperands.push_back(std::move(SubOpInfo));
21162116
}
21172117
continue;
21182118
}
@@ -2143,7 +2143,7 @@ populateInstruction(const CodeGenTarget &Target, const Record &EncodingDef,
21432143
// instruction! (This is a longstanding bug, which will be addressed in an
21442144
// upcoming change.)
21452145
if (OpInfo.numFields() > 0)
2146-
InsnOperands.push_back(OpInfo);
2146+
InsnOperands.push_back(std::move(OpInfo));
21472147
}
21482148
}
21492149
Operands[Opc] = InsnOperands;

0 commit comments

Comments
 (0)