dhrystone和coremark测试比较

关于dhrystone测试,请参考博客

Dhrystone DMIPS跑分原理以及CPU&NPU等效算力分析_papaofdoudou的博客-CSDN博客_dhrystone测试结果怎么看

比较

dhrystone和coremark测试比较_第1张图片

coremark环境搭建

caozilong@caozilong-Vostro-3268:~/Workspace/coremark$ git clone https://gitcode.net/mirrors/eembc/coremark.git 
正克隆到 'coremark'...
remote: Enumerating objects: 374, done.
remote: Counting objects: 100% (374/374), done.
remote: Compressing objects: 100% (190/190), done.
remote: Total 374 (delta 218), reused 295 (delta 175), pack-reused 0
接收对象中: 100% (374/374), 497.54 KiB | 517.00 KiB/s, 完成.
处理 delta 中: 100% (218/218), 完成.
caozilong@caozilong-Vostro-3268:~/Workspace/coremark$ cd coremark/
caozilong@caozilong-Vostro-3268:~/Workspace/coremark/coremark$ make
make XCFLAGS=" -DPERFORMANCE_RUN=1" load run1.log
make[1]: 进入目录“/home/caozilong/Workspace/coremark/coremark”
make port_prebuild
make[2]: 进入目录“/home/caozilong/Workspace/coremark/coremark”
make[2]: 对“port_prebuild”无需做任何事。
make[2]: 离开目录“/home/caozilong/Workspace/coremark/coremark”
make link
make[2]: 进入目录“/home/caozilong/Workspace/coremark/coremark”
cc -O2 -Ilinux -Iposix -I. -DFLAGS_STR=\""-O2 -DPERFORMANCE_RUN=1  -lrt"\" -DITERATIONS=0 -DPERFORMANCE_RUN=1 core_list_join.c core_main.c core_matrix.c core_state.c core_util.c posix/core_portme.c -o ./coremark.exe -lrt
Link performed along with compile
make[2]: 离开目录“/home/caozilong/Workspace/coremark/coremark”
make port_postbuild
make[2]: 进入目录“/home/caozilong/Workspace/coremark/coremark”
make[2]: 对“port_postbuild”无需做任何事。
make[2]: 离开目录“/home/caozilong/Workspace/coremark/coremark”
make port_preload
make[2]: 进入目录“/home/caozilong/Workspace/coremark/coremark”
make[2]: 对“port_preload”无需做任何事。
make[2]: 离开目录“/home/caozilong/Workspace/coremark/coremark”
echo Loading done ./coremark.exe
Loading done ./coremark.exe
make port_postload
make[2]: 进入目录“/home/caozilong/Workspace/coremark/coremark”
make[2]: 对“port_postload”无需做任何事。
make[2]: 离开目录“/home/caozilong/Workspace/coremark/coremark”
make port_prerun
make[2]: 进入目录“/home/caozilong/Workspace/coremark/coremark”
make[2]: 对“port_prerun”无需做任何事。
make[2]: 离开目录“/home/caozilong/Workspace/coremark/coremark”
./coremark.exe  0x0 0x0 0x66 0 7 1 2000 > ./run1.log
make port_postrun
make[2]: 进入目录“/home/caozilong/Workspace/coremark/coremark”
make[2]: 对“port_postrun”无需做任何事。
make[2]: 离开目录“/home/caozilong/Workspace/coremark/coremark”
make[1]: 离开目录“/home/caozilong/Workspace/coremark/coremark”
make XCFLAGS=" -DVALIDATION_RUN=1" load run2.log
make[1]: 进入目录“/home/caozilong/Workspace/coremark/coremark”
make port_preload
make[2]: 进入目录“/home/caozilong/Workspace/coremark/coremark”
make[2]: 对“port_preload”无需做任何事。
make[2]: 离开目录“/home/caozilong/Workspace/coremark/coremark”
echo Loading done ./coremark.exe
Loading done ./coremark.exe
make port_postload
make[2]: 进入目录“/home/caozilong/Workspace/coremark/coremark”
make[2]: 对“port_postload”无需做任何事。
make[2]: 离开目录“/home/caozilong/Workspace/coremark/coremark”
make port_prerun
make[2]: 进入目录“/home/caozilong/Workspace/coremark/coremark”
make[2]: 对“port_prerun”无需做任何事。
make[2]: 离开目录“/home/caozilong/Workspace/coremark/coremark”
./coremark.exe  0x3415 0x3415 0x66 0 7 1 2000  > ./run2.log
make port_postrun
make[2]: 进入目录“/home/caozilong/Workspace/coremark/coremark”
make[2]: 对“port_postrun”无需做任何事。
make[2]: 离开目录“/home/caozilong/Workspace/coremark/coremark”
make[1]: 离开目录“/home/caozilong/Workspace/coremark/coremark”
Check run1.log and run2.log for results.
See README.md for run and reporting rules.
caozilong@caozilong-Vostro-3268:~/Workspace/coremark/coremark$ 

dhrystone和coremark测试比较_第2张图片

编译生成了coremark.exe,可以单独执行

dhrystone和coremark测试比较_第3张图片

使用QEMU运行

qemu-x86_64   ./coremark.exe 

可以看到,使用模拟器后,分数降低了很多

caozilong@caozilong-Vostro-3268:~/Workspace/coremark/coremark$ qemu-x86_64 ./coremark.exe 
warning: TCG doesn't support requested feature: CPUID.01H:ECX.vmx [bit 5]

2K performance run parameters for coremark.
CoreMark Size    : 666
Total ticks      : 15239
Total time (secs): 15.239000
Iterations/Sec   : 7218.321412
Iterations       : 110000
Compiler version : GCC7.5.0
Compiler flags   : -O2 -DPERFORMANCE_RUN=1  -lrt
Memory location  : Please put data memory location here
			(e.g. code in flash, data on heap etc)
seedcrc          : 0xe9f5
[0]crclist       : 0xe714
[0]crcmatrix     : 0x1fd7
[0]crcstate      : 0x8e3a
[0]crcfinal      : 0x33ff
Correct operation validated. See README.md for run and reporting rules.
CoreMark 1.0 : 7218.321412 / GCC7.5.0 -O2 -DPERFORMANCE_RUN=1  -lrt / Heap

gem5的测试结果

./build/X86/gem5.opt configs/example/se.py -c ~/Workspace/coremark/coremark/coremark.exe
caozilong@caozilong-Vostro-3268:~/Workspace/gem5$ ./build/X86/gem5.opt configs/example/se.py -c ~/Workspace/coremark/coremark/coremark.exe 
gem5 Simulator System.  http://gem5.org
gem5 is copyrighted software; use the --copyright option for details.

gem5 version 21.2.1.0
gem5 compiled Oct  1 2022 21:53:41
gem5 started Oct  1 2022 22:49:47
gem5 executing on caozilong-Vostro-3268, pid 10229
command line: ./build/X86/gem5.opt configs/example/se.py -c /home/caozilong/Workspace/coremark/coremark/coremark.exe

Global frequency set at 1000000000000 ticks per second
warn: No dot file generated. Please install pydot to generate the dot file and pdf.
build/X86/mem/mem_interface.cc:793: warn: DRAM device capacity (8192 Mbytes) does not match the address range assigned (512 Mbytes)
0: system.remote_gdb: listening for remote gdb on port 7000
**** REAL SIMULATION ****
build/X86/sim/simulate.cc:194: info: Entering event queue @ 0.  Starting simulation...
build/X86/sim/syscall_emul.cc:74: warn: ignoring syscall mprotect(...)
build/X86/sim/syscall_emul.cc:74: warn: ignoring syscall mprotect(...)
build/X86/sim/mem_state.cc:443: info: Increasing stack size by one page.
build/X86/sim/syscall_emul.cc:74: warn: ignoring syscall mprotect(...)
build/X86/sim/syscall_emul.cc:74: warn: ignoring syscall mprotect(...)
build/X86/sim/syscall_emul.cc:74: warn: ignoring syscall mprotect(...)
build/X86/sim/syscall_emul.cc:74: warn: ignoring syscall mprotect(...)
build/X86/sim/syscall_emul.cc:74: warn: ignoring syscall mprotect(...)
build/X86/sim/syscall_emul.cc:74: warn: ignoring syscall mprotect(...)
build/X86/sim/syscall_emul.cc:74: warn: ignoring syscall set_robust_list(...)
build/X86/sim/syscall_emul.cc:86: warn: ignoring syscall rt_sigaction(...)
      (further warnings will be suppressed)
build/X86/sim/syscall_emul.cc:86: warn: ignoring syscall rt_sigprocmask(...)
      (further warnings will be suppressed)
2K performance run parameters for coremark.
CoreMark Size    : 666
Total ticks      : 13768
Total time (secs): 13.768000
Iterations/Sec   : 2905.287623
Iterations       : 40000
Compiler version : GCC7.5.0
Compiler flags   : -O2 -DPERFORMANCE_RUN=1  -lrt
Memory location  : Please put data memory location here
			(e.g. code in flash, data on heap etc)
seedcrc          : 0xe9f5
[0]crclist       : 0xe714
[0]crcmatrix     : 0x1fd7
[0]crcstate      : 0x8e3a
[0]crcfinal      : 0x25b5
Correct operation validated. See README.md for run and reporting rules.
CoreMark 1.0 : 2905.287623 / GCC7.5.0 -O2 -DPERFORMANCE_RUN=1  -lrt / Heap
Exiting @ tick 17592221426500 because exiting with last active thread context

dhrystone和coremark测试比较_第4张图片


结束

你可能感兴趣的:(金融,汽车,linux,服务器,运维)