test/codegen: test negation on add/sub on riscv64
diff --git a/test/codegen/arithmetic.go b/test/codegen/arithmetic.go
index 7055db3..b88da3a 100644
--- a/test/codegen/arithmetic.go
+++ b/test/codegen/arithmetic.go
@@ -176,20 +176,26 @@
// mips:"SUB",-"ADD"
// mips64:"SUBV",-"ADDV"
// loong64:"SUBV",-"ADDV"
+ // riscv64:"SUB",-"ADD"
r := (a + b) - (a + c)
// amd64:-"ADDQ"
+ // riscv64:-"ADD"
r1 := (a + b) - (c + a)
// amd64:-"ADDQ"
+ // riscv64:-"ADD"
r2 := (b + a) - (a + c)
// amd64:-"ADDQ"
+ // riscv64:-"ADD"
r3 := (b + a) - (c + a)
// amd64:-"SUBQ"
// arm64:-"SUB"
// mips:"ADD",-"SUB"
// mips64:"ADDV",-"SUBV"
// loong64:"ADDV",-"SUBV"
+ // riscv64:"ADD",-"SUB"
r4 := (a - c) + (c + b)
// amd64:-"SUBQ"
+ // riscv64:-"SUB"
r5 := (a - c) + (b + c)
return r, r1, r2, r3, r4, r5
}
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
// riscv64:-"ADD"Seems like this (and the next two) should be `"SUB",-"ADD"` (or just `-"ADD"` above).
// riscv64:-"SUB"Same here with `"ADD","-SUB"` (or just `-"SUB"` above).
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Commit-Queue | +1 |
Seems like this (and the next two) should be `"SUB",-"ADD"` (or just `-"ADD"` above).
Done
Same here with `"ADD","-SUB"` (or just `-"SUB"` above).
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +2 |
test/codegen: test negation on add/sub on riscv64```suggestion
test/codegen: test negation with add/sub on riscv64
```
// riscv64:"SUB" -"ADD"Still an extra SUB here - this should just be `-"ADD"` if we're matching what is done for amd64/arm64.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Commit-Queue | +1 |
```suggestion
test/codegen: test negation with add/sub on riscv64
```
Done
Still an extra SUB here - this should just be `-"ADD"` if we're matching what is done for amd64/arm64.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Commit-Queue | +1 |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |