On Fri, Sep 09, 2016 at 03:16:50PM +0200, Lluís Vilanova wrote: > > The various _DSTATE variables are still arbitrarily scattered in > > memory, as opposed to in a contiguous cache friendly array, which > > is one of the goals of Paolo's original change. > > > That said, I'm unclear on how much of the performance win from > > Paolo's change came from eliminating the struct field de-reference, > > vs having the contiguous array. I'm guessing most of the win is > > from the former, the latter only being important if we hit multiple > > related tracepoints on close succession. > > The latter can also be achieved by packing them all together in a single > section, but I don't know if that's acceptable within portable QEMU code. For > example: > > bool ___TRACE_EVENTNAME_DSTATE __attribute__((section("dstate_array")))
Acutally, it should be sufficient if we just generate all the dstate variables in one place in the .c file - the compiler isn't going to scatter a set of variables declared one after each other. Regards, Daniel -- |: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :| |: http://libvirt.org -o- http://virt-manager.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|