Hacker News new | ask | show | jobs
by fluffybucktsnek 62 days ago
I don't know where you are trying to go with this logic. You still haven't assured that the 50MB is actually related to data structures used behind by bevy, lest you are insunating that the data structures used by bevy are solely responsible for that size, which is not what the post claims.
2 comments

How small is a hello world in C on Linux? The last time I checked a few years ago, it was either 9Mb or 13Mb (memory is fuzzy on this one but one of them was right).

Edit: wow I’m way off… it must have been the 90s when I checked this lol

C statically linked hello world binaries have never been 9MB or 13MB, they definitely weren't in the 90s. Also these are rust binaries.

https://github.com/MichalStrehovsky/sizegame

Yeah, testing here with GCC 13.3.0 led to 16K. Perhaps, when you made your test, the compiler was statically linking some libs, which would explain the massive increase in size.
You should probably read the whole thread. You jumped in half way through and got all mixed up.
I know the thread. Your point is about whether Bevy's "data structure" is worth 50MB. I pressing on the fact that you haven't shown what this 50MB actually are.

But, out of curiosity, do you also consider the Linux Kernel also a data structure?

I pressing on the fact that you haven't shown what this 50MB actually are.

To be clear you think an ECS implementation is 50 MB?

But, out of curiosity, do you also consider the Linux Kernel also a data structure?

Do you think a spreadsheet the holds function pointers is a kernel?

> To be clear you think an ECS implementation is 50MB?

No.

> Do you think a spreadsheet the[sic] holds a function pointer is a kernel?

Do you think an entire engine, including its system scheduler, is a spreadsheet? If so, shouldn't be hard to apply the same argument to any kernel. Of course, it all relies on your definitions and sense of reductionism.

I think you're conflating other big features of a game engine with a way to store data. If you look at other ecs implementations they are data structures, they don't do "system scheduling" (is that different from regular scheduling?)
First of, Bevy isn't just an ECS implementation. It's a game engine designed around ECS. While the ECS part is its core, Bevy also provides rendering, resource management, physics, etc. One of its other tasks, a rather important one too, is system scheduling: once you register systems, Bevy is responsible for dispatching them each frame, at the appropriate time, while also avoid data races over global resources and components.
Other ECS implementations might not, but Bevy does come with a system scheduler. You register systems (functions that operate over the components) and, through their parameters, Bevy's scheduler decides how to parallelize the registered systems while avoid data races.