{"retlo+12(FP)", "retlo+12(FP)"},
{"runtime·_sfloat2(SB)", "runtime._sfloat2(SB)"},
{"·AddUint32(SB)", "\"\".AddUint32(SB)"},
+ {"(R1, R3)", "(R1, R3)"},
}
var ppc64OperandTests = []operandTest{
{"$runtime·badsystemstack(SB)", "$runtime.badsystemstack(SB)"},
{"ZR", "ZR"},
{"(ZR)", "(ZR)"},
+ {"(R29, RSP)", "(R29, RSP)"},
}
char := p.arch.Thechar
switch p.next().ScanToken {
case ',':
- if char != '5' {
+ if char != '5' && char != '7' {
p.errorf("illegal register pair syntax")
return
}
a.Reg = r1
if r2 != 0 {
// TODO: Consistency in the encoding would be nice here.
- if p.arch.Thechar == '5' {
- // Special form for ARM: destination register pair (R1, R2).
+ if p.arch.Thechar == '5' || p.arch.Thechar == '7' {
+ // Special form
+ // ARM: destination register pair (R1, R2).
+ // ARM64: register pair (R1, R2) for LDP/STP.
if prefix != 0 || scale != 0 {
p.errorf("illegal address mode for register pair")
return
}
a.Type = obj.TYPE_REGREG
a.Offset = int64(r2)
- // Nothing may follow; this is always a pure destination.
+ // Nothing may follow
return
}
if p.arch.Thechar == '9' {