Achieving High-Performance the Functional Way (2020)
dl.acm.org
dl.acm.org
Got this: [drm:amdgpu_cs_ioctl [amdgpu]] ERROR Failed to initialize parser -125!
Had to kill the XServer with CTRL+Alt+Backspace to get it back.
Coding to yield() on a framework which doesn't support tail recursion might (for example) loop to infinity.
Coding to immutability which cannot be guaranteed, means you may return false results.
https://devblogs.microsoft.com/dotnet/update-to-the-dotnet-l...
for HPC and ML, Python is dominant, I would expect to enhance python somehow with FP instead of anything else, then adding c/c++/rust/fortran libraries(e.g numpy) for intensive computing needs.
why python can't thread? impact of GIL on python https://pythonspeed.com/articles/python-gil/
Python is better used as a glue language and leverage numpy etc to do the heavy lifting, numpy can work with multiple-core just like c/c++/rust languages can.
If you really need launch multiple python processes, the multiprocessing module comes to rescue.
While not ideal, I don't see a showstopper to use Python for HPC's high and parallel computation needs at all.
x = 1 y = 2
q = list(map(lambda t: ( tx := tx, ty := ty, tx+ty )[-1], [1, 2, 3]))
print(q)
if i understand it, they then automatically analyze the iterator chain and rewrite some of it using parallel versions of the code, for example they change Map to MapPar
"In Rise, low-level implementation choices such as performing a computation in parallel are encoded with low-level patterns. For example, the map pattern that applies a function to each element of an array might be performed in a data-parallel fashion as indicated by the mapPar variant of the pattern"
https://arxiv.org/pdf/2002.02268.pdf
This reminds me a bit of how the Rayon crate in Rust works, where you can take an iter() and change it to par_iter() and instantly get parallelism in your program (depending on various details). but it seems like they have taken it "to the next level" and can output a CUDA program automatically , starting from their basic iterator chain.