Browse code

Removed JSR JMP2r tail-call optimisations for now

Devine Lu Linvega authored on 06/08/2022 18:05:16
Showing 1 changed files
... ...
@@ -217,14 +217,12 @@ writeopcode(char *w)
217 217
 {
218 218
 	Uint8 res;
219 219
 	if(jsrlast && scmp(w, "JMP2r", 5)) { /* tail-call optimization */
220
-		p.data[p.ptr - 1] = jsrlast == 2 ? findopcode("JMP2") : findopcode("JMP");
220
+		p.data[p.ptr - 1] = findopcode("JMP2");
221 221
 		jsrlast = 0;
222 222
 		return 1;
223 223
 	}
224 224
 	res = writebyte(findopcode(w));
225 225
 	if(scmp(w, "JSR2", 4))
226
-		jsrlast = 2;
227
-	else if(scmp(w, "JSR", 3))
228 226
 		jsrlast = 1;
229 227
 	return res;
230 228
 }