On Fri, Feb 15, 2019 at 12:15 AM Andreas Schwab <sch...@linux-m68k.org> wrote:
>
> This breaks non-split-stack builds.
>
> ../../../libgo/runtime/stack.c: In function 'doscanstack1':
> ../../../libgo/runtime/stack.c:113:18: error: passing argument 1 of 
> 'scanstackblock' makes integer from pointer without a cast 
> [-Werror=int-conversion]
>   113 |   scanstackblock(bottom, (uintptr)(top - bottom), gcw);
>       |                  ^~~~~~
>       |                  |
>       |                  byte * {aka unsigned char *}

Thanks, and sorry.  Fixed like so.  Committed to mainline.

Ian
Index: gcc/go/gofrontend/MERGE
===================================================================
--- gcc/go/gofrontend/MERGE     (revision 268923)
+++ gcc/go/gofrontend/MERGE     (working copy)
@@ -1,4 +1,4 @@
-03e28273a4fcb114f5204d52ed107591404002f4
+a9c1a76e14b66a356d3c3dfb50f1e6138e97733c
 
 The first line of this file holds the git revision number of the last
 merge done from the gofrontend repository.
Index: libgo/runtime/stack.c
===================================================================
--- libgo/runtime/stack.c       (revision 268923)
+++ libgo/runtime/stack.c       (working copy)
@@ -110,15 +110,15 @@ static bool doscanstack1(G *gp, void *gc
        }
        top = (byte*)(void*)(gp->gcinitialsp) + gp->gcstacksize;
        if(top > bottom)
-               scanstackblock(bottom, (uintptr)(top - bottom), gcw);
+               scanstackblock((uintptr)(bottom), (uintptr)(top - bottom), gcw);
        else
-               scanstackblock(top, (uintptr)(bottom - top), gcw);
+               scanstackblock((uintptr)(top), (uintptr)(bottom - top), gcw);
        if (nextsp2 != nil) {
                initialsp2 = (byte*)(void*)(gp->gcinitialsp2);
                if(initialsp2 > nextsp2)
-                       scanstackblock(nextsp2, (uintptr)(initialsp2 - 
nextsp2), gcw);
+                       scanstackblock((uintptr)(nextsp2), (uintptr)(initialsp2 
- nextsp2), gcw);
                else
-                       scanstackblock(initialsp2, (uintptr)(nextsp2 - 
initialsp2), gcw);
+                       scanstackblock((uintptr)(initialsp2), (uintptr)(nextsp2 
- initialsp2), gcw);
        }
 #endif
        return true;

Reply via email to