RDK problems

43 views
Skip to first unread message

Sebastian Meisner

unread,
Nov 7, 2016, 12:22:06 PM11/7/16
to rec...@googlegroups.com
Hi!

I just cloned a fresh repo of the "develop" branch from
https://www.github.de/reconos/reconos.git.

I tried to build the hardware for the sortdemo using the reconos development
kit (rdk) however, it fails at compiling the HLS version of the sortdemo
thread (see [1] at end of mail). It seems like the rdk tries to feed the
unprocessed template files to Vivado HLS.

Any ideas how to solves this?


Kind regards
Sebastian


[1]
meise@pc-techinf-28:~/git/reconos_develop_fresh/demos/sort_demo$ LANG="" rdk
-l debug export_hw
[reconos-toolchain | reconos.scripts.hw.export] INFO: Export hardware to
directory '/home/meise/git/reconos_develop_fresh/demos/sort_demo/build.hw'
[reconos-toolchain | reconos.scripts.hw.export] INFO: Generating export files ...
[reconos-toolchain | reconos.scripts.hw.export] INFO: Generating threads ...
[reconos-toolchain | reconos.scripts.hw.export] INFO: Exporting thread
SortDemo to directory
'/home/meise/git/reconos_develop_fresh/demos/sort_demo/build.hw/pcores'
[reconos-toolchain | reconos.scripts.hw.export] INFO: Generating temporary HLS
project in /tmp/tmpyd2hbur5 ...
[reconos-toolchain | reconos.scripts.hw.export] INFO: Starting Vivado HLS ...
================================================================
Vivado(TM) HLS - High-Level Synthesis from C, C++ and SystemC
Version 2016.2
Build 1577090 on Thu Jun 02 16:59:10 MDT 2016
Copyright (C) 1986-2016 Xilinx, Inc. All Rights Reserved.
================================================================
INFO: [HLS 200-10] Running
'/opt/Xilinx/Vivado_HLS/2016.2/bin/unwrapped/lnx64.o/vivado_hls'
INFO: [HLS 200-10] For user 'meise' on host 'pc-techinf-28' (Linux_x86_64
version 4.4.0-45-generic) on Mon Nov 07 18:17:21 CET 2016
INFO: [HLS 200-10] On os Ubuntu 16.04.1 LTS
INFO: [HLS 200-10] In directory '/tmp/tmpyd2hbur5'
INFO: [HLS 200-10] Creating and opening project '/tmp/tmpyd2hbur5/hls'.
INFO: [HLS 200-10] Adding design file 'reconos_calls.h' to the project
INFO: [HLS 200-10] Adding design file 'reconos_thread.h' to the project
INFO: [HLS 200-10] Adding design file 'sortdemo.cpp' to the project
INFO: [HLS 200-10] Creating and opening solution '/tmp/tmpyd2hbur5/hls/sol'.
INFO: [HLS 200-10] Setting target device to 'xc7z020clg484-1'
INFO: [SYN 201-201] Setting up clock 'default' with a period of 10ns.
INFO: [HLS 200-10] Analyzing design file 'sortdemo.cpp' ...
CRITICAL WARNING: [HLS 200-70] Compilation errors found:
In file included from sortdemo.cpp:2:
./reconos_thread.h:21:1: error: expected unqualified-id
<<reconos_preproc>>
^
./reconos_thread.h:37:9: error: macro names must be identifiers
#define <<NameLower>> 0x<<HexLocalId>>
^
sortdemo.cpp:44:26: error: use of undeclared identifier 'resources_address'
uint32 addr = MBOX_GET(resources_address);
^
./reconos_calls.h:216:27: note: expanded from macro 'MBOX_GET'
stream_write(osif_hw2sw, p_handle),\
^
sortdemo.cpp:47:3: error: use of undeclared identifier 'sort_bubble'
sort_bubble(ram);
^
sortdemo.cpp:50:12: error: use of undeclared identifier 'resources_acknowledge'
MBOX_PUT(resources_acknowledge, addr);
^
./reconos_calls.h:226:27: note: expanded from macro 'MBOX_PUT'
stream_write(osif_hw2sw, p_handle),\
^
5 errors generated.
Failed checking during preprocessing.
while executing
"source [lindex $::argv 1] "
("uplevel" body line 1)
invoked from within
"uplevel \#0 { source [lindex $::argv 1] } "

[reconos-toolchain | reconos.scripts.hw.export] INFO: Generating export files ...
meise@pc-techinf-28:~/git/reconos_develop_fresh/demos/sort_demo$




Christoph Rüthing

unread,
Nov 7, 2016, 4:53:52 PM11/7/16
to rec...@googlegroups.com
Hi Sebastian,

you are right that the files are not processed correctly by the RDK. The problem is, that you are calling rdk without the LANG environment variable set correctly to an UTF-8 encoding (e.g. en_US.utf-8). Leaving it empty causes python to open the files with plain ASCII encoding instead of UTF-8. This fails for some of the files using non-ASCII characters. Unfortunately, no errors are printed but the files are simply skipped during pre-processing.

Is there any reason for setting the LANG environment variable before calling rdk? I think you do not need to worry about it (on Linux I would suppose that it is already set to somrthing with UTF-8). I also tested it on my system and it also breaks with LANG="" but works fine without it.

Yours,
Christoph

Sebastian Meisner

unread,
Nov 8, 2016, 2:59:11 AM11/8/16
to rec...@googlegroups.com
Hi Christoph!

Thanks a lot! With LANG="de_DE.UTF-8" it works now. I've been setting the LANG
Variable, because i got another error when not setting it. After several
generations of ISE tools on my Ubuntu machine and several work arounds to get
everything working my environment seems to be messed up a bit...


Cheers,
Sebastian
Reply all
Reply to author
Forward
0 new messages