git: 9front

Download patch

ref: 2b8f51b7ccd798182b680b870138d0298fd3aca7
parent: a778aca8bed0b647fcfecdebf1252986b0183304
author: cinap_lenrek <cinap_lenrek@felloff.net>
date: Sun Aug 14 14:52:18 EDT 2016

6c: subsitute floating point registers eleminating MOVSD and MOVSS instructions in peephole pass

--- a/sys/src/cmd/6c/peep.c
+++ b/sys/src/cmd/6c/peep.c
@@ -440,6 +440,11 @@
 		case AADDQ:
 		case AADCL:
 		case AADCQ:
+
+		case AADDSS:
+		case AADDSD:
+		case AMULSS:
+		case AMULSD:
 			/*
 			 * can swap when:
 			 *  ADD R2, R1
@@ -472,6 +477,9 @@
 		case AMOVWQSX:
 		case AMOVLQZX:
 		case AMOVLQSX:
+
+		case AMOVSS:
+		case AMOVSD:
 			if(p->to.type == v1->type)
 				goto gotit;
 			break;
--