Branch: refs/heads/main
Revision: 43d3191
Author: bradcray
Link: https://github.com/chapel-lang/chapel/pull/19180
Log Message:
Merge pull request #19180 from bradcray/pidigits-cobegin-sep-mults
Pidigits version using a cobegin
[reviewed / co-developed by @ronawho]
Elliot realized that the previous begin
-based version put two tasks on locale 0,
and we also discussed in the perf meeting that the three begin statements felt
a bit clunky. Both of those can be resolved with a cobegin
statement which is
what we do here.
Interesting variations on this version might include:
-
using a monitor/condition variable library abstraction to coordinate between the
tasks -
using a context manager pattern for the waitFor...write patterns in the task routines
-
using begins/futures to launch tasks for each subcomputation rather than setting
an existing task free (for an elegance::performance tradeoff)Modified Files:
M test/studies/shootout/pidigits/bradc/pidigits-blc.chplCompare: https://github.com/chapel-lang/chapel/compare/596bf2e08ccf...43d31917ae1c