What game engines know about data that databases forgot
nockawa.github.io
nockawa.github.io
- "It’s not an accident — it’s driven by the same physics." The classic "it's not x, it's y", with an em-dash thrown in for good measure
- "Typhon brings these into the component storage model — not as bolted-on workarounds, but as first-class citizens." More "not x, but y", this time with a leading clause joined by an emdash
- "Blittable, unmanaged, fixed-size, stored contiguously per type — that’s the ECS side." Short, punchy list of examples, emdash'd to a stinger, again typical of LLM writing
- "Schema in code, not SQL. Components are C# structs with attributes, not DDL statements. Natural for game developers, unfamiliar territory for database administrators. If your team thinks in SQL, this is a paradigm shift." This whole mini-paragraph is the x/y style, combined with the triplet / rule-of-three, just at the sentence scale. And then of course, the stinger at the end.
Definitive, no, but it certainly has a particular flavor that reads as LLM output to me.
At some point this is not positive for the community.
"Hi there, I am Loïc Baumann, I’m from Paris area, France I develop, since early 90s, first assembly, then C++ and nowadays mostly .net.
My area of interest are 3D programming, low-latency/highly-scalable/performant solutions and many other things."
Compare that style to what's in this most recent blog - mildly ungrammatical constructions typical of an ESL writer, straightforward and plain style vs breathless, feed-optimized "not x, but y", triplet/rule of three constructions, perfect native speaker grammar but an oddly hollow tone. Or look at this post from 2018: https://nockawa.github.io/microservice-or-not-microservice/ It's just radically different (at a concrete syntactic level, no emdashes). I'm sure he has technical chops and it's cool that he worked on DOTS, but I would bet a very large amount of money he wrote the bullet points describing this project and then prompted GPT 5.3 to expand them to a blog post to "save time".
It is far more likely that AI-written articles will become harder to spot, not that they will stop being written.
Calling what out? Did we suddenly invent a durable Turing test that will last more than six months? (We didn't, but some people "just know")
The only durable metric is if the article is good, if the ideas are good. Everything else is complaining about Bob Dylan's electric guitar.
I posted this elsewhere, but convincingly, consistently "writing like AI" and never slipping once takes an amount of knowledge and skill analogous to art forgery. Except that with art forgery you can at least make millions of dollars off it.
If you want to read chatbot output, why are you coming here? There's a ton of free chatbots for you to read.
After all, the audience here knows where to go to get chatbot output, but they're coming here instead. What does that tell you?
That HN was a neat community fifteen years ago, but like all things cool made by early adopters, it will eventually attract a following hoping to be somewhere, to exist among people doing things, but the tragedy of such followings is that they bring with them their toxicity, their immunity to their own poison, and drown out what they depend on until the early adopters early adopt away.
The real slop is all this lazy concern farming from an ant mill that is powerless to do anything except validate its own hand wringing.
Which circles back to the question of why, if you want to read AI output, are you still here?
You can read that sort of thing just about anywhere else.
> Zero-copy is the default, not the optimization:
the amount of fluffy mapping, destructuring, temp scope-creation, ... that is the norm now for JS/TS devs is excruciating. how did this become the norm? do it once it doesnt matter, but every single layer in the app doing this and things become jittery. you first take the hit at creation time, and then another time at GC. stop doing that! Pass references around to objects, not recreate them each time at some function boundary.
> Entity as pure identity.
Stop json.stringifiyng every thing! how many hashThing() implementations i have seen that are essentially Json.stringify. stop it!
> Cache locality by default.
a little less clear for web dev, much is missing in terms of primitives. but do think about it. if anything, it's good hygiene. fixed typed array does make sense, dont mix&match types in your array, ...
Save the web, think like a videogame dev!
Isn’t it funny, btw, how "performance" can also meant "acting out a fictional narrative"? Just a thought…
And then there's the more detailed version of that where people write {x: 0, y: 1} in one spot and {y: 1, x: 0} in another and do not seem to realize that this under the hood they just sabotaged the ability of every JS engine out there to fully optimize any code related to it. Which also extends to situations where functions take objects that happen to share some properties as parameters: if you can put the shared properties first and in the same order in the object creation, it will result in better optimized functions.
(but tbh I think that as long as we don't fix the bloat that is tracking libraries first, all of this is optimizing the wrong thing)
Non-primitives are always pass-by-reference. There's no mechanism to pass a non-primitive by value except edge-cases like giving ownership of a buffer to another process.
> destructuring
What about it? What backs the assumption that destructuring is inherently worse than dot and/or bracket syntax? Is there a behavior you think is unique to destructuring? Or maybe a specific report from one engine years ago?
it's a good thing. pass objects by reference.
> Is there a behavior you think is unique to destructuring?
depending on exact syntax, will collect values in another array or object. it's often used as the mirror-pattern of using named variables, which allocates an object for each function call.
in isolation these are not inherently wrong, at scale they start to add up. and should not be used in tight loops.
It’s not an option. That’s how JS must behave.
> depending on exact syntax, will collect values in another array or object
Not in JS. Maybe you are referring to rest syntax? That is not specific to destructuring i.e. functions accept rest parameters.
> which allocates an object for each function call.
No, in JS non-primitives MUST be pass by reference.
Pass objects by ref, I said that to underscore its better than create new objects. I get it, its the only way, but theyre still passed by ref.
Yes, [a,b,...rest] =... is restructuring and creates new object.
Named params create new objects, it's better to pass args individually, the ref creation under the hood is not comparibly impactful.
Not one mention of column stores? This didn't come from ECS...
In my mind, there's a pedagogical gap in OOP where ontologies are formed using classes and this almost never works in real life applications (no in real life for that matter). We almost always construct ontological relations using predicates not rigid hierarchies. For this, ECS tends to be flexible, and expressive enough to be a pragmatic choice.
1. https://www.gamedevs.org/uploads/data-driven-game-object-sys...
The main one is subrow versioning. Column stores (in OLAP at least) have always used row-level versioning, which gets in the way of small updates. A single change to a row amplifies into deleting and re-inserting the whole thing, and operations that seem sensible like adding or dropping a column break previous versions. This scheme is the first I've seen that tries to fix that problem.
One other difference is a lack of compression, as it's zero-copy, so the performance gains of operating on compressed data are lost.
[1] https://db.cs.cmu.edu/events/pg-vs-world-spacetimedb-tyler-c...
Traditionally called something like entity and attachments.
ECS is to me still conceptually cleaner and easier to work with, if more tedious and boilerplate-y.
It's too bad that ECS isn't more widely known outside of gamedev. It's not just good for performance, it's also legitimately a useful architecture design on its own to solve problems.
If you take a BDD/TDD approach - do technologies like this still give you something?
I've dabbled a bit into smth similar (SpacetimeDB) with the aim of creating a headless backend for a game.
But then I realized that I'd still need to define the interface that I was testing in the traditional software layer and that all the nice DB magic seemed worthless since I'd still have to orchestrate traditionally.
(In short: No matter how nice your DB magic is, you will still hide it away in the basement/engine room, right?)
This is my aim https://tablam.org.
BTW I worked in SpacetimeDB and I proudly say is half-way :)
While it's nice to get yourself acquainted with all, especially easy to do with AI these days.. I do have to point out few things visible outside of myopia induced when looking from one perspective into another. In this case from gamedev to data world. In Cliff's notes since I don't have much time but I also don't want to give a drive-by snark since there are hidden values to this, imo, contrary to what I'm going to say.
What gamedev perspective myopia kind of ignores is, in no particular order..
persistence vs throughput - goal of data management is not only about execution speed. ACID, WAL, etc all are core features, not an overhead per se. Sometimes you can forego these, of course. Sometimes, if you understand what you're giving way to.
columnar fallacy, for the lack of better words - DoD, SoA are not secrets game engines use which others have forgotten. This in-particular ignores existence of OLAP. Clickhouse, Snowflake, HN's darling duckDB have been using SoA for _quite awhile_. AoS in OLTP is used because updating a single record _is_ faster that way. Why one over the other - see OLAP vs OLTP
Game engines obsess over cache hierarchy (L1-L3), and in particular cache misses by avoiding those with cache line packing, prefetching. Databases operate in a different real, that of I/O boundaries; Disk and network primarily. Bottleneck of databases is often the speed of light (latency) or the bus (NVME for example). packing structs is going to give you marginal benefit if you're waiting for 10ms for a network packet or a disk read. Suggested are micro optimizations in the context of a global system. Different realms of execution flows.
ECS are cool, everyone agrees on that. Relational databases are built on top of relational algebra though. So if you're up for running the same logic over many objects, ECS is going to be cool. If you want to allow for complex, arbitrary queries and set based logic you will need some guarantees of consistency. Complex, many-to-many joins across disparate ECS ssystems without predefined _system_ and you're foregoing the promised performance. What DBs are doing is general purpose, ECS ain't that.
Finally, yes game engines manage thousands, millions, of entities in localized 3D space. Databases manage billions, trillions, of records across petabytes of distributed storage. So, what gives? Entity model does not scale to distributed systems because of CAP theorem. No such thing as instant consistency in a globally distributed system without violating physics or sacrificing availability. TBH, some middle ground, localized to a machine, might give way to the idea but at what cost?
Don't let it shoot you down though. If there is still a kernel of idea tingling after that chat with AI, go ahead and drive through that CAP wall!
Not entirely forgotten in the database world!
That smells a bit like a transaction to me.