Re: gitk: avoid obscene memory consumption
- From
Jacob Keller <jacob.keller@gmail.com>
- Date
- Nov 6, 2016, 20:33 UTC
- Message-ID
- <CA+P7+xo6qTjf3R1WTjyRUAn0-2pyKXRpf=v_aMJGPXQg39SweA@mail.gmail.com>
- In-Reply-To
- <ff5bb36b-e30c-3998-100d-789b4b5e7249@jump-ing.de>
On Sun, Nov 6, 2016 at 2:28 AM, Markus Hitter <mah@jump-ing.de> wrote:
> - Storing only the actually viewed diff. It's an interactive tool, so there's no advantage in displaying the diff in 0.001 seconds over viewing it in 0.1 seconds. As far as I can see, Gitk currently stores every diff it gets a hold of forever. >
This seems like the right solution. Store only what we need to view as we need to view it. (IE: lazily generate the diff and don't keep it long term, possibly by generating each file separately when that file is viewed)?
> - View the diff sparsely. Like rendering only the actually visible portion. >
This also would be valuable, as part of the solution above.
> - Enhancing ctext. This reference diff has 28 million characters, so there should be a way to store this with color information in, let's say, 29 MB of memory. >
I think all three suggestions here are a better solution that what you've outlined already as you explain the problems caused by cutting off the diff.
Thanks, Jake