| 1 |
#! stap -p4 --compatible=2.9 |
| 2 |
|
| 3 |
probe begin { |
| 4 |
printf("%d\n", _stp_valid_task(0) + _MM_FILEPAGES() |
| 5 |
+ _MM_ANONPAGES() + _stp_get_mm_counter(0, 0) |
| 6 |
+ _stp_mem_txt_adjust(0, 0)) |
| 7 |
printf("%s\n", _stp_number_to_string_postfix(1, 0, "")) |
| 8 |
printf("%d\n", proc_mem_size()); |
| 9 |
printf("%d\n", proc_mem_rss()); |
| 10 |
printf("%d\n", proc_mem_shr()); |
| 11 |
printf("%d\n", proc_mem_txt()); |
| 12 |
printf("%d\n", proc_mem_data()); |
| 13 |
printf("%d\n", mem_page_size()) |
| 14 |
printf("%s\n", bytes_to_string(0)); |
| 15 |
printf("%s\n", pages_to_string(0)); |
| 16 |
printf("%s\n", proc_mem_string()); |
| 17 |
} |
| 18 |
|
| 19 |
probe end { |
| 20 |
printf("%d\n", proc_mem_size(0)); |
| 21 |
printf("%d\n", proc_mem_rss(0)); |
| 22 |
printf("%d\n", proc_mem_shr(0)); |
| 23 |
printf("%d\n", proc_mem_txt(0)); |
| 24 |
printf("%d\n", proc_mem_data(0)); |
| 25 |
printf("%s\n", proc_mem_string(0)); |
| 26 |
} |