C Language Macros and C++ Templates: Applications of Two Metaprogramming Techniques in High-Performance Computing
Introduction In High-Performance Computing (HPC), template metaprogramming or macros are often seen, where functions are called through template parameters or macro parameters. The most notable examples are CUTLASS (which uses templates almost exclusively) and OpenBLAS (which uses macros in many places). In fact, both macros and templates are metaprogramming techniques that occur before the actual … Read more