Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in
  • L linux-rm
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
    • Requirements
  • Merge requests 0
    • Merge requests 0
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Metrics
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • linux-arm
  • linux-rm
  • Repository
Switch branch/tag
  • linux-rm
  • tools
  • testing
  • selftests
  • vm
  • ksm_tests.c
Find file BlameHistoryPermalink
  • Zhansaya Bagdauletkyzy's avatar
    selftests: vm: add KSM merging time test · 9e7cb94c
    Zhansaya Bagdauletkyzy authored Sep 02, 2021
    Patch series "add KSM performance tests", v3.
    
    Extend KSM self tests with a performance benchmark.  These tests are not
    part of regular regression testing, as they are mainly intended to be used
    by developers making changes to the memory management subsystem.
    
    This patch (of 2):
    
    Add ksm_merge_time() function to determine speed and time needed for
    merging.  The total spent time is shown in seconds while speed is in
    MiB/s.  User must specify the size of duplicated memory area (in MiB)
    before running the test.
    
    The test is run as follows: ./ksm_tests -P -s 100
    The output:
    	Total size:    100 MiB
    	Total time:    0.201106786 s
    	Average speed:  497.248 MiB/s
    
    Link: https://lkml.kernel.org/r/cover.1629386192.git.zhansayabagdaulet@gmail.com
    Link: https://lkml.kernel.org/r/318b946ac80cc9205c89d0962048378f7ce0705b.1629386192.git.zhansayabagdaulet@gmail.com
    
    
    Signed-off-by: default avatarZhansaya Bagdauletkyzy <zhansayabagdaulet@gmail.com>
    Reviewed-by: default avatarTyler Hicks <tyhicks@linux.microsoft.com>
    Reviewed-by: default avatarPavel Tatashin <pasha.tatashin@soleen.com>
    Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
    Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
    9e7cb94c