Re: [go-nuts] what`s the intention of "heapGoal" around GC cycle

2018-11-05 Thread liuding234
Wow~ let me check the code about "gc_trigger". Thanks a lot 在 2018年11月6日星期二 UTC+8上午11:50:19,Ian Lance Taylor写道: > > On Mon, Nov 5, 2018 at 6:47 PM, > > wrote: > > But why "intended to occur" is greater than live heap(heap_live)? > > If the heap goal were the size of the live heap, then it woul

Re: [go-nuts] what`s the intention of "heapGoal" around GC cycle

2018-11-05 Thread liuding234
But why "intended to occur" is greater than live heap(heap_live)? 在 2018年11月6日星期二 UTC+8上午4:00:24,Ian Lance Taylor写道: > > On Mon, Nov 5, 2018 at 8:46 AM, > > wrote: > > > > I saw a variable "heapGoal" in gctrace printer. > > > > Why heapGoal is greater than heap_live? > > heapGoal is the si

[go-nuts] what`s the intention of "heapGoal" around GC cycle

2018-11-05 Thread liuding234
I saw a variable "heapGoal" in gctrace printer. Why heapGoal is greater than heap_live? -- 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...@

Re: [go-nuts] *netFD.Close() will block in some case?

2017-02-09 Thread liuding234
Bug if i set write deadline, that means i hold two timers. it`s stranged 在 2017年2月9日星期四 UTC+8下午5:52:32,Jakob Borg写道: > > Yeah, for Close() on TLS connections you want to set a write deadline > before calling Close(). > > //jb > > > On 9 Feb 2017, at 10:28, liudi...@gmail.com wrote: > > > > O

[go-nuts] Re: *netFD.Close() will block in some case?

2017-02-09 Thread liuding234
OH sorry. it seems has some wrong in my demo code. it should import "crypto/tls". So Close() is in crypto/tls/conn.go. And i found it blocked in "c.handshakeMutex.Lock()". I suspect that someone goroutine blocked in "c.sendAlert(alertCloseNotify)", case it`s an network IO, and i didn`t setDeadL

[go-nuts] *netFD.Close() will block in some case?

2017-02-08 Thread liuding234
go version: 1.7.4 OS: debian code like: https://play.golang.org/p/DMIrSr2PLg this project just like IM, there are both goroutine for each client connection, one to Read, another to Write. recently i found conn.Close() (line 9) occasional block while high concurrency, then there are a large of