Re:High-order Virtual Machine (HVM): Massively parallel, opt...
by amelius on Sunday February 06, 2022 @01:15PM
(#30235228)
Ok. I'd be interested in the following benchmark: A program that reads in a large map of key-value pairs; it then reads in a list of keys, and produces a list of values (order of the output is not important). The map can be modeled by e.g. a red/black tree.
I'd be interested in the performance in Haskell, if it was implemented using a number of worker threads (each with their own reference to the map), versus the best implementation you can think of in HVM.
Re:High-order Virtual Machine (HVM): Massively parallel, opt...
by LightMachine on Sunday February 06, 2022 @02:12PM
(#30235845)
Looks good. I'll keep that in mind and let you know if we write such a benchmark. Opening an issue would be helpful to remind us!
Note that if the same expression was written in a deeper position of the normal form, it would be evaluated sequentially. This is what avoids the fine-grained parallelism issue. It also means that in many cases HVM will not be as parallel as it could, though! But when the parallelism kicks in, it is always productive.