[foreign-memaccess] Integrated: Unsafe ParallelSum test is broken
Maurizio Cimadamore
mcimadamore at openjdk.java.net
Mon Aug 24 11:04:50 UTC 2020
On Mon, 24 Aug 2020 10:50:14 GMT, Jorn Vernee <jvernee at openjdk.org> wrote:
>> The numbers for the unsafe parallel sum tests are artificially low; after some debugging I realized that the test was
>> not summing up all components. I then plugged in the unsafe fork join action into our existing memory segment
>> spliterator test, and verified that indeed that fork join action was violating all assertions.
>> I then fixed all the issues, verified that assertions were satisfied and then plugged the fixed action back into the
>> microbenchmark.
>> Unsurprisingly, the perf numbers of the unsafe part are now in sync with those obtained from the segment counterpart.
>
> test/micro/org/openjdk/bench/jdk/incubator/foreign/ParallelSum.java line 217:
>
>> 216: SumUnsafe s1 = new SumUnsafe(address, start, lobound);
>> 217: SumUnsafe s2 = new SumUnsafe(address, start + lobound, hibound);
>> 218: s1.fork();
>
> Judging by this code the third parameter is no longer a length, but an upper bound? Maybe you also want to change the
> field name in that case.
Uhm - it's still the length (in elements) associated with the task. I'll leave the field name as is.
-------------
PR: https://git.openjdk.java.net/panama-foreign/pull/288
More information about the panama-dev
mailing list