git: 9front

Download patch

ref: 52f7b0c152ee5b0ae61c5a1a196b5ec12baaecdb
parent: 8ba9aaff9af9cb70432e50ee9d8e3270e01e9d48
author: Sigrid Solveig Haflínudóttir <sigrid@ftrv.se>
date: Tue May 9 14:53:53 EDT 2023

7c: peephole: ACASE needs two distinctive registers - nothing to optimize

--- a/sys/src/cmd/7c/peep.c
+++ b/sys/src/cmd/7c/peep.c
@@ -1122,7 +1122,6 @@
 	case AFABSS:
 	case AFSQRTD:
 	case AFSQRTS:
-	case ACASE:
 #ifdef YYY
 		if(p->scond&(C_WBIT|C_PBIT))
 		if(v->type == D_REG) {
@@ -1303,6 +1302,9 @@
 		if(v->type == D_REG)
 			if(v->reg == REGARG)
 				return 3;
+		return 0;
+
+	case ACASE:
 		return 0;
 	}
 }
--