• KOSAKI Motohiro's avatar
    vmscan: implement swap token trace · 83cd81a3
    KOSAKI Motohiro authored
    This is useful for observing swap token activity.
    
    example output:
    
                 zsh-1845  [000]   598.962716: update_swap_token_priority:
    mm=ffff88015eaf7700 old_prio=1 new_prio=0
              memtoy-1830  [001]   602.033900: update_swap_token_priority:
    mm=ffff880037a45880 old_prio=947 new_prio=949
              memtoy-1830  [000]   602.041509: update_swap_token_priority:
    mm=ffff880037a45880 old_prio=949 new_prio=951
              memtoy-1830  [000]   602.051959: update_swap_token_priority:
    mm=ffff880037a45880 old_prio=951 new_prio=953
              memtoy-1830  [000]   602.052188: update_swap_token_priority:
    mm=ffff880037a45880 old_prio=953 new_prio=955
              memtoy-1830  [001]   602.427184: put_swap_token:
    token_mm=ffff880037a45880
                 zsh-1789  [000]   602.427281: replace_swap_token:
    old_token_mm=          (null) old_prio=0 new_token_mm=ffff88015eaf7018
    new_prio=2
                 zsh-1789  [001]   602.433456: update_swap_token_priority:
    mm=ffff88015eaf7018 old_prio=2 new_prio=4
                 zsh-1789  [000]   602.437613: update_swap_token_priority:
    mm=ffff88015eaf7018 old_prio=4 new_prio=6
                 zsh-1789  [000]   602.443924: update_swap_token_priority:
    mm=ffff88015eaf7018 old_prio=6 new_prio=8
                 zsh-1789  [000]   602.451873: update_swap_token_priority:
    mm=ffff88015eaf7018 old_prio=8 new_prio=10
                 zsh-1789  [001]   602.462639: update_swap_token_priority:
    mm=ffff88015eaf7018 old_prio=10 new_prio=12
    Signed-off-by: default avatarKOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
    Acked-by: Rik van Riel<riel@redhat.com>
    Reviewed-by: default avatarKAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
    Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
    Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
    83cd81a3
thrash.c 3.1 KB