• Z
    KVM: arm64: Support the vCPU preemption check · ad26870d
    Zengruan Ye 提交于
    euleros inclusion
    category: feature
    bugzilla: https://bugzilla.openeuler.org/show_bug.cgi?id=35
    CVE: NA
    
    --------------------------------
    
    Support the vcpu_is_preempted() functionality under KVM/arm64. This will
    enhance lock performance on overcommitted hosts (more runnable vCPUs
    than physical CPUs in the system) as doing busy waits for preempted
    vCPUs will hurt system performance far worse than early yielding.
    
    unix benchmark result:
      host:  kernel 4.19.87, HiSilicon Kunpeng920, 8 CPUs
      guest: kernel 4.19.87, 16 vCPUs
    
                   test-case                |    after-patch    |   before-patch
    ----------------------------------------+-------------------+------------------
     Dhrystone 2 using register variables   | 338955728.5 lps   | 339266319.5 lps
     Double-Precision Whetstone             |     30634.9 MWIPS |     30884.4 MWIPS
     Execl Throughput                       |      6753.2 lps   |      3580.1 lps
     File Copy 1024 bufsize 2000 maxblocks  |    490048.0 KBps  |    313282.3 KBps
     File Copy 256 bufsize 500 maxblocks    |    129662.5 KBps  |     83550.7 KBps
     File Copy 4096 bufsize 8000 maxblocks  |   1552551.5 KBps  |    814327.0 KBps
     Pipe Throughput                        |   8976422.5 lps   |   9048628.4 lps
     Pipe-based Context Switching           |    258641.7 lps   |    252925.9 lps
     Process Creation                       |      5312.2 lps   |      4507.9 lps
     Shell Scripts (1 concurrent)           |      8704.2 lpm   |      6720.9 lpm
     Shell Scripts (8 concurrent)           |      1708.8 lpm   |       607.2 lpm
     System Call Overhead                   |   3714444.7 lps   |   3746386.8 lps
    ----------------------------------------+-------------------+------------------
     System Benchmarks Index Score          |      2270.6       |      1679.2
    Signed-off-by: NZengruan Ye <yezengruan@huawei.com>
    Reviewed-by: Nzhanghailiang <zhang.zhanghailiang@huawei.com>
    Signed-off-by: NYang Yingliang <yangyingliang@huawei.com>
    Signed-off-by: NChaochao Xing <xingchaochao@huawei.com>
    Reviewed-by: NZengruan Ye <yezengruan@huawei.com>
    Reviewed-by: NXiangyou Xie <xiexiangyou@huawei.com>
    Signed-off-by: NCheng Jian <cj.chengjian@huawei.com>
    ad26870d
paravirt.h 888 字节