Opened 7 years ago
Closed 7 years ago
#1658 closed enhancement (duplicate)
Optimize memory usage in ngx_reset_pool
| Reported by: | Owned by: | ||
|---|---|---|---|
| Priority: | minor | Milestone: | |
| Component: | nginx-core | Version: | 1.15.x |
| Keywords: | Cc: | ||
| uname -a: | |||
| nginx -V: | nginx version: nginx/1.15.3 | ||
Description
In ngx_pool_t, the overhead of first block is sizeof(ngx_pool_t), the overhead of other blocks is sizeof(ngx_pool_data_t). But in function ngx_reset_pool, the last pointer always move to 'p + sizeof(ngx_pool_t)', and wastes some(small) memory.
I think we can optimize it, please see the patch, thanks.
Attachments (1)
Change History (2)
by , 7 years ago
| Attachment: | ngx_palloc.c.patch added |
|---|
comment:1 by , 7 years ago
| Resolution: | → duplicate |
|---|---|
| Status: | new → closed |
Note:
See TracTickets
for help on using tickets.

Duplicate of #1594.