• Keith Randall's avatar
    runtime: increase number of stack orders to 4 · 5aae246f
    Keith Randall authored
    Cache 2KB, 4KB, 8KB, and 16KB stacks.  Larger stacks
    will be allocated directly.  There is no point in cacheing
    32KB+ stacks as we ask for and return 32KB at a time
    from the allocator.
    
    Note that the minimum stack is 8K on windows/64bit and 4K on
    windows/32bit and plan9.  For these os/arch combinations,
    the number of stack orders is less so that we have the same
    maximum cached size.
    
    Fixes #9045
    
    Change-Id: Ia4195dd1858fb79fc0e6a91ae29c374d28839e44
    Reviewed-on: https://go-review.googlesource.com/2098
    
    Reviewed-by: default avatarRuss Cox <rsc@golang.org>
    5aae246f
malloc2.go 19 KB