【NUCLEO-L552ZE测评】+CoreMark跑分测试
<div class='showpostmsg'> 本帖最后由 dql2016 于 2020-12-20 19:09 编辑<div align="left" style="text-indent:0px; -webkit-text-stroke-width:0px"><span style="font-size:14px"><span style="overflow-wrap:break-word"><span style="color:#444444"><span style="font-family:Tahoma, "Microsoft Yahei", Simsun"><span style="font-style:normal"><span style="font-variant-ligatures:normal"><span style="font-variant-caps:normal"><span style="font-weight:400"><span style="letter-spacing:normal"><span style="orphans:2"><span style="text-transform:none"><span style="white-space:normal"><span style="widows:2"><span style="word-spacing:0px"><span style="background-color:#ffffff"><span style="text-decoration-thickness:initial"><span style="text-decoration-style:initial"><span style="text-decoration-color:initial">CoreMark是用来衡量嵌入式系统中中心处理单元(CPU,或叫做微控制器MCU)性能的标准。该标准于2009年由EEMBC组织的Shay Gla-On提出,并且试图将其发展成为工业标准,从而代替陈旧的Dhrystone标准。代码使用C语言写成,包含如下的运算法则:列举(寻找并排序),数学矩阵操作(普通矩阵运算)和状态机(用来确定输入流中是否包含有效数字),最后还包括CRC(循环冗余校验)。目前CoreMark已迅速成为测量与比较处理器性能的业界标准基准测试。</span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></div>
<div align="left" style="text-indent:0px; -webkit-text-stroke-width:0px"><span style="font-size:14px"><span style="overflow-wrap:break-word"><span style="color:#444444"><span style="font-family:Tahoma, "Microsoft Yahei", Simsun"><span style="font-style:normal"><span style="font-variant-ligatures:normal"><span style="font-variant-caps:normal"><span style="font-weight:400"><span style="letter-spacing:normal"><span style="orphans:2"><span style="text-transform:none"><span style="white-space:normal"><span style="widows:2"><span style="word-spacing:0px"><span style="background-color:#ffffff"><span style="text-decoration-thickness:initial"><span style="text-decoration-style:initial"><span style="text-decoration-color:initial"><strong style="overflow-wrap:break-word; font-weight:700"><font color="#ff0000"><font style="overflow-wrap: break-word;">CoreMark的得分越高,意味着性能更高。</font></font></strong></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></div>
<div align="left" style="text-indent:0px; -webkit-text-stroke-width:0px"><span style="font-size:14px"><span style="overflow-wrap:break-word"><span style="color:#444444"><span style="font-family:Tahoma, "Microsoft Yahei", Simsun"><span style="font-style:normal"><span style="font-variant-ligatures:normal"><span style="font-variant-caps:normal"><span style="font-weight:400"><span style="letter-spacing:normal"><span style="orphans:2"><span style="text-transform:none"><span style="white-space:normal"><span style="widows:2"><span style="word-spacing:0px"><span style="background-color:#ffffff"><span style="text-decoration-thickness:initial"><span style="text-decoration-style:initial"><span style="text-decoration-color:initial">在CoreMark的官网上可以看到STM32L552的CoreMark得分:</span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></div>
<div align="left" style="text-indent:0px; -webkit-text-stroke-width:0px"></div>
<div align="left" style="text-indent:0px; -webkit-text-stroke-width:0px">
<div align="left" style="text-indent:0px; -webkit-text-stroke-width:0px"> </div>
<div align="left" style="text-indent:0px; -webkit-text-stroke-width:0px">ST官方测试结果如下:</div>
<div align="left" style="text-indent:0px; -webkit-text-stroke-width:0px"></div>
<div align="left" style="text-indent:0px; -webkit-text-stroke-width:0px"><span style="font-size:14px"><span style="overflow-wrap:break-word"><span style="color:#444444"><span style="font-family:Tahoma, "Microsoft Yahei", Simsun"><span style="font-style:normal"><span style="font-variant-ligatures:normal"><span style="font-variant-caps:normal"><span style="font-weight:400"><span style="letter-spacing:normal"><span style="orphans:2"><span style="text-transform:none"><span style="white-space:normal"><span style="widows:2"><span style="word-spacing:0px"><span style="background-color:#ffffff"><span style="text-decoration-thickness:initial"><span style="text-decoration-style:initial"><span style="text-decoration-color:initial">也可以从CoreMark的官网上下载测试代码移植到自己的MCU上,亲自测试性能。</span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></div>
<div align="left" style="text-indent:0px; -webkit-text-stroke-width:0px"><span style="font-size:14px"><span style="overflow-wrap:break-word"><span style="color:#444444"><span style="font-family:Tahoma, "Microsoft Yahei", Simsun"><span style="font-style:normal"><span style="font-variant-ligatures:normal"><span style="font-variant-caps:normal"><span style="font-weight:400"><span style="letter-spacing:normal"><span style="orphans:2"><span style="text-transform:none"><span style="white-space:normal"><span style="widows:2"><span style="word-spacing:0px"><span style="background-color:#ffffff"><span style="text-decoration-thickness:initial"><span style="text-decoration-style:initial"><span style="text-decoration-color:initial">CoreMark官网下载地址地址:<a href="http://www.eembc.org/coremark/index.php" style="overflow-wrap:break-word; color:#336699; text-decoration:underline" target="_blank">https://www.eembc.org/coremark/download.php</a></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></div>
<div align="left" style="text-indent:0px; -webkit-text-stroke-width:0px"><span style="font-size:14px"><span style="overflow-wrap:break-word"><span style="color:#444444"><span style="font-family:Tahoma, "Microsoft Yahei", Simsun"><span style="font-style:normal"><span style="font-variant-ligatures:normal"><span style="font-variant-caps:normal"><span style="font-weight:400"><span style="letter-spacing:normal"><span style="orphans:2"><span style="text-transform:none"><span style="white-space:normal"><span style="widows:2"><span style="word-spacing:0px"><span style="background-color:#ffffff"><span style="text-decoration-thickness:initial"><span style="text-decoration-style:initial"><span style="text-decoration-color:initial">我这里下载的为<strong style="overflow-wrap:break-word; font-weight:700"><i style="overflow-wrap:break-word; font-style:italic">coremark_v1.0.1zip</i></strong>。</span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></div>
<div align="left" style="text-indent:0px; -webkit-text-stroke-width:0px"></div>
<div align="left" style="text-indent:0px; -webkit-text-stroke-width:0px"><span style="font-size:14px"><span style="overflow-wrap:break-word"><span style="color:#444444"><span style="font-family:Tahoma, "Microsoft Yahei", Simsun"><span style="font-style:normal"><span style="font-variant-ligatures:normal"><span style="font-variant-caps:normal"><span style="font-weight:400"><span style="letter-spacing:normal"><span style="orphans:2"><span style="text-transform:none"><span style="white-space:normal"><span style="widows:2"><span style="word-spacing:0px"><span style="background-color:#ffffff"><span style="text-decoration-thickness:initial"><span style="text-decoration-style:initial"><span style="text-decoration-color:initial">在STM32中文官网<a href="http://www.stmcu.com.cn/" style="overflow-wrap:break-word; color:#336699; text-decoration:underline" target="_blank">http://www.stmcu.com.cn/</a>搜索CoreMark即可找到应用笔记</span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span><span style="color:#e74c3c;"><span style="font-family:Tahoma, "Microsoft Yahei", Simsun"><span style="font-style:normal"><span style="font-variant-ligatures:normal"><span style="font-variant-caps:normal"><span style="font-weight:400"><span style="letter-spacing:normal"><span style="orphans:2"><span style="text-transform:none"><span style="white-space:normal"><span style="widows:2"><span style="word-spacing:0px"><span style="background-color:#ffffff"><span style="text-decoration-thickness:initial"><span style="text-decoration-style:initial"><span style="text-decoration-color:initial"><font style="overflow-wrap: break-word;"><font face="&quot;"><font style="overflow-wrap: break-word;"><font style="overflow-wrap:break-word; font-size:9pt"><i style="overflow-wrap:break-word; font-style:italic">如何将coremark程序移植到STM32上.pdf</i></font></font></font></font></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></div>
<div align="left" style="text-indent:0px; -webkit-text-stroke-width:0px"></div>
<div align="left" style="text-indent:0px; -webkit-text-stroke-width:0px"><span style="font-size:14px; text-align:-webkit-left; text-indent:0px; -webkit-text-stroke-width:0px"><span style="font-family: Tahoma, "Microsoft Yahei", Simsun;"><span style="font-style: normal;"><span style="font-variant-ligatures: normal;"><span style="font-variant-caps: normal;"><span style="font-weight: 400;"><span style="letter-spacing: normal;"><span style="orphans: 2;"><span style="text-transform: none;"><span style="white-space: normal;"><span style="widows: 2;"><span style="word-spacing: 0px;"><span style="background-color: rgb(255, 255, 255);"><span style="text-decoration-thickness: initial;"><span style="text-decoration-style: initial;"><span style="text-decoration-color: initial;"><span style="display: inline !important;"><span style="float: none;"><font color="#444444">移植步骤不再赘述,这里使用板卡的PG7、PG8低功耗串口1,全速110MHz</font>。</span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></div>
<div align="left" style="text-indent:0px; -webkit-text-stroke-width:0px"><span style="font-size:14px; text-align:-webkit-left; text-indent:0px; -webkit-text-stroke-width:0px"><span style="color:#444444"><span style="font-family:Tahoma, "Microsoft Yahei", Simsun"><span style="font-style:normal"><span style="font-variant-ligatures:normal"><span style="font-variant-caps:normal"><span style="font-weight:400"><span style="letter-spacing:normal"><span style="orphans:2"><span style="text-transform:none"><span style="white-space:normal"><span style="widows:2"><span style="word-spacing:0px"><span style="background-color:#ffffff"><span style="text-decoration-thickness:initial"><span style="text-decoration-style:initial"><span style="text-decoration-color:initial"><span style="display:inline !important"><span style="float:none">KEIL优化配置见下图:</span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></span></div>
<p> </p>
<p>将CoreMark相关文件添加到工程目录:</p>
<p> </p>
<p></p>
<p> </p>
<p>移植需要注意的是中断配置:</p>
<p></p>
<p><strong><span style="font-size:20px;"><span style="background-color:#2ecc71;">结果如下:</span></span></strong></p>
<p><strong><span style="color:#e74c3c;"><span style="font-size:16px;">关ICAHE</span></span></strong></p>
<p></p>
<p><strong><span style="font-size:16px;"><span style="color:#e74c3c;">开ICHAE 1-way模式</span></span></strong></p>
<p></p>
<p><strong><span style="font-size:16px;"><span style="color:#e74c3c;">开ICHAE 2-way模式</span></span></strong></p>
<p></p>
<p><span style="font-size:20px;"><span style="background-color:#2ecc71;">结果和官方相差有点大,比性能,keil ac6交叉编译工具链依然不如iar。。。</span></span></p>
<p>测试工程:</p>
<p></p>
<p> </p>
</div>
</div><script> var loginstr = '<div class="locked">查看本帖全部内容,请<a href="javascript:;" style="color:#e60000" class="loginf">登录</a>或者<a href="https://bbs.eeworld.com.cn/member.php?mod=register_eeworld.php&action=wechat" style="color:#e60000" target="_blank">注册</a></div>';
if(parseInt(discuz_uid)==0){
(function($){
var postHeight = getTextHeight(400);
$(".showpostmsg").html($(".showpostmsg").html());
$(".showpostmsg").after(loginstr);
$(".showpostmsg").css({height:postHeight,overflow:"hidden"});
})(jQuery);
} </script><script type="text/javascript">(function(d,c){var a=d.createElement("script"),m=d.getElementsByTagName("script"),eewurl="//counter.eeworld.com.cn/pv/count/";a.src=eewurl+c;m.parentNode.insertBefore(a,m)})(document,523)</script> <p>keil编译的性能竟然不如iar编译的性能。</p>
<p>棒!学到了</p>
<p><strong><a href="https://bbs.eeworld.com.cn/elecplay/content/153" target="_blank">ST新品NUCLEO-L552ZE-Q(Cortex-M33)</a></strong></p>
<p>汇总贴:<a href="https://bbs.eeworld.com.cn/thread-1152571-1-1.html" target="_blank">https://bbs.eeworld.com.cn/thread-1152571-1-1.html</a></p>
Rimas 发表于 2020-12-21 11:02
keil编译的性能竟然不如iar编译的性能。
棒!学到了
<p>官方给的 coremark 跑分是 IAR 编译出来的结果。Keil编译出来没达到,也没什么奇怪的。</p>
<p>我以前测试F7的时候用GCC,比Keil快,也没官方的高。GCC不同版本编译出来的跑分也不一样,不知道现在的GCC优化如何了。</p>
cruelfox 发表于 2020-12-21 15:19
官方给的 coremark 跑分是 IAR 编译出来的结果。Keil编译出来没达到,也没什么奇怪的。
我以前测试F7 ...
<p>差的相当多。。。100+分</p>
<p>新知识,我到时候也得试一试!</p>
cruelfox 发表于 2020-12-21 15:19
官方给的 coremark 跑分是 IAR 编译出来的结果。Keil编译出来没达到,也没什么奇怪的。
我以前测试F7 ...
<p>ac5 编译器编译速度慢的出奇,ac6到时很快了,不过性能嘛,原地踏步的样子。</p>
页:
[1]