dimitriv / Ziria

A domain-specific-language and compiler for low-level bitstream processing.
92 stars 18 forks source link

Restructure Ziria C API for interfacing with MAC #32

Open bradunov opened 9 years ago

bradunov commented 9 years ago

Restructure various calls from Ziria generated code to make the API more clear. For example, wpl_global_init() initializes the heap using wpl_init_heap and generates LUTs. So if I want to run wpl_go() many times in a C loop, I need to do only one one global init but I need to run wpl_init_heap in each loop. This should be simplified and clarified.

Also, provide better return of parameters between MAC(C) and PHY(Ziria). For example, if Ziria code is a computer that returns a struct, this struct should be returned by wpl_go. Also, allow MAC to query Ziria's compile-time parameters, such as input/output types.