diff options
author | Ian Lance Taylor <ian@gcc.gnu.org> | 2019-02-15 01:57:51 +0000 |
---|---|---|
committer | Ian Lance Taylor <ian@gcc.gnu.org> | 2019-02-15 01:57:51 +0000 |
commit | 8a9f2a6bbd6bdf164ca987edac34ac72447881a5 (patch) | |
tree | 0722c462bd08d8478a0d1861b10b9f966193505e /libgo/runtime/stack.c | |
parent | c8530c410972f09b88bb143e5e5a4910bd72b2ee (diff) | |
download | gcc-8a9f2a6bbd6bdf164ca987edac34ac72447881a5.zip gcc-8a9f2a6bbd6bdf164ca987edac34ac72447881a5.tar.gz gcc-8a9f2a6bbd6bdf164ca987edac34ac72447881a5.tar.bz2 |
compiler, runtime: harmonize types referenced by both C and Go
Compiling with LTO revealed a number of cases in the runtime and
standard library where C and Go disagreed about the type of an object or
function (or where Go and code generated by the compiler disagreed). In
all cases the underlying representation was the same (e.g., uintptr vs.
void*), so this wasn't causing actual problems, but it did result in a
number of annoying warnings when compiling with LTO.
Reviewed-on: https://go-review.googlesource.com/c/160700
From-SVN: r268923
Diffstat (limited to 'libgo/runtime/stack.c')
-rw-r--r-- | libgo/runtime/stack.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libgo/runtime/stack.c b/libgo/runtime/stack.c index 2d5d1e0..be5e523 100644 --- a/libgo/runtime/stack.c +++ b/libgo/runtime/stack.c @@ -20,7 +20,7 @@ extern void * __splitstack_find_context (void *context[10], size_t *, void **, // tail call to doscanstack1. #pragma GCC optimize ("-fno-optimize-sibling-calls") -extern void scanstackblock(void *addr, uintptr size, void *gcw) +extern void scanstackblock(uintptr addr, uintptr size, void *gcw) __asm__("runtime.scanstackblock"); static bool doscanstack1(G*, void*) @@ -84,11 +84,11 @@ static bool doscanstack1(G *gp, void *gcw) { } } if(sp != nil) { - scanstackblock(sp, (uintptr)(spsize), gcw); + scanstackblock((uintptr)(sp), (uintptr)(spsize), gcw); while((sp = __splitstack_find(next_segment, next_sp, &spsize, &next_segment, &next_sp, &initial_sp)) != nil) - scanstackblock(sp, (uintptr)(spsize), gcw); + scanstackblock((uintptr)(sp), (uintptr)(spsize), gcw); } #else byte* bottom; |