当前位置:网站首页>HLS4ML/vivado HLS 报错解决方案
HLS4ML/vivado HLS 报错解决方案
2022-07-01 18:46:00 【heisenberg.liu】
用HLS4ML到 hls_model.build()的时候报错
报错内容
/opt/Xilinx/Vivado/2019.1/include/mpfr.h:724:28: error: ‘mpfr_srcptr’ was not declared in this scope
__MPFR_DECLSPEC int mpfr_custom_get_kind _MPFR_PROTO ((mpfr_srcptr));
^~~~~~~~~~~
make: *** [obj/myproject.cpp_pre.cpp.tb.o] Error 1
ERROR: [COSIM 212-317] C++ compile error.
ERROR: [COSIM 212-321] EXE file generate failed.
ERROR: [COSIM 212-321] EXE file generate failed.
ERROR: [COSIM 212-331] Aborting co-simulation: C simulation failed, compilation errors.
ERROR: [COSIM 212-5] *** C/RTL co-simulation file generation failed. ***
ERROR: [COSIM 212-4] *** C/RTL co-simulation finished: FAIL ***
command 'ap_source' returned error code
while executing
"source build_prj.tcl"
("uplevel" body line 1)
invoked from within
"uplevel \#0 [list source $arg] "
INFO: [HLS 200-112] Total elapsed time: 578.3 seconds; peak allocated memory: 1.226 GB.
INFO: [Common 17-206] Exiting vivado_hls at Tue Dec 14 15:45:32 2021...
child process exited
原因是因为GCC文件冲突,这里用的是vivado2019.2
解决方案:
- 把
/tools/Xilinx/Vivado/2019.2/include/mpfr.h中系统导入头文件<gmp.h>改为当前文件夹导入”gmp.h“
#ifndef __GMP_H__
#include "gmp.h"
#endif
- 在每个源文件(main.cpp和test.cpp,主文件路径在
my-hls-test/fireware/myproject.cpp,test文件在my-hls-test/fmyproject_test.cpp)头顶添加下面语句,这句话添加的位置靠前点儿
#include "/tools/Xilinx/Vivado/2019.2/include/gmp.h"
#define __gmp_const const
这个bug需要在每次生成my-hls-test文件夹之后手动修改cpp文件,因此不能在python文件中直接用hls_model.build(),需要命令行输入hls4ml build -p my-hls-test -a
参考:
边栏推荐
猜你喜欢

测试自学人必看:软件测试如何找测试项目?

Facebook聊单,SaleSmartly有妙招!

Oracle物理体系结构

音视频、编解码相关电子书、小工具,打包奉送!

118. Yanghui triangle

Native JS creates a calendar - supports mouse wheel scrolling to select months - and can be ported to any framework

Interview questions for audio and video positions in Dachang -- today's headline

Crunch简介、安装,使用Crunch制作密码字典

AAAI2020: Real-time Scene Text Detection with Differentiable Binarization

Why has instagram changed from a content sharing platform to a marketing tool? How do independent sellers use this tool?
随机推荐
新版国标GB28181视频平台EasyGBS如何配置WebRTC视频流格式播放?
Solution and summary of Nacos startup failure
Uni app wechat applet one click login to obtain permission function
集合对象值改变NULL值对象
Shell高级进阶
How to configure webrtc video streaming format for easygbs, a new version of national standard gb28181 video platform?
OpenCV视频质量检测--清晰度检测
EasyGBS网络不稳定情况下重复请求视频拉流问题的优化
How to redraw the header of CListCtrl in MFC
A brief understanding of white box encryption technology
科技T3国产平台!成功搭载“翼辉国产实时系统SylixOS”
SIP protocol of gb28181
EasyGBS主子码流都为H.265时,切换出现花屏如何解决?
CMU AI PhD 第一年总结
[go ~ 0 to 1] day 4 June 30 defer, structure, method
What must be done in graduation season before going to Shanhai
win10下使用msys+vs2019编译ffmpeg源码
下载(导出)pdf模板文件(比如:审批单),报错:Invalid nested tag *** found, expected closing tag ***
精耕渠道共謀發展 福昕攜手偉仕佳傑開展新產品培訓大會
Shell advanced