<div dir="auto">I was involved in some work about five years ago where I had to keep a small number of files (about 5) open all the time for examination as needed. Each was 100-500 GB.<div dir="auto"><br></div><div dir="auto">I opened them all in vim instances running in the background at login time, and then I read email until they were all loaded. I then put the process with the file I needed into the foreground, examined it, and returned to the shell with :stop (which all command line editors should have) when I was done. Worked like a charm.</div></div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">On Fri, Jul 18, 2025, 7:46 PM Larry McVoy <<a href="mailto:lm@mcvoy.com">lm@mcvoy.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On Fri, Jul 18, 2025 at 06:57:03PM -0400, Jeff Johnson wrote:<br>
> Actually, Xvi is now maintained at <a href="https://codeberg.org/martinwguy/xvi" rel="noreferrer noreferrer" target="_blank">https://codeberg.org/martinwguy/xvi</a>.<br>
> <br>
> I'll bow out of the editor discussion now, since I think we're pretty<br>
> far from the original topic.<br>
<br>
I can pull it back to something potentially useful. As I mentioned, years<br>
and years ago, on small memory machines, I used to vi $BIG_ASS_LOGFILE<br>
and because editors tend to malloc each line, the vi session got really<br>
slow (started swapping) when the file was bigger than roughly 1/2 of mem.<br>
My changes were to teach the string library, and whatever else operated<br>
on a line of the file, to treat \n the same way you would treat \0.<br>
Then you change the code that read in the file to just mmap() it.<br>
<br>
I don't think I went so far as to make changes to the file work, not<br>
sure, it may have just worked but I was looking at log files, I don't<br>
think I modified them.<br>
<br>
I'm pretty sure the answer is no, the laptop I'm typing on has 64GB and<br>
I suspect everyone else is the same. But can anyone imagine a use case<br>
where having a vi that could read really large files (and quickly, no<br>
parsing/mallocing each line) would be useful?<br>
<br>
I'm pretty done with programming but if someone said "here is an important<br>
use case where that would help" I'd go find those changes and see if I can<br>
port them forward. <br>
-- <br>
---<br>
Larry McVoy Retired to fishing <a href="http://www.mcvoy.com/lm/boat" rel="noreferrer noreferrer" target="_blank">http://www.mcvoy.com/lm/boat</a><br>
</blockquote></div>