On Fri, Nov 17, 2017 at 3:31 AM, Conrado PLG <conrado...@gmail.com> wrote:
>
> I'm working on a software for a 32-bit PowerPC processor. Since there is no
> Go support for it, I'm using gccgo. However, I've noticed that it's not
> possible to use a large number of goroutines since each one takes around 2
> MB of memory. From what I understand, this is the stack space reserved for
> each goroutine, and it's large because gccgo does not support split stack
> for non-x86 processors.
>
> My questions are:
>
> - Is there a way to reduce the stack usage of goroutines (even if it
> requires recompiling gccgo)?

Edit StackMin (for the non-split-stack case) in libgo/runtime/proc.c
and rebuild libgo.

Note that GCC does support split stacks for 64-bit PPC.  I don't know
how difficult it would be to add support for 32-bit PPC.


> - How difficult would it be to port Go to 32-bit PowerPC (Linux)? Could
> someone give a high-level overview of what would need to be changed (or is
> there an overview somewhere)?

It probably wouldn't be too hard for someone familiar with PPC32 and
PPC64 as used on GNU/Linux.  Basically look for every file in the Go
distribution with "ppc64" in the name, and plan to write a plan "ppc"
version.

Ian

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to