RFR: Enhancements for Shenandoah's generational mode [v6]
William Kemper
wkemper at openjdk.org
Thu Mar 30 22:12:46 UTC 2023
On Thu, 30 Mar 2023 10:21:55 GMT, Aleksey Shipilev <shade at openjdk.org> wrote:
>> William Kemper has updated the pull request incrementally with 51 additional commits since the last revision:
>>
>> - Fix comment formatting
>> - Update copyrights
>> - WIP: Fix issues for live mode
>> - WIP: Use a fixed size buffer for events
>> - Show initial logFile argument in toolbar
>> - Do not load log files on event loop thread
>> - Factor visualizer frame setup out of main function
>> - Fix weird 3-space indentation
>> - Layout improvements
>> - WIP: Fix warnings
>> - ... and 41 more: https://git.openjdk.org/shenandoah-visualizer/compare/dadfaff6...06abcd90
>
> src/main/java/org/openjdk/shenandoah/CircularBuffer.java line 79:
>
>> 77:
>> 78: public int size() {
>> 79: return Math.min(count, elements.length);
>
> Why not just `return count`?
The code uses `count` to detect when the write index has wrapped (count itself does not wrap). This is mostly to support counted loop iteration.
-------------
PR Review Comment: https://git.openjdk.org/shenandoah-visualizer/pull/1#discussion_r1153837878
More information about the shenandoah-dev
mailing list