summary refs log tree commit diff
path: root/lisc
diff options
context:
space:
mode:
authorQuentin Carbonneaux <quentin.carbonneaux@yale.edu>2016-02-09 16:56:36 -0500
committerQuentin Carbonneaux <quentin.carbonneaux@yale.edu>2016-02-09 16:56:36 -0500
commitc92b0268fdbf45962a52087438afca1289cd3aae (patch)
tree014687fbaffa05db001d41988bacec55440cdf9f /lisc
parent610e03f6d07d341e6d2aaa6ce3811bb5d3451b44 (diff)
downloadroux-c92b0268fdbf45962a52087438afca1289cd3aae.tar.gz
add one case in address matching
Diffstat (limited to 'lisc')
-rw-r--r--lisc/isel.c17
1 files changed, 10 insertions, 7 deletions
diff --git a/lisc/isel.c b/lisc/isel.c
index 8d80299..45f793c 100644
--- a/lisc/isel.c
+++ b/lisc/isel.c
@@ -691,13 +691,15 @@ anumber(ANum *ai, Blk *b, Con *con)
 		[2] [2] = 2,              /* folding */
 		[2] [5] = 5, [5] [2] = 5,
 		[2] [6] = 6, [6] [2] = 6,
-		[0] [0] = 4,              /* b + s * i */
-		/* [0] [1] = 4, [1] [0] = 4, */
+		[2] [7] = 7, [7] [2] = 7,
+		[0] [0] = 4,              /* 4: b + s * i */
 		[0] [3] = 4, [3] [0] = 4,
-		[2] [3] = 5, [3] [2] = 5, /* o + s * i */
-		[2] [4] = 6, [4] [2] = 6, /* o + b + s * i */
-		[0] [5] = 6, [5] [0] = 6,
-		/* [1] [5] = 6, [5] [1] = 6, */
+		[2] [3] = 5, [3] [2] = 5, /* 5: o + s * i */
+		[0] [2] = 6, [2] [0] = 6, /* 6: o + b */
+		[2] [4] = 7, [4] [2] = 7, /* 7: o + b + s * i */
+		[0] [5] = 7, [5] [0] = 7,
+		[6] [3] = 7, [3] [6] = 7,
+
 	};
 	int a, a1, a2, n1, n2, t1, t2;
 	Ins *i;
@@ -792,7 +794,8 @@ amatch(Addr *a, Ref r, ANum *ai, Fn *fn, int top)
 		break;
 	case 2: /* constants */
 	case 5: /* o + s * i */
-	case 6: /* o + b + s * i */
+	case 6: /* o + b */
+	case 7: /* o + b + s * i */
 		amatch(a, ar, ai, fn, 0);
 		amatch(a, al, ai, fn, 0);
 		break;