Open kxxt opened 1 month ago
The search feature caches all the lines in string representation to make it memory-contiguous, which would double the memory usage. Ideally the regex should be able to work on chunks of str
s : https://github.com/rust-lang/regex/issues/425 . Maybe I should give https://github.com/pascalkuthe/regex-cursor a try
For now there's lots of clones involved in the code. We could use something like https://github.com/thomcc/arcstr to optimize the memory footprint.
The tui can already handle 100000 events with a very low idle cpu usage without hassle thanks to the complex multi-layer cache system I implemented. But the memory usage doesn't look nice to me (total ram 16GB).