RFR: 8277865: G1: Change integer division to floating point division
Leo Korinth
lkorinth at openjdk.java.net
Fri Nov 26 14:43:28 UTC 2021
In the class G1PreConcurrentStartTask::NoteStartOfMarkTask the method `worker_cost` returns a cost of type double, unfortunately the return value is calculated using an integer division:
`return _claimer.n_regions() / regions_per_thread;`
-------------
Commit messages:
- 8277865: G1: Change integer division to floating point division
Changes: https://git.openjdk.java.net/jdk/pull/6577/files
Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=6577&range=00
Issue: https://bugs.openjdk.java.net/browse/JDK-8277865
Stats: 1 line in 1 file changed: 0 ins; 0 del; 1 mod
Patch: https://git.openjdk.java.net/jdk/pull/6577.diff
Fetch: git fetch https://git.openjdk.java.net/jdk pull/6577/head:pull/6577
PR: https://git.openjdk.java.net/jdk/pull/6577
More information about the hotspot-gc-dev
mailing list