Re: [PATCH v2] perf ordered_events: Optimise event object reuse

2020-05-28 Thread Matt Fleming
On Wed, 27 May, at 12:25:33PM, Jiri Olsa wrote: > On Tue, May 26, 2020 at 02:59:28PM +0100, Matt Fleming wrote: > > +/* > > + * Allocate a new event object from the free event cache. > > + * > > + * Find the first address range in the cache and carve out enough bytes > > + * for an ordered_event

Re: [PATCH v2] perf ordered_events: Optimise event object reuse

2020-05-27 Thread Jiri Olsa
On Tue, May 26, 2020 at 02:59:28PM +0100, Matt Fleming wrote: SNIP > + > +/* > + * Allocate a new event object from the free event cache. > + * > + * Find the first address range in the cache and carve out enough bytes > + * for an ordered_event objects. The object with the lowest address is > +

Re: [PATCH v2] perf ordered_events: Optimise event object reuse

2020-05-26 Thread Arnaldo Carvalho de Melo
Adding a few more folks that worked on the ordering of events over the years. Some minor nits at the end of the message. Thanks! - Arnaldo Em Tue, May 26, 2020 at 02:59:28PM +0100, Matt Fleming escreveu: > ordered_event objects can be placed on the free event list in any order > which means

[PATCH v2] perf ordered_events: Optimise event object reuse

2020-05-26 Thread Matt Fleming
ordered_event objects can be placed on the free event list in any order which means future allocations may not return objects at sequential locations in memory. Getting non-contiguous objects from the free list has bad consequences when later iterating over those objects in