1/* 2 * Copyright (C) 2018 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17syntax = "proto2"; 18option optimize_for = LITE_RUNTIME; 19 20package perfetto.protos; 21 22// When editing entries here remember also to update "sys_stats_counters.h" with 23// the corresponding string definitions for the actual /proc files parser. 24 25// Counter definitions for Linux's /proc/meminfo. 26enum MeminfoCounters { 27 MEMINFO_UNSPECIFIED = 0; 28 MEMINFO_MEM_TOTAL = 1; 29 MEMINFO_MEM_FREE = 2; 30 MEMINFO_MEM_AVAILABLE = 3; 31 MEMINFO_BUFFERS = 4; 32 MEMINFO_CACHED = 5; 33 MEMINFO_SWAP_CACHED = 6; 34 MEMINFO_ACTIVE = 7; 35 MEMINFO_INACTIVE = 8; 36 MEMINFO_ACTIVE_ANON = 9; 37 MEMINFO_INACTIVE_ANON = 10; 38 MEMINFO_ACTIVE_FILE = 11; 39 MEMINFO_INACTIVE_FILE = 12; 40 MEMINFO_UNEVICTABLE = 13; 41 MEMINFO_MLOCKED = 14; 42 MEMINFO_SWAP_TOTAL = 15; 43 MEMINFO_SWAP_FREE = 16; 44 MEMINFO_DIRTY = 17; 45 MEMINFO_WRITEBACK = 18; 46 MEMINFO_ANON_PAGES = 19; 47 MEMINFO_MAPPED = 20; 48 MEMINFO_SHMEM = 21; 49 MEMINFO_SLAB = 22; 50 MEMINFO_SLAB_RECLAIMABLE = 23; 51 MEMINFO_SLAB_UNRECLAIMABLE = 24; 52 MEMINFO_KERNEL_STACK = 25; 53 MEMINFO_PAGE_TABLES = 26; 54 MEMINFO_COMMIT_LIMIT = 27; 55 MEMINFO_COMMITED_AS = 28; 56 MEMINFO_VMALLOC_TOTAL = 29; 57 MEMINFO_VMALLOC_USED = 30; 58 MEMINFO_VMALLOC_CHUNK = 31; 59 MEMINFO_CMA_TOTAL = 32; 60 MEMINFO_CMA_FREE = 33; 61} 62 63// Counter definitions for Linux's /proc/vmstat. 64enum VmstatCounters { 65 VMSTAT_UNSPECIFIED = 0; 66 VMSTAT_NR_FREE_PAGES = 1; 67 VMSTAT_NR_ALLOC_BATCH = 2; 68 VMSTAT_NR_INACTIVE_ANON = 3; 69 VMSTAT_NR_ACTIVE_ANON = 4; 70 VMSTAT_NR_INACTIVE_FILE = 5; 71 VMSTAT_NR_ACTIVE_FILE = 6; 72 VMSTAT_NR_UNEVICTABLE = 7; 73 VMSTAT_NR_MLOCK = 8; 74 VMSTAT_NR_ANON_PAGES = 9; 75 VMSTAT_NR_MAPPED = 10; 76 VMSTAT_NR_FILE_PAGES = 11; 77 VMSTAT_NR_DIRTY = 12; 78 VMSTAT_NR_WRITEBACK = 13; 79 VMSTAT_NR_SLAB_RECLAIMABLE = 14; 80 VMSTAT_NR_SLAB_UNRECLAIMABLE = 15; 81 VMSTAT_NR_PAGE_TABLE_PAGES = 16; 82 VMSTAT_NR_KERNEL_STACK = 17; 83 VMSTAT_NR_OVERHEAD = 18; 84 VMSTAT_NR_UNSTABLE = 19; 85 VMSTAT_NR_BOUNCE = 20; 86 VMSTAT_NR_VMSCAN_WRITE = 21; 87 VMSTAT_NR_VMSCAN_IMMEDIATE_RECLAIM = 22; 88 VMSTAT_NR_WRITEBACK_TEMP = 23; 89 VMSTAT_NR_ISOLATED_ANON = 24; 90 VMSTAT_NR_ISOLATED_FILE = 25; 91 VMSTAT_NR_SHMEM = 26; 92 VMSTAT_NR_DIRTIED = 27; 93 VMSTAT_NR_WRITTEN = 28; 94 VMSTAT_NR_PAGES_SCANNED = 29; 95 VMSTAT_WORKINGSET_REFAULT = 30; 96 VMSTAT_WORKINGSET_ACTIVATE = 31; 97 VMSTAT_WORKINGSET_NODERECLAIM = 32; 98 VMSTAT_NR_ANON_TRANSPARENT_HUGEPAGES = 33; 99 VMSTAT_NR_FREE_CMA = 34; 100 VMSTAT_NR_SWAPCACHE = 35; 101 VMSTAT_NR_DIRTY_THRESHOLD = 36; 102 VMSTAT_NR_DIRTY_BACKGROUND_THRESHOLD = 37; 103 VMSTAT_PGPGIN = 38; 104 VMSTAT_PGPGOUT = 39; 105 VMSTAT_PGPGOUTCLEAN = 40; 106 VMSTAT_PSWPIN = 41; 107 VMSTAT_PSWPOUT = 42; 108 VMSTAT_PGALLOC_DMA = 43; 109 VMSTAT_PGALLOC_NORMAL = 44; 110 VMSTAT_PGALLOC_MOVABLE = 45; 111 VMSTAT_PGFREE = 46; 112 VMSTAT_PGACTIVATE = 47; 113 VMSTAT_PGDEACTIVATE = 48; 114 VMSTAT_PGFAULT = 49; 115 VMSTAT_PGMAJFAULT = 50; 116 VMSTAT_PGREFILL_DMA = 51; 117 VMSTAT_PGREFILL_NORMAL = 52; 118 VMSTAT_PGREFILL_MOVABLE = 53; 119 VMSTAT_PGSTEAL_KSWAPD_DMA = 54; 120 VMSTAT_PGSTEAL_KSWAPD_NORMAL = 55; 121 VMSTAT_PGSTEAL_KSWAPD_MOVABLE = 56; 122 VMSTAT_PGSTEAL_DIRECT_DMA = 57; 123 VMSTAT_PGSTEAL_DIRECT_NORMAL = 58; 124 VMSTAT_PGSTEAL_DIRECT_MOVABLE = 59; 125 VMSTAT_PGSCAN_KSWAPD_DMA = 60; 126 VMSTAT_PGSCAN_KSWAPD_NORMAL = 61; 127 VMSTAT_PGSCAN_KSWAPD_MOVABLE = 62; 128 VMSTAT_PGSCAN_DIRECT_DMA = 63; 129 VMSTAT_PGSCAN_DIRECT_NORMAL = 64; 130 VMSTAT_PGSCAN_DIRECT_MOVABLE = 65; 131 VMSTAT_PGSCAN_DIRECT_THROTTLE = 66; 132 VMSTAT_PGINODESTEAL = 67; 133 VMSTAT_SLABS_SCANNED = 68; 134 VMSTAT_KSWAPD_INODESTEAL = 69; 135 VMSTAT_KSWAPD_LOW_WMARK_HIT_QUICKLY = 70; 136 VMSTAT_KSWAPD_HIGH_WMARK_HIT_QUICKLY = 71; 137 VMSTAT_PAGEOUTRUN = 72; 138 VMSTAT_ALLOCSTALL = 73; 139 VMSTAT_PGROTATED = 74; 140 VMSTAT_DROP_PAGECACHE = 75; 141 VMSTAT_DROP_SLAB = 76; 142 VMSTAT_PGMIGRATE_SUCCESS = 77; 143 VMSTAT_PGMIGRATE_FAIL = 78; 144 VMSTAT_COMPACT_MIGRATE_SCANNED = 79; 145 VMSTAT_COMPACT_FREE_SCANNED = 80; 146 VMSTAT_COMPACT_ISOLATED = 81; 147 VMSTAT_COMPACT_STALL = 82; 148 VMSTAT_COMPACT_FAIL = 83; 149 VMSTAT_COMPACT_SUCCESS = 84; 150 VMSTAT_COMPACT_DAEMON_WAKE = 85; 151 VMSTAT_UNEVICTABLE_PGS_CULLED = 86; 152 VMSTAT_UNEVICTABLE_PGS_SCANNED = 87; 153 VMSTAT_UNEVICTABLE_PGS_RESCUED = 88; 154 VMSTAT_UNEVICTABLE_PGS_MLOCKED = 89; 155 VMSTAT_UNEVICTABLE_PGS_MUNLOCKED = 90; 156 VMSTAT_UNEVICTABLE_PGS_CLEARED = 91; 157 VMSTAT_UNEVICTABLE_PGS_STRANDED = 92; 158}