hocl icon indicating copy to clipboard operation
hocl copied to clipboard

[Preesm backend] configuration actors not recognized

Open jserot opened this issue 3 years ago • 2 comments

[Issue initially mentionned by ggauthie by PM]

Configuration actors -- i.e. actors having an output port with type t param are not handled correctly by the Preesm backend.

For example, this actor:

node selector
in ()
out (value: int param) actor
preesm(loop_fn="selector", incl_file="Code/include/selector.h", src_file="Code/src/selector.cpp")
end;

gives the following code in the generated .pi file:

<node id="selector_18" kind="actor" period="0">
  <data key="graph_desc">Code/include/selector.h</data>
  <loop name="selector">
    <param direction="OUT" isConfig="false" name="value" type="int"/>
  </loop>
  <port kind="output" name="value" expr="1" annotation=""/>
</node>

whereas it should give:

<node id="selector_17" kind="actor">
  <data key="graph_desc">Code/include/selector.h</data>
  <loop name="selector">
    <param direction="OUT" isConfig="true" name="value" type="int"/>
  </loop>
  <port annotation="NONE" kind="cfg_output" name="value"/>
</node>

Note the isConfig field set to true and the port kind set to cfg_output.

jserot avatar Aug 13 '21 14:08 jserot

Associated to this issue is another one : the output port of a configuration actor cannot be connected directly to a configuration input port of another actor. There must be a parameter node in between.

jserot avatar Oct 19 '21 09:10 jserot

Fixed in current source tree (will be in release 1.2.3)

jserot avatar Oct 19 '21 16:10 jserot