└[~/Develop/GO/Gnet-Scanner]> go version
go version go1.22.2 linux/amd64
Showing top 10 nodes out of 33
flat flat% sum% cum cum%
69.51MB 43.29% 43.29% 131.07MB 81.63% net/http.(*Transport).getConn
60.56MB 37.72% 81.00% 61.06MB 38.03% net/http.(*Transport).queueForIdleConn
7.50MB 4.67% 85.68% 7.50MB 4.67% net.(*Resolver).internetAddrList.func1
7.50MB 4.67% 90.35% 143.07MB 89.10% main.scan
6MB 3.74% 94.08% 7MB 4.36% net.(*sysDialer).dialSingle
4MB 2.49% 96.57% 4MB 2.49% net.JoinHostPort
2MB 1.25% 97.82% 2MB 1.25% net.IPv4
0.50MB 0.31% 98.13% 17MB 10.59% net/http.(*Transport).dialConn
0 0% 98.13% 143.07MB 89.10% main.scanChunk
0 0% 98.13% 16.50MB 10.28% net.(*Dialer).DialContext
. . 1100: // Register to receive next connection that becomes idle.
. . 1101: if t.idleConnWait == nil {
. . 1102: t.idleConnWait = make(map[connectMethodKey]wantConnQueue)
. . 1103: }
. . 1104: q := t.idleConnWait[w.key]
. . 1105: q.cleanFront()
. 6MB 1106: q.pushBack(w)
380.89MB 380.89MB 1107: t.idleConnWait[w.key] = q
. . 1108: return false
. . 1109:}
. . 1110:
. . 1111:// removeIdleConn marks pconn as dead.
. . 1112:func (t *Transport) removeIdleConn(pconn *persistConn) bool {
tr := &http.Transport{
MaxIdleConns: 10,
IdleConnTimeout: 30 * time.Second,
DisableCompression: true,
}