From: Nick Bowler Date: Thu, 12 Jan 2023 05:51:41 +0000 (-0500) Subject: Performance improvements for runtime icon generation. X-Git-Url: http://git.draconx.ca/gitweb/rrace.git/commitdiff_plain/2345a9dba343693668ece5abbba1fe58e0e18ed8?hp=2345a9dba343693668ece5abbba1fe58e0e18ed8 Performance improvements for runtime icon generation. As most of the rows for any given icon tile are the same as the previously-generated row, it is not necessary to recompute the colour values every single time. The code can be adjusted to re-use the previously-computed row instead. Since the generic code now works on bytes, we can also replace the open-coded loops in the row generation with a couple of memset calls, which should help modern compilers produce more efficient output. All this reduces the amount of computation done by the generic code substantially, to roughly a quarter of what it was previously. Also take the time to remove some unneeded complexity in the EWMH formatting implementation, which further helps a little bit on the code size front. ---