mpicc test_module.c HyperCubeLib.c -o runmpirun -n 64 run- Inspired by CS525 at Purdue, here is the related slide.
- see it at the top of each function here
- see the MACROs here, and you could compare the complexities among different implementations.
-
definition:$S[i] = \sum_{k=0}^i sum[k] (\Pi_{l=k+1}^i mul[l])$ -
sequential handling:
for(int i = 1; i < n; i++)
S[i] = sum[i] + mul[i] * S[i - 1];- Which is built for Mamba, that Scan