cornell-zhang / heterocl

HeteroCL: A Multi-Paradigm Programming Infrastructure for Software-Defined Heterogeneous Computing
https://cornell-zhang.github.io/heterocl/
Apache License 2.0
326 stars 92 forks source link

[Refactor] Reference argument usage in C++ #328

Closed seanlatias closed 1 year ago

seanlatias commented 3 years ago

We should enforce ourselves to do the following (according to Google C++ style):

void (const A& a); //good
void (A* a); //good
void (A& a); //bad

This is also a common coding style (at least TVM is also requiring this). We should create a PR purely for cleaning up this usage. Tagging the current contributors.

@Hecmay @paldebjit @zzzDavid @Sibylau

seanlatias commented 3 years ago

This applies not only to function arguments but also class constructors.

chhzh123 commented 1 year ago

As we have released a new version of HeteroCL that entirely moves the compilation stack to MLIR, issues related to the original HalideIR flow will be closed.