cornell-zhang / hcl-dialect

HeteroCL-MLIR dialect for accelerator design
https://cornell-zhang.github.io/heterocl/index.html
Other
37 stars 15 forks source link

[Transforms] FoldBitWidth pass to fix cornell-zhang/allo#121 #213

Open matth2k opened 7 months ago

matth2k commented 7 months ago

I wrote this pass with cornell-zhang/allo#121 in mind. However, it still needs testing and to be integrated within the Allo compilation pipeline. It probably has some bugs still.

@chhzh123 any feedback? Where should this pass get called in Allo? Should we expose it to Python or just bundle the pass in with some other lowering step?

chhzh123 commented 7 months ago

Probably it would be better to make it an option for now. You can expose the pass to the Python frontend.

I can take a closer look once you provide some test cases or examples, but currently the pass looks good!