forked from OSchip/llvm-project
[AMDGPU] AsmParser: refactor post push_back vector access. NFC.
llvm-svn: 263409
This commit is contained in:
parent
b9456a5eb3
commit
9e33c7f5d3
|
@ -1106,14 +1106,13 @@ AMDGPUAsmParser::parseOperand(OperandVector &Operands, StringRef Mnemonic) {
|
||||||
Parser.Lex();
|
Parser.Lex();
|
||||||
Modifiers |= 0x2;
|
Modifiers |= 0x2;
|
||||||
}
|
}
|
||||||
Operands.push_back(AMDGPUOperand::CreateReg(
|
auto R = AMDGPUOperand::CreateReg(RegNo, S, E,
|
||||||
RegNo, S, E, getContext().getRegisterInfo(), &getSTI(),
|
getContext().getRegisterInfo(),
|
||||||
isForcedVOP3()));
|
&getSTI(), isForcedVOP3());
|
||||||
|
|
||||||
if (Modifiers) {
|
if (Modifiers) {
|
||||||
AMDGPUOperand &RegOp = ((AMDGPUOperand&)*Operands[Operands.size() - 1]);
|
R->setModifiers(Modifiers);
|
||||||
RegOp.setModifiers(Modifiers);
|
|
||||||
}
|
}
|
||||||
|
Operands.push_back(std::move(R));
|
||||||
} else {
|
} else {
|
||||||
ResTy = parseVOP3OptionalOps(Operands);
|
ResTy = parseVOP3OptionalOps(Operands);
|
||||||
if (ResTy == MatchOperand_NoMatch) {
|
if (ResTy == MatchOperand_NoMatch) {
|
||||||
|
|
Loading…
Reference in New Issue