// license that can be found in the LICENSE file.
TEXT errors(SB),$0
+ MOV $errors(SB), (X5) // ERROR "unsupported addr MOV"
+ MOV $8(SP), (X5) // ERROR "unsupported addr MOV"
+ MOVB $8(SP), X5 // ERROR "unsupported addr MOV"
+ MOVH $8(SP), X5 // ERROR "unsupported addr MOV"
+ MOVW $8(SP), X5 // ERROR "unsupported addr MOV"
+ MOVF $8(SP), X5 // ERROR "unsupported addr MOV"
+ MOV $1234, 0(SP) // ERROR "constant load must target register"
+ MOV $1234, 8(SP) // ERROR "constant load must target register"
MOV $0, 0(SP) // ERROR "constant load must target register"
MOV $0, 8(SP) // ERROR "constant load must target register"
MOV $1234, 0(SP) // ERROR "constant load must target register"
MOVH $1, X5 // ERROR "unsupported constant load"
MOVW $1, X5 // ERROR "unsupported constant load"
MOVF $1, X5 // ERROR "unsupported constant load"
+ MOVBU X5, (X6) // ERROR "unsupported unsigned store"
+ MOVHU X5, (X6) // ERROR "unsupported unsigned store"
+ MOVWU X5, (X6) // ERROR "unsupported unsigned store"
+
RET
switch p.As {
case AMOVBU, AMOVHU, AMOVWU:
ctxt.Diag("unsupported unsigned store at %v", p)
+ return
}
switch p.To.Name {
case obj.NAME_AUTO, obj.NAME_PARAM, obj.NAME_NONE:
case AMOV, AMOVB, AMOVH, AMOVW, AMOVBU, AMOVHU, AMOVWU, AMOVF, AMOVD:
// Handle register to register moves.
if p.From.Type != obj.TYPE_REG || p.To.Type != obj.TYPE_REG {
- break
+ return nil
}
switch p.As {
case AMOV: // MOV Ra, Rb -> ADDI $0, Ra, Rb