本文來(lái)源電子發(fā)燒友社區(qū),作者:李先生, 帖子地址:https://bbs.elecfans.com/jishu_2304985_1_1.html
前言
板子的性能不僅僅和CPU相關(guān),也和存儲(chǔ)等相關(guān),是一個(gè)綜合體現(xiàn),所以我們從CPU,存儲(chǔ),等幾個(gè)關(guān)鍵的部分去進(jìn)行性能測(cè)試。
CPU性能:Coremark跑分
git clone [https://github.com/eembc/coremark.git](https://github.com/eembc/coremark.git)
cd coremark/
單線(xiàn)程
打印信息如下
root@firefly:~/coremark# make ITERATIONS=100000
make XCFLAGS=" -DPERFORMANCE_RUN=1" load run1.log
make[1]: Entering directory '/root/coremark'
make port_prebuild
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_prebuild'.
make[2]: Leaving directory '/root/coremark'
make link
make[2]: Entering directory '/root/coremark'
cc -O2 -Ilinux -Iposix -I. -DFLAGS_STR=""-O2 -DPERFORMANCE_RUN=1 -lrt"" -DITERATIONS=100000 -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]: Leaving directory '/root/coremark'
make port_postbuild
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_postbuild'.
make[2]: Leaving directory '/root/coremark'
make port_preload
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_preload'.
make[2]: Leaving directory '/root/coremark'
echo Loading done ./coremark.exe
Loading done ./coremark.exe
make port_postload
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_postload'.
make[2]: Leaving directory '/root/coremark'
make port_prerun
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_prerun'.
make[2]: Leaving directory '/root/coremark'
./coremark.exe 0x0 0x0 0x66 100000 7 1 2000 > ./run1.log
make port_postrun
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_postrun'.
make[2]: Leaving directory '/root/coremark'
make[1]: Leaving directory '/root/coremark'
make XCFLAGS=" -DVALIDATION_RUN=1" load run2.log
make[1]: Entering directory '/root/coremark'
make port_preload
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_preload'.
make[2]: Leaving directory '/root/coremark'
echo Loading done ./coremark.exe
Loading done ./coremark.exe
make port_postload
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_postload'.
make[2]: Leaving directory '/root/coremark'
make port_prerun
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_prerun'.
make[2]: Leaving directory '/root/coremark'
./coremark.exe 0x3415 0x3415 0x66 100000 7 1 2000 > ./run2.log
make port_postrun
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_postrun'.
make[2]: Leaving directory '/root/coremark'
make[1]: Leaving directory '/root/coremark'
Check run1.log and run2.log for results.
See README.md for run and reporting rules.
run1.log
root@firefly:~/coremark# vi run1.log
2K performance run parameters for coremark.
CoreMark Size : 666
Total ticks : 14036
Total time (secs): 14.036000
Iterations/Sec : 7124.536905
Iterations : 100000
Compiler version : GCC9.4.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 : 0xd340
Correct operation validated. See README.md for run and reporting rules.
CoreMark 1.0 : 7124.536905 / GCC9.4.0 -O2 -DPERFORMANCE_RUN=1 -lrt / Heap
run2.log
root@firefly:~/coremark# vi run2.log
2K validation run parameters for coremark.
CoreMark Size : 666
Total ticks : 14138
Total time (secs): 14.138000
Iterations/Sec : 7073.136229
Iterations : 100000
Compiler version : GCC9.4.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 : 0x18f2
[0]crclist : 0xe3c1
[0]crcmatrix : 0x0747
[0]crcstate : 0x8d84
[0]crcfinal : 0x5c66
Correct operation validated. See README.md for run and reporting rules.
多線(xiàn)程
make XCFLAGS="-DMULTITHREAD=4 -DUSE_FORK"
打印如下
root@firefly:~/coremark# make XCFLAGS="-DMULTITHREAD=4 -DUSE_FORK"
make XCFLAGS="-DMULTITHREAD=4 -DUSE_FORK -DPERFORMANCE_RUN=1" load run1.log
make[1]: Entering directory '/root/coremark'
make port_preload
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_preload'.
make[2]: Leaving directory '/root/coremark'
echo Loading done ./coremark.exe
Loading done ./coremark.exe
make port_postload
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_postload'.
make[2]: Leaving directory '/root/coremark'
make port_prerun
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_prerun'.
make[2]: Leaving directory '/root/coremark'
./coremark.exe 0x0 0x0 0x66 0 7 1 2000 > ./run1.log
make port_postrun
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_postrun'.
make[2]: Leaving directory '/root/coremark'
make[1]: Leaving directory '/root/coremark'
make XCFLAGS="-DMULTITHREAD=4 -DUSE_FORK -DVALIDATION_RUN=1" load run2.log
make[1]: Entering directory '/root/coremark'
make port_preload
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_preload'.
make[2]: Leaving directory '/root/coremark'
echo Loading done ./coremark.exe
Loading done ./coremark.exe
make port_postload
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_postload'.
make[2]: Leaving directory '/root/coremark'
make port_prerun
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_prerun'.
make[2]: Leaving directory '/root/coremark'
./coremark.exe 0x3415 0x3415 0x66 0 7 1 2000 > ./run2.log
make port_postrun
make[2]: Entering directory '/root/coremark'
make[2]: Nothing to be done for 'port_postrun'.
make[2]: Leaving directory '/root/coremark'
make[1]: Leaving directory '/root/coremark'
Check run1.log and run2.log for results.
See README.md for run and reporting rules.
run1.log
root@firefly:~/coremark# vi run1.log
2K performance run parameters for coremark.
CoreMark Size : 666
Total ticks : 15471
Total time (secs): 15.471000
Iterations/Sec : 28440.307672
Iterations : 440000
Compiler version : GCC9.4.0
Compiler flags : -O2 -DMULTITHREAD=4 -DUSE_FORK -DPERFORMANCE_RUN=1 -lrt
Parallel Fork : 4
Memory location : Please put data memory location here
(e.g. code in flash, data on heap etc)
seedcrc : 0xe9f5
[0]crclist : 0xe714
[1]crclist : 0xe714
[2]crclist : 0xe714
[3]crclist : 0xe714
[0]crcmatrix : 0x1fd7
[1]crcmatrix : 0x1fd7
[2]crcmatrix : 0x1fd7
[3]crcmatrix : 0x1fd7
[0]crcstate : 0x8e3a
[1]crcstate : 0x8e3a
[2]crcstate : 0x8e3a
[3]crcstate : 0x8e3a
[0]crcfinal : 0x33ff
[1]crcfinal : 0x33ff
[2]crcfinal : 0x33ff
[3]crcfinal : 0x33ff
Correct operation validated. See README.md for run and reporting rules.
CoreMark 1.0 : 28440.307672 / GCC9.4.0 -O2 -DMULTITHREAD=4 -DUSE_FORK -DPERFORMANCE_RUN=1 -lrt / Heap / 4:Fork
~
run2.log
root@firefly:~/coremark# vi run2.log
2K validation run parameters for coremark.
CoreMark Size : 666
Total ticks : 15582
Total time (secs): 15.582000
Iterations/Sec : 28237.710178
Iterations : 440000
Compiler version : GCC9.4.0
Compiler flags : -O2 -DMULTITHREAD=4 -DUSE_FORK -DPERFORMANCE_RUN=1 -lrt
Parallel Fork : 4
Memory location : Please put data memory location here
(e.g. code in flash, data on heap etc)
seedcrc : 0x18f2
[0]crclist : 0xe3c1
[1]crclist : 0xe3c1
[2]crclist : 0xe3c1
[3]crclist : 0xe3c1
[0]crcmatrix : 0x0747
[1]crcmatrix : 0x0747
[2]crcmatrix : 0x0747
[3]crcmatrix : 0x0747
[0]crcstate : 0x8d84
[1]crcstate : 0x8d84
[2]crcstate : 0x8d84
[3]crcstate : 0x8d84
[0]crcfinal : 0x0956
[1]crcfinal : 0x0956
[2]crcfinal : 0x0956
[3]crcfinal : 0x0956
Correct operation validated. See README.md for run and reporting rules.
對(duì)比
https://www.eembc.org/coremark/scores.php
下搜索A55沒(méi)有對(duì)應(yīng)的芯片的跑分,
可以和A53對(duì)比下,
我們這里的得分28440比A53的19678還是高很多的,并且還僅是-O2優(yōu)化。
計(jì)算圓周率
time echo "[scale](https://so.csdn.net/so/search?q=scale&spm=1001.2101.3001.7020)=5000; 4*a(1)" | bc -l -q
執(zhí)行時(shí)間如下
real 0m47.623s
user 0m47.596s
sys 0m0.012s
RAM
帶寬
參考https://www.cs.virginia.edu/stream/ref.html
git clone [https://github.com/qinyunti/STREAM.git](https://github.com/qinyunti/STREAM.git)
cd STREAM/
gcc -O3 stream.c -o stream
打印如下
root@firefly:~/coremark/STREAM# ./stream
---
STREAM version $Revision: 5.10 $
---
This system uses 8 bytes per array element.
---
Array size = 10000000 (elements), Offset = 0 (elements)
Memory per array = 76.3 MiB (= 0.1 GiB).
Total memory required = 228.9 MiB (= 0.2 GiB).
Each kernel will be executed 10 times.
The *best* time for each kernel (excluding the first iteration)
will be used to compute the reported bandwidth.
---
Your clock granularity/precision appears to be 1 microseconds.
Each test below will take on the order of 43055 microseconds.
(= 43055 clock ticks)
Increase the size of the arrays if this shows that
you are not getting at least 20 clock ticks per test.
---
WARNING -- The above is only a rough guideline.
For best results, please be sure you know the
precision of your system timer.
---
Function Best Rate MB/s Avg time Min time Max time
Copy: 6306.2 0.025627 0.025372 0.025743
Scale: 5647.5 0.028464 0.028331 0.028618
Add: 5446.5 0.044271 0.044065 0.044582
Triad: 5169.9 0.046605 0.046423 0.046989
---
Solution Validates: avg error less than 1.000000e-13 on all three arrays
壓力測(cè)試
參考https://pyropus.ca./software/memtester/
wget [https://pyropus.ca./software/memtester/old-versions/memtester-4.5.1.tar.gz](https://pyropus.ca./software/memtester/old-versions/memtester-4.5.1.tar.gz)
tar -xvf memtester-4.5.1.tar.gz
cd memtester-4.5.1/
gcc -O3 memtester.c tests.c -o memtester
./memtester 512M 1
512M表示測(cè)試RAM大小
1表示測(cè)試一次
打印如下
root@firefly:~/memtester-4.5.1# ./memtester 512M 1
memtester version 4.5.1 (64-bit)
Copyright (C) 2001-2020 Charles Cazabon.
Licensed under the GNU General Public License version 2 (only).
pagesize is 4096
pagesizemask is 0xfffffffffffff000
want 512MB (536870912 bytes)
got 512MB (536870912 bytes), trying mlock ...locked.
Loop 1/1:
Stuck Address : ok
Random Value : ok
Compare XOR : ok
Compare SUB : ok
Compare MUL : ok
Compare DIV : ok
Compare OR : ok
Compare AND : ok
Sequential Increment: ok
Solid Bits : ok
Block Sequential : ok
Checkerboard : ok
Bit Spread : ok
Bit Flip : ok
Walking Ones : ok
Walking Zeroes : ok
Done.
EMMC
dmesg | grep mmc
可以看到打印
1.975460] mmc3: new ultra high speed SDR104 SDIO card at address 0001
[ 2.312867] mmc3:mmc host rescan start!
其中high speed SDR104表示emmc 設(shè)備支持的時(shí)鐘模式:
Speed Mode | clock (MHz) |
---|---|
Default Speed | 26 |
Hight Speed SDR | 52 |
Hight Speed DDR | 52 |
HS200 | 200 |
HS400 | 200 |
SDR : 單邊沿采樣
DDR : 雙邊沿采樣
所以我們這里x8-bit理論最大吞吐量應(yīng)該是52MB/S。
輸入df回車(chē)
我們看到EMMC的/dev/mmcblk0p7掛在了目錄/userdata
我們就在該目錄下讀寫(xiě)文件測(cè)試
root@firefly:~/memtester-4.5.1# df
Filesystem 1K-blocks Used Available Use% Mounted on
udev 1984744 8 1984736 1% /dev
tmpfs 399616 1168 398448 1% /run
/dev/mmcblk0p6 2666944 2599912 0 100% /root-ro
/dev/mmcblk0p7 26999224 6355668 20627172 24% /userdata
overlayroot 26999224 6355668 20627172 24% /
tmpfs 1998060 0 1998060 0% /dev/shm
tmpfs 5120 4 5116 1% /run/lock
tmpfs 1998060 0 1998060 0% /sys/fs/cgroup
tmpfs 399612 0 399612 0% /run/user/0
tmpfs 399612 8 399604 1% /run/user/1000
root@firefly:~/memtester-4.5.1#
讀
dd if=/userdata/test.bin of=/dev/null bs=塊大小 count=塊數(shù)量
寫(xiě)
dd if=/dev/zero of=/userdata/test.bin bs=塊大小 count=塊數(shù)量
測(cè)試記錄如下
bs/count 1GB | bs/count 1GB | 指令 | 結(jié)果 |
---|---|---|---|
讀 | 16k/65536 | dd if=/userdata/test.bin of=/dev/null bs=16k count=65536 iflag=direct | 36.5 MB/s |
4k/262144 | dd if=/userdata/test.bin of=/dev/null bs=4k count=262144 iflag=direct | 14.7 MB/s | |
1k/1048576 | dd if=/userdata/test.bin of=/dev/null bs=1k count=10485764 iflag=direct | 2.2 MB/s | |
寫(xiě) | 16k/65536 | dd if=/dev/zero of=/userdata/test.bin bs=16k count=65536 conv=fdatasync | 118 MB/s |
4k/262144 | dd if=/dev/zero of=/userdata/test.bin bs=4k count=262144 conv=fdatasync | 112 MB/s | |
1k/1048576 | dd if=/dev/zero of=/userdata/test.bin bs=1k count=1048576 conv=fdatasync | 64.6 MB/s |
QT
sudo apt-get install qt5-default qtcreator
直接板上使用qtcreator開(kāi)發(fā),操作也比較流暢
GPU
sudo apt install glmark2
運(yùn)行
輸入glmark2回車(chē)
最終得分
=======================================================
glmark2 Score: 49
=======================================================
視頻硬件編解碼
/usr/local/test.mp4
1080P, 24Fps, H264
播放流暢
總結(jié)
綜合各方面,該開(kāi)發(fā)板性能都非常不錯(cuò),特別適合人機(jī)交互,AI,邊緣計(jì)算等高性能要求的場(chǎng)景。
-
RK3568
+關(guān)注
關(guān)注
4文章
526瀏覽量
5238 -
開(kāi)發(fā)板試用
+關(guān)注
關(guān)注
3文章
301瀏覽量
2152
發(fā)布評(píng)論請(qǐng)先 登錄
相關(guān)推薦
迅為RK3568開(kāi)發(fā)板驅(qū)動(dòng)指南Linux中通用SPI設(shè)備驅(qū)動(dòng)
![迅為<b class='flag-5'>RK3568</b><b class='flag-5'>開(kāi)發(fā)板</b>驅(qū)動(dòng)指南Linux中通用SPI設(shè)備驅(qū)動(dòng)](https://file1.elecfans.com/web3/M00/06/FF/wKgZO2eRsTyAQNODAACATQzlR7A177.png)
[迅為RK3568開(kāi)發(fā)板]非科班也能玩轉(zhuǎn)Android應(yīng)用,體驗(yàn)QT跨平臺(tái)能力
![[迅為<b class='flag-5'>RK3568</b><b class='flag-5'>開(kāi)發(fā)板</b>]非科班也能玩轉(zhuǎn)Android應(yīng)用,體驗(yàn)QT跨平臺(tái)能力](https://file1.elecfans.com/web3/M00/02/F1/wKgZO2diirGAPoENAACpt0CV3xc346.png)
RK3568內(nèi)置MCU開(kāi)發(fā)介紹之一
![<b class='flag-5'>RK3568</b>內(nèi)置MCU<b class='flag-5'>開(kāi)發(fā)</b>介紹之一](https://file1.elecfans.com/web3/M00/00/A2/wKgZPGdLMg-AFkS0AAA5BGKqG3E264.png)
【迅為電子】叮!您的RK3568開(kāi)發(fā)板系統(tǒng)鏡像備份方法請(qǐng)查收
![【迅為電子】叮!您的<b class='flag-5'>RK3568</b><b class='flag-5'>開(kāi)發(fā)板</b>系統(tǒng)鏡像備份方法請(qǐng)查收](https://file1.elecfans.com/web3/M00/00/20/wKgZO2dGtgGAI-V6AACJSeqLjMw980.png)
基于迅為RK3568開(kāi)發(fā)板全國(guó)產(chǎn)平臺(tái),快速實(shí)現(xiàn)APP開(kāi)機(jī)自啟動(dòng)技術(shù)分享
![基于迅為<b class='flag-5'>RK3568</b><b class='flag-5'>開(kāi)發(fā)板</b>全國(guó)產(chǎn)平臺(tái),快速實(shí)現(xiàn)APP開(kāi)機(jī)自啟動(dòng)技術(shù)分享](https://file1.elecfans.com/web2/M00/0C/FB/wKgaomc-y_CAM0OEAACic4bprx8519.png)
能力再次提升! 迅為RK3588/RK3568開(kāi)發(fā)板&amp;核心板新增定制分區(qū)鏡像
![能力再次提升! 迅為<b class='flag-5'>RK</b>3588/<b class='flag-5'>RK3568</b><b class='flag-5'>開(kāi)發(fā)板</b>&amp;核心<b class='flag-5'>板</b>新增定制分區(qū)鏡像](https://file1.elecfans.com/web2/M00/0B/E0/wKgaomcrFqCAPVkfAAC-6O-KM4Q713.png)
瑞芯微RK3568鴻蒙開(kāi)發(fā)板OpenHarmony系統(tǒng)修改cfg文件權(quán)限方法
![瑞芯微<b class='flag-5'>RK3568</b>鴻蒙<b class='flag-5'>開(kāi)發(fā)板</b>OpenHarmony系統(tǒng)修改cfg文件權(quán)限方法](https://file1.elecfans.com/web2/M00/06/01/wKgZombhKSWAfaYCAACRBodpoiI952.png)
北京迅為RK3568開(kāi)發(fā)板嵌入式學(xué)習(xí)之Linux驅(qū)動(dòng)全新更新-CAN+
![北京迅為<b class='flag-5'>RK3568</b><b class='flag-5'>開(kāi)發(fā)板</b>嵌入式學(xué)習(xí)之Linux驅(qū)動(dòng)全新更新-CAN+](https://file1.elecfans.com/web2/M00/06/25/wKgaombYDFKAD0JxAADlDQo6OXo738.png)
國(guó)產(chǎn)核心板全面進(jìn)攻-RK3568開(kāi)發(fā)板評(píng)測(cè)
![國(guó)產(chǎn)核心<b class='flag-5'>板</b><b class='flag-5'>全面</b>進(jìn)攻-<b class='flag-5'>RK3568</b><b class='flag-5'>開(kāi)發(fā)板</b>評(píng)測(cè)](https://file.elecfans.com/web2/M00/08/64/pYYBAGDwFEGADIPWAAFlJOlmLxg664.jpg)
鴻蒙OpenHarmony南向:【RK3568開(kāi)發(fā)板介紹】
![鴻蒙OpenHarmony南向:【<b class='flag-5'>RK3568</b><b class='flag-5'>開(kāi)發(fā)板</b>介紹】](https://file1.elecfans.com/web2/M00/D8/1F/wKgZomYpEAGALxyGABBtbKfhj8Q460.jpg)
鴻蒙OpenHarmony【標(biāo)準(zhǔn)系統(tǒng)編譯】 (基于RK3568開(kāi)發(fā)板)
![鴻蒙OpenHarmony【標(biāo)準(zhǔn)系統(tǒng)編譯】 (基于<b class='flag-5'>RK3568</b><b class='flag-5'>開(kāi)發(fā)板</b>)](https://file1.elecfans.com/web2/M00/C5/D1/wKgZomYChGOAUaiiAADe1d8SeRY102.jpg)
迅為RK3568開(kāi)發(fā)板驅(qū)動(dòng)開(kāi)發(fā)指南-輸入子系統(tǒng)
![迅為<b class='flag-5'>RK3568</b><b class='flag-5'>開(kāi)發(fā)板</b>驅(qū)動(dòng)<b class='flag-5'>開(kāi)發(fā)</b>指南-輸入子系統(tǒng)](https://file1.elecfans.com/web2/M00/C0/BF/wKgZomXYRRKAMTL1AAAnOMdfhdU008.png)
評(píng)論