aboutsummaryrefslogtreecommitdiff
path: root/src/net/http/internal/httpsfv/httpsfv.go
diff options
context:
space:
mode:
authorShulhan <m.shulhan@gmail.com>2024-01-25 04:23:24 +0700
committerShulhan <m.shulhan@gmail.com>2026-02-03 18:04:30 +0700
commitc1b21b3cccfeed8f8f6762410479ac03864cd30c (patch)
treee2ed26daecc27b67e68ea3119454f88b9ad85eba /src/net/http/internal/httpsfv/httpsfv.go
parentc9f30d6b1840f109b2009fbf3081a97659e0927c (diff)
downloadgo-c1b21b3cccfeed8f8f6762410479ac03864cd30c.tar.xz
encoding/json: realign struct encodeState, structFields, and field
This reduce the struct encodeState size from 56 to 16 bytes (-42), struct structFields size from 40 to 24 bytes (-16), and struct field size from 136 to 128 bytes (-8). Benchmark memory profiling before and after, File: json.test Type: alloc_space Time: Jan 25, 2024 at 4:51am (WIB) Showing nodes accounting for -4.01GB, 4.66% of 85.95GB total Dropped 64 nodes (cum <= 0.43GB) flat flat% sum% cum cum% -4.25GB 4.94% 4.94% -4.01GB 4.67% encoding/json.Marshal 0.19GB 0.22% 4.73% 0.24GB 0.28% encoding/json.mapEncoder.encode 0.05GB 0.057% 4.67% 0.05GB 0.057% reflect.copyVal 0.04GB 0.049% 4.62% 0.04GB 0.049% bytes.growSlice -0.04GB 0.045% 4.66% -0.04GB 0.045% encoding/json.RawMessage.MarshalJSON 0 0% 4.66% 0.04GB 0.046% bytes.(*Buffer).WriteString 0 0% 4.66% 0.04GB 0.049% bytes.(*Buffer).grow 0 0% 4.66% -0.04GB 0.045% encoding/json.(*Encoder).Encode 0 0% 4.66% 0.20GB 0.23% encoding/json.(*encodeState).marshal 0 0% 4.66% 0.20GB 0.23% encoding/json.(*encodeState).reflectValue
Diffstat (limited to 'src/net/http/internal/httpsfv/httpsfv.go')
0 files changed, 0 insertions, 0 deletions