skip to content

Game Engine Architecture

The machinery under every engine: the game loop and timestep, ECS and data-oriented layout, job systems, allocators and asset cooking. Senior interviews open here whichever engine you shipped on.

on this pageshow

explore

questions

page 2 of 2

In an engine's job system, why does a job that must wait on other jobs mid-run push teams toward fibers, and what do fibers cost?

level: seniorimportance: should knowfreq 40%

basics

~20 s

A job that waits on other jobs blocks its worker, idling a core or deadlocking the pool. Fibers park the waiting job's stack so the worker runs other jobs and any worker resumes it later, costing a stack per fiber and thread-local pitfalls.

open as a page

How do archetype storage and sparse-set storage differ in an ECS, and which suits a status that is added and removed every few frames?

level: seniorimportance: should knowfreq 55%

basics

~20 s

Archetype storage keeps entities with identical component sets in shared tables: dense multi-component iteration, but adding a component copies the whole entity. Sparse sets store each type separately: constant-time add and remove, indirect joins. A frequently toggled status suits sparse sets.

open as a page

After a long hitch, a fixed-step game loop falls further behind every frame and never recovers; what is this spiral of death and how do you prevent it?

level: seniorimportance: should knowfreq 52%

basics

~20 s

The spiral of death is a fixed-step loop whose catch-up steps cost more real time than they simulate, so each frame owes more steps. Clamping frame time, capping steps per frame and cheap steps prevent it.

open as a page

Designer scripts run a per-entity update that calls into the engine thousands of times a frame and blows the budget; what does each scripting boundary crossing cost, and how do you fix it?

level: seniorimportance: should knowfreq 38%

basics

~20 s

Each crossing between script and engine pays for lookup, argument conversion, type and handle checks and often a temporary allocation. Fix it by crossing less: event-driven scripts, batched coarse-grained calls, cached lookups and hot loops moved into native code.

open as a page

After a patch, players' save games fail to load or load with wrong values; how do you design an engine's saves so old files survive patches?

level: seniorimportance: should knowfreq 45%

basics

~20 s

Save games survive patches when they store tagged fields per object, a version per type, and stable persistent IDs instead of pointers, then run chained upgrade steps on load and test every shipped version's saves automatically.

open as a page

A console game hitches mid-match on general-purpose heap allocations and runs out of memory after several level loads, though each level fits alone; how do you diagnose and fix it?

level: seniorimportance: should knowfreq 50%

basics

~20 s

Treat both as lifetime bugs: track allocations per frame and move mid-match ones into pools, frame allocators or load-time reservations; snapshot memory at one quiet point after each level load, then give level data an arena freed at once.

open as a page

For gameplay queries such as all enemies within a radius in a large world, when do you choose a uniform grid, a quadtree or a loose octree?

level: seniorimportance: should knowfreq 50%

basics

~20 s

A uniform grid or spatial hash with cells sized to the usual query radius suits many moving objects spread fairly evenly; a quadtree adapts to very uneven density; a loose octree handles moving objects of very different sizes in full 3D without straddling.

open as a page

In an open world that streams cells around the player, why do cells near a border load and unload repeatedly, and how do you design streaming decisions to stop it?

level: seniorimportance: should knowfreq 45%

basics

~20 s

A single distance threshold flips a cell's state every time the player crosses it. Use hysteresis — load inside a smaller radius, unload only beyond a larger one — plus velocity-based prediction, a minimum residency time and a per-frame activation budget.

open as a page

A full content cook takes hours and blocks artists; what incremental-build and derived-data-cache strategy would you set for the team?

level: principalimportance: should knowfreq 32%

basics

~20 s

Treat each conversion as a deterministic function, key its output by a hash of source, settings, platform, converter version and dependencies, and share that cache, kept warm by a farm that cooks every submit, so incremental cooks fetch instead of recompute.

open as a page

When should a team adopt an ECS in an existing game built on inheritance-based objects, and how would you migrate it incrementally?

level: principalimportance: should knowfreq 35%

basics

~20 s

Adopt an ECS where profiling shows hot loops over many similar objects stalling on memory. In a shipped game, start with one hot subsystem as an ECS island, bridged to the object model by ids, and expand only on measured wins.

open as a page

How would you choose the fixed tick rate for a dedicated game server, and what does raising it cost the server, the network and the players' clients?

level: principalimportance: should knowfreq 38%

basics

~20 s

Choose the lowest fixed tick rate that the game's pace and precision need, measured against per-tick cost at peak load. Raising it multiplies server CPU and often bandwidth, shrinks the time each tick may take, and changes tuning that clients share.

open as a page

As the lead on a game shipping to several consoles, PC and dedicated servers, how do you set and enforce memory budgets per platform and per subsystem?

level: principalimportance: should knowfreq 38%

basics

~20 s

Budget from each platform's retail memory, split by category with named owners and a held-back reserve, and make it measurable: tag every allocation, record per-level peaks in automated runs, fail builds that exceed. Dedicated servers budget per match process.

open as a page

As a performance lead, how would you set and enforce frame and tick budgets across several target platforms and a dedicated game server?

level: principalimportance: should knowfreq 40%

basics

~20 s

Derive each platform's budget from its target rate, keep headroom, split it into per-system millisecond lines with owners, validate worst-case scenes on reference hardware, and enforce with automated runs that flag regressions above noise. Set the server's tick budget at peak load.

open as a page

What is a load-in-place asset layout, and how are its internal pointers fixed up after the file is read into memory?

level: seniorimportance: nice to knowfreq 35%

basics

~20 s

A load-in-place asset is cooked as a byte image of its runtime structures, so loading is one read into one allocation; internal pointers are stored as offsets and either patched to addresses through a fix-up table or kept as self-relative offsets.

open as a page

As engine lead, how do you decide whether designers get an embedded scripting language, which kind of language, or data-driven tools instead?

level: principalimportance: nice to knowfreq 32%

basics

~20 s

Decide by who writes gameplay logic and how fast they must iterate, then weigh run-time cost, platform limits on generated code, debugging tools, binding upkeep and sandboxing. Scripting earns its cost when designers own logic; otherwise tuning data may suffice.

open as a page

For a new open-world game, how would you choose between automatic grid-based world streaming and hand-authored streaming sublevels, and which rules would you set for the team?

level: principalimportance: nice to knowfreq 35%

basics

~20 s

Neither wins outright: a grid scales to large seamless worlds and lets many people edit at once, while authored sublevels group content by gameplay. Most large games mix both and set cell sizes, memory budgets, a top traversal speed and cross-cell reference rules.

open as a page

showing 31–46 of 46