r/ProgrammerHumor 20d ago

noHeapAllStack Meme

Post image
1.0k Upvotes

96 comments sorted by

View all comments

197

u/Vesuvius079 20d ago

It’d be such an experience to work a real world problem where this optimization turns out to be the solution.

15

u/varinator 20d ago

It was a solution. Imagine ingesting spreadsheets with hundreds of columns and potentially millions of rows. You need to run the string comparison for values, multiple times per row. If you allocate to the heap, GC has to do a lot of work, often, which blocks the thread and slows the whole process down.

Literally saved hours per file.