Closed
【OLK-6.6】kernel support CCA hugepage #8502
yangxiangkaiAdd on  Feb 10Closed at  Mar 4
yangxiangkai
yangxiangkai
Feb 10 Create

特性描述

基于CCA机密虚机内存映射优化提升机密虚机运行性能:
1)CCA机密虚机stage2页表创建支持大页映射;
2)CCA机密虚机支持启动阶段提前创建stage2页表;
3)CCA机密虚机计算性能(speccpu/unixbench/lmbench)相比普通虚机平均劣化<5%,speccpu/lmbench最大性能劣化<10%,unixbench最大性能劣化<15%。

交付计划

版本分支 计划合入时间
OLK-6.6 2026/3/330

背景和需求分析

包括用户场景、价值评估
基于CCA架构提供高性能机密计算运行环境。

技术方案设计

架构设计、接口变更、性能影响等

测试计划和验收标准

realm机密虚机增加配置hisi-cca-enable='yes',启动realm机密虚机:
image.png
image.png
查看realm机密虚机占用大页情况:
image.png
销毁虚机:
image.png
查看系统大页占用情况:
image.png
在realm机密虚机中运行benchmark,查看相比普通虚机的性能损耗数据:
最新host内核测试 普通虚机基线 rust版本机密虚机(WFX使能+2M大页映射)libvirt
单线程 多线程 单线程 多线程 性能损耗
specpu 2017 SpecCPU int 6.15 22.5 6.11 22.2 -1.33%
500.perlbench_r 5.69 21.2 5.69 21 -0.94%
502.gcc_r 7.53 25.2 7.45 24.9 -1.19%
505.mcf_r 5.86 21.2 5.83 20.9 -1.42%
520.omnetpp_r 4 11.9 3.89 11.3 -5.04%
523.xalancbmk_r 6.16 23.1 5.98 22.9 -0.87%
525.x264_r 12.8 49.9 12.8 49.3 -1.20%
531.deepsjeng_r 5.23 20.4 5.22 20.3 -0.49%
541.leela_r 4.43 17.6 4.46 17.8 1.14%
548.exchange2_r 14.3 57.2 14.3 56.1 -1.92%
557.xz_r 2.96 10.3 2.95 10.2 -0.97%
unixbench Dhrystone 5814.6 23242.8 5629 22434.4 -3.48%
Whetstone 1299 5195.1 1296.3 5174 -0.41%
Execl Throughput 1368.8 4364.8 1373.9 4285 -1.83%
File Copy 1024 bufsize 2000 maxblocks 3006.4 5562 3108.6 5427.6 -2.42%
File Copy 256 bufsize 500 maxblocks 2064 3634.6 2152.2 3817.3 5.03%
File Copy 4096 bufsize 8000 maxblocks 5792.3 11689.4 5494.3 10491.6 -10.25%
Pipe Throughput 1305.7 5212.5 1392.9 5539.2 6.27%
Pipe-based Context Switching 302.1 3393.6 134.8 3358.5 -1.03%
Process Creation 883.3 2734.9 765.4 2531.1 -7.45%
Shell Scripts (1 concurrent) 2872.3 7263.9 3148.7 7881.3 8.50%
Shell Scripts (8 concurrent) 6457.2 7287.1 6965 7965.9 9.32%
System Call Overhead 659.2 2363.9 736.3 2574.2 8.90%
System Benchmarks Index Score 1847.7 5492.6 1755.3 5532.7 0.73%

兼容性影响评估

与CCA原生接口兼容

相关依赖和风险分析

该特性在用户态QEMU及libvirt提供相应的软件能力支持

likedislike
openeuler-ci-botopeneuler-ci-botCollaborators
Feb 10 Added label: sig/Kernel
openeuler-ci-bot
openeuler-ci-botCollaborators
Feb 10 Comments:
likedislike
hjx_gitffhjx_gitffCollaborators
Mar 3 Modify description of issue
hjx_gitffhjx_gitffCollaborators
Mar 3 Modify description of issue
openeuler-ci-botopeneuler-ci-botCollaborators
Mar 4 Close issue