EPFL-LAP / dynamatic

DHLS (Dynamic High-Level Synthesis) compiler based on MLIR
Other
65 stars 19 forks source link

[CfToHandshake] External function bug in CfToHandshake conversion #108

Closed Carmine50 closed 2 months ago

Carmine50 commented 3 months ago

After the last change in the file CfToHandshake, it is impossible to declare external functions. During the application of applyFullConversion, the pattern ConvertCalls is executed on the calls of external functions before transforming the external functions into handshake functions in the LowerFuncToHandshake pattern. During the ConvertCalls, there is a check to ensure that the call refers to a handshake function. This check fails. There are 2 possible solutions to this problem:

  1. The check is skipped in the ConvertCalls pattern
  2. The LowerFuncToHandshake pattern is executed with a partial conversion before executing all the other patterns