First contact with Fibers
Alan.Bateman at oracle.com
Tue Aug 13 19:01:03 UTC 2019
On 13/08/2019 16:50, Christian Stein wrote:
> Using `-Xmx2G` the error didn't occur. The execution of the million
> fibers took about 223 seconds -- too much pressure for the virtual
> machine provided by GitHub/Azure Pipeline, methinks: 
Thanks confirming that increasing the heap size works around the OOME
handling issue. I don't think I can explain the 223 seconds. I tried it
on both Linux and macOS and it runs in about 5s, which is similar to
what you seeing on Windows.
$ java -Djdk.defaultScheduler.parallelism=4 -p lib:bin/main/modules -m
org.junit.platform.console --details SUMMARY --scan-modules --config
tests=1000000 --config thread=false
Test run finished after 5016 ms
[ 1 containers found ]
[ 0 containers skipped ]
[ 1 containers started ]
[ 0 containers aborted ]
[ 1 containers successful ]
[ 0 containers failed ]
[ 1000000 tests found ]
[ 0 tests skipped ]
[ 1000000 tests started ]
[ 0 tests aborted ]
[ 1000000 tests successful ]
[ 0 tests failed ]
> Did you take a quick glance at two implementations? Are they ... okay?
> Or am I missing something?
Looks okay, at least for experimentation but I wouldn't expect unit
tests to spend a lot of waiting/sleeping/blocked (some will but I would
guess that it's the minority).
More information about the loom-dev