| Function report | 
| Source Code: mm\oom_kill.c | Create Date:2022-07-28 14:06:39 | 
| Last Modify:2022-05-23 13:16:41 | Copyright©Brick | 
| home page | Tree | 
| Annotation kernel can get tool activity | Download SCCT | Chinese | 
Name:_of_memory - kill the "best" process when we run out of memory*@oc: pointer to struct oom_control* If we run out of memory, we have the choice between either* killing a random task (bad), letting the system crash (worse)
Proto:bool out_of_memory(struct oom_control *oc)
Type:bool
Parameter:
| Type | Parameter | Name | 
|---|---|---|
| struct oom_control * | oc | 
| 1045 | freed = 0 | 
| 1047 | If oom_killer_disabled Then Return false | 
| 1050 | If Not is_memcg_oom(oc) Then | 
| 1051 | blocking_notifier_call_chain( & oom_notify_list, 0, & freed) | 
| 1052 | If freed > 0 Then Return true | 
| 1065 | Return true | 
| 1075 | If Used to determine cpuset and node locality requirement && Not (Used to determine cpuset and node locality requirement & __GFP_FS) && Not is_memcg_oom(oc) Then Return true | 
| 1083 | If Used to print the constraint info. != CONSTRAINT_MEMORY_POLICY Then Used to determine mempolicy = NULL | 
| 1092 | chosen = current process | 
| 1093 | oom_kill_process(oc, "Out of memory (oom_kill_allocating_task)") | 
| 1094 | Return true | 
| 1099 | If Not chosen Then | 
| 1100 | dump_header(oc, NULL) | 
| 1101 | pr_warn("Out of memory and no killable processes...\n") | 
| 1110 | If (chosen && chosen != (void * ) - 1UL) Then oom_kill_process(oc, !is_memcg_oom(oc) ? "Out of memory" : "Memory cgroup out of memory") | 
| 1113 | Return Not Not chosen | 
| Name | Describe | 
|---|---|
| pagefault_out_of_memory | The pagefault handler calls here because it is out of memory, so kill a* memory-hogging task. If oom_lock is held by somebody else, a parallel oom* killing is already in progress so do nothing. | 
| __alloc_pages_may_oom | |
| mem_cgroup_out_of_memory | 
| 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 |