[Rev 02] RFR: 6674: Optimize finding of first start time and first & last end times
hirt at openjdk.java.net
Mon Jan 20 21:37:10 UTC 2020
On Mon, 20 Jan 2020 21:37:09 GMT, Henrik Dafgård <hdafgard at openjdk.org> wrote:
>> This optimization relies on the fact that event lanes are sorted by timestamp. This allows us to skip performing very costly comparisons when finding the first start time or first/last end times of an IItemCollection and instead just get the first or last events in each lane and find the event in that set that was earliest or last, respectively.
>> This PR also removes the associated aggregators to strongly encourage downstream users to make use of the added RulesToolkit methods.
> The pull request has been updated with 1 additional commit.
core/org.openjdk.jmc.flightrecorder.rules/src/main/java/org/openjdk/jmc/flightrecorder/rules/util/RulesToolkit.java line 1432:
> 1431: * Returns the latest end time in the provided item collection. This method is based on the
> 1432: * assumption that item collection lanes are sorted by timestamp.
> 1433: *
...and that they are not overlapping.
More information about the jmc-dev