Function report | 
Source Code:mm\slub.c | 
Create Date:2022-07-28 15:49:32 | 
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick | 
| home page | Tree | 
| Annotation kernel can get tool activity | Download SCCT | Chinese | 
Name:kmem_cache_shrink discards empty slabs and promotes the slabs filled* up most to the head of the partial lists. New allocations will then* fill those up and thus they can be removed from the partial lists.* The slabs with the least items are placed last
Proto:int __kmem_cache_shrink(struct kmem_cache *s)
Type:int
Parameter:
| Type | Parameter | Name | 
|---|---|---|
| struct kmem_cache * | s | 
| 3982 | ret = 0 | 
| 3987 | When i < SHRINK_PROMOTE_MAX cycle Initialization list head | 
| 3990 | spin_lock_irqsave( & list_lock, flags) | 
| 4009 | nr_partial-- | 
| 4010 | Else if free <= SHRINK_PROMOTE_MAX Then list_move - delete from one list and add as another's head*@list: the entry to move*@head: the head that will precede our entry | 
| 4018 | When i >= 0 cycle list_splice - join two lists, this is designed for stacks*@list: the new list to add.*@head: the place to add it in the first list. | 
| 4021 | spin_unlock_irqrestore( & list_lock, flags) | 
| 4025 | discard_slab(s, page) | 
| 4027 | If slabs_node(s, node) Then ret = 1 | 
| 4031 | Return ret | 
| Name | Describe | 
|---|---|
| kmem_cache_shrink_all | kmem_cache_shrink_all - shrink a cache and all memcg caches for root cache*@s: The cache pointer | 
| __kmemcg_cache_deactivate | |
| __kmem_cache_shutdown | |
| __kmemcg_cache_deactivate_after_rcu | |
| slab_mem_going_offline_callback | 
| Source code conversion tool public plug-in interface  | X | 
|---|---|
| Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion  |