Re: [go-nuts] Why default stack size is 1gb?

2017-07-26 Thread T L


On Wednesday, July 26, 2017 at 10:37:44 AM UTC-4, Jan Mercl wrote:
>
> On Wed, Jul 26, 2017 at 4:26 PM T L  
> wrote:
>
> > BTW, I think we do need a GrowCurrentStackTo API, to avoid predicted 
> several stack copies in stack growing.
>
> The specification does not requires Go implementations to have any stack 
> at all.
>

we can just add it in the debug package, just like 
runtime/debug.SetMaxStack.
 

>
> -- 
>
> -j
>

-- 
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.


Re: [go-nuts] Why default stack size is 1gb?

2017-07-26 Thread Jan Mercl
On Wed, Jul 26, 2017 at 4:26 PM T L  wrote:

> BTW, I think we do need a GrowCurrentStackTo API, to avoid predicted
several stack copies in stack growing.

The specification does not requires Go implementations to have any stack at
all.

-- 

-j

-- 
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.


Re: [go-nuts] Why default stack size is 1gb?

2017-07-26 Thread T L
BTW, I think we do need a GrowCurrentStackTo API, to avoid predicted 
several stack copies in stack growing.

On Monday, July 24, 2017 at 9:51:22 PM UTC-4, taozle wrote:
>
> my mistake, i mean the *max* stack size is 1gb which i saw it here 
> , not the default 
> stack size. Sorry for confusing
>
> On Tue, Jul 25, 2017 at 7:33 AM Florin Pățan  > wrote:
>
>> Iirc the default stack size is 2 or 4 kb not 1 gb. Where did you found 
>> the reference?
>>
>> --
>> 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...@googlegroups.com .
>> For more options, visit https://groups.google.com/d/optout.
>>
>

-- 
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.


Re: [go-nuts] Why default stack size is 1gb?

2017-07-24 Thread 张李阳
my mistake, i mean the *max* stack size is 1gb which i saw it here
, not the default stack
size. Sorry for confusing

On Tue, Jul 25, 2017 at 7:33 AM Florin Pățan  wrote:

> Iirc the default stack size is 2 or 4 kb not 1 gb. Where did you found the
> reference?
>
> --
> 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.
>

-- 
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.


[go-nuts] Why default stack size is 1gb?

2017-07-24 Thread Florin Pățan
Iirc the default stack size is 2 or 4 kb not 1 gb. Where did you found the 
reference? 

-- 
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.


Re: [go-nuts] Why default stack size is 1gb?

2017-07-24 Thread Jan Mercl
On Mon, Jul 24, 2017 at 5:32 PM taozle  wrote:

> I found that the default stack size for 64-bit is 1gb, but i can't see
any reason for such a large stack, can anyone help me find out the purpose
for this?

Where did you find that info? AFAICT it's not true. Thread stack size is
probably same or similar to the default C stack size on each platform and
goroutine stack defaults to few kB only.

-- 

-j

-- 
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.


[go-nuts] Why default stack size is 1gb?

2017-07-24 Thread taozle
I found that the default stack size for 64-bit is 1gb, but i can't see any 
reason for such a large stack, can anyone help me find out the purpose for 
this?

-- 
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.