]> Cypherpunks repositories - gostls13.git/commitdiff
[release-branch.r57] 6g, 8g: fix goto fix
authorRuss Cox <rsc@golang.org>
Thu, 16 Jun 2011 05:35:30 +0000 (01:35 -0400)
committerRuss Cox <rsc@golang.org>
Thu, 16 Jun 2011 05:35:30 +0000 (01:35 -0400)
««« CL 4632041 / cbc2b570b2ca
6g, 8g: fix goto fix

R=ken2
CC=golang-dev
https://golang.org/cl/4632041
»»»

R=adg
CC=golang-dev
https://golang.org/cl/4631042

src/cmd/6g/gsubr.c
src/cmd/8g/gsubr.c

index f224dfd9f21cfab579134305eb51fe40bd251ed4..78b8c4351ca2902ae2ada1cd6c25c70c11c25e7e 100644 (file)
@@ -125,7 +125,7 @@ clearstk(void)
 {
        Plist *pl;
        Prog *p1, *p2;
-       Node sp, di, cx, con;
+       Node sp, di, cx, con, ax;
 
        if((uint32)plast->firstpc->to.offset <= 0)
                return;
@@ -147,6 +147,9 @@ clearstk(void)
        gins(ACLD, N, N);
        gins(AMOVQ, &sp, &di);
        gins(AMOVQ, &con, &cx);
+       nodconst(&con, types[TUINT64], 0);
+       nodreg(&ax, types[TUINT64], D_AX);
+       gins(AMOVQ, &con, &ax);
        gins(AREP, N, N);
        gins(ASTOSQ, N, N);
 
index de1d323f83c8f0fd79af8cb799b51c378fa47a8a..ae9901eebafde37a38214fcea691d07c2f08e6d4 100644 (file)
@@ -127,7 +127,7 @@ clearstk(void)
 {
        Plist *pl;
        Prog *p1, *p2;
-       Node sp, di, cx, con;
+       Node sp, di, cx, con, ax;
 
        if(plast->firstpc->to.offset <= 0)
                return;
@@ -149,6 +149,9 @@ clearstk(void)
        gins(ACLD, N, N);
        gins(AMOVL, &sp, &di);
        gins(AMOVL, &con, &cx);
+       nodconst(&con, types[TUINT32], 0);
+       nodreg(&ax, types[TUINT32], D_AX);
+       gins(AMOVL, &con, &ax);
        gins(AREP, N, N);
        gins(ASTOSL, N, N);