[Bug 199169] [patch] zone "UMA Zones" has bigger size than need
bugzilla-noreply at freebsd.org
bugzilla-noreply at freebsd.org
Mon Apr 6 03:35:08 UTC 2015
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=199169
--- Comment #2 from luke.tw at gmail.com ---
hi, Dmitry,
Thanks for your feedback.
That's right, but there is already one uma_cache in the struct uma_zone.
Let me do an experiment on sleepq_zone.
I have 4-core cpu and the mp_maxid is 3.
(kgdb) p mp_maxid
$1 = 3
The size of all per-cpu cache in sleepq_zone is 640 bytes.
(kgdb) p sleepq_zone
$2 = 0xfffff80002bb8000
(kgdb) p sleepq_zone->uz_cpu
$3 = 0xfffff80002bb8200
(kgdb) p masterzone_z->uz_size - (0xfffff80002bb8200 - 0xfffff80002bb8000)
$4 = 640
So, there are total 5 elements in the uz_cpu array
(kgdb) p 640 / sizeof(struct uma_cache)
$5 = 5
Only the first 4 elements are used.
(kgdb) p sleepq_zone->uz_cpu[0]
$6 = {uc_freebucket = 0x0, uc_allocbucket = 0xfffff80002bb1c00, uc_allocs = 73,
uc_frees = 0}
(kgdb) p sleepq_zone->uz_cpu[1]
$7 = {uc_freebucket = 0x0, uc_allocbucket = 0xfffff8000516a800, uc_allocs = 18,
uc_frees = 0}
(kgdb) p sleepq_zone->uz_cpu[2]
$8 = {uc_freebucket = 0x0, uc_allocbucket = 0xfffff80004747c00, uc_allocs = 18,
uc_frees = 0}
(kgdb) p sleepq_zone->uz_cpu[3]
$9 = {uc_freebucket = 0x0, uc_allocbucket = 0xfffff800047a1c00, uc_allocs = 36,
uc_frees = 0}
(kgdb) p sleepq_zone->uz_cpu[4]
$10 = {uc_freebucket = 0x0, uc_allocbucket = 0x0, uc_allocs = 0, uc_frees = 0}
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the freebsd-bugs
mailing list