diff options
Diffstat (limited to 'vm')
-rw-r--r-- | vm/vm_fault.c | 7 | ||||
-rw-r--r-- | vm/vm_pageout.c | 1 |
2 files changed, 8 insertions, 0 deletions
diff --git a/vm/vm_fault.c b/vm/vm_fault.c index 178f307..7e84961 100644 --- a/vm/vm_fault.c +++ b/vm/vm_fault.c @@ -254,6 +254,7 @@ vm_fault_return_t vm_fault_page(first_object, first_offset, vm_stat_sample(SAMPLED_PC_VM_FAULTS_ANY); vm_stat.faults++; /* needs lock XXX */ + current_task()->faults++; /* * Recovery actions @@ -471,6 +472,7 @@ vm_fault_return_t vm_fault_page(first_object, first_offset, vm_stat_sample(SAMPLED_PC_VM_ZFILL_FAULTS); vm_stat.zero_fill_count++; + current_task()->zero_fills++; vm_object_lock(object); pmap_clear_modify(m->phys_addr); break; @@ -552,6 +554,7 @@ vm_fault_return_t vm_fault_page(first_object, first_offset, if (m->inactive) { vm_stat_sample(SAMPLED_PC_VM_REACTIVATION_FAULTS); vm_stat.reactivations++; + current_task()->reactivations++; } VM_PAGE_QUEUES_REMOVE(m); @@ -651,6 +654,7 @@ vm_fault_return_t vm_fault_page(first_object, first_offset, vm_stat.pageins++; vm_stat_sample(SAMPLED_PC_VM_PAGEIN_FAULTS); + current_task()->pageins++; if ((rc = memory_object_data_request(object->pager, object->pager_request, @@ -740,6 +744,7 @@ vm_fault_return_t vm_fault_page(first_object, first_offset, vm_page_zero_fill(m); vm_stat_sample(SAMPLED_PC_VM_ZFILL_FAULTS); vm_stat.zero_fill_count++; + current_task()->zero_fills++; vm_object_lock(object); pmap_clear_modify(m->phys_addr); break; @@ -855,6 +860,7 @@ vm_fault_return_t vm_fault_page(first_object, first_offset, vm_stat.cow_faults++; vm_stat_sample(SAMPLED_PC_VM_COW_FAULTS); + current_task()->cow_faults++; object = first_object; offset = first_offset; @@ -1638,6 +1644,7 @@ kern_return_t vm_fault_wire_fast(map, va, entry) vm_prot_t prot; vm_stat.faults++; /* needs lock XXX */ + current_task()->faults++; /* * Recovery actions */ diff --git a/vm/vm_pageout.c b/vm/vm_pageout.c index 77c1cfe..661675f 100644 --- a/vm/vm_pageout.c +++ b/vm/vm_pageout.c @@ -764,6 +764,7 @@ void vm_pageout_scan() vm_object_unlock(object); vm_page_activate(m); vm_stat.reactivations++; + current_task()->reactivations++; vm_page_unlock_queues(); vm_pageout_inactive_used++; continue; |