Skip to content
  • Kai Willadsen's avatar
    Cache inline-diff results to avoid rediffing blocks (closes bgo#168139) · 40b26c55
    Kai Willadsen authored
    Calculation of inline diffs is one of the most expensive things we do,
    but most changes to the diffed text result in very few changed blocks.
    This patch adds a simple caching mechanism to avoid constantly rediffing
    unchanged blocks. Currently, blocks are evicted from the cache on a LRU
    basis, which isn't perfect but works reasonably well.
    
    In combination with the previous patch, this closes bgo#168139.
    40b26c55