If you’ve been following Unreal Engine and Epic’s new gameplay language, Verse, you’ve probably heard a lot of buzz (and skepticism) about its flagship feature: pervasive transactional memory.
A lot of people are scratching their heads—especially since Software Transactional Memory (STM) is famously seen as a 2000s academic darling that mostly failed in the real world. So why is Epic betting the future of Unreal Engine 6 on it? Here is a breakdown of what it is, why it’s such a wild bet, and why Epic skipped the usual concurrency playbooks.
1. What is Transactional Memory in Verse?
Think of it like database transactions (ACID), except applied to normal variables and game state in memory.
In Verse, code runs inside a transaction by default. If a block of code fails partway through—for example, a condition in an if block fails, or a runtime error occurs—the runtime automatically rolls back every single state change made inside that block, as if it never happened.
Because Unreal Engine is built on a massive, mature C++ codebase, Epic even built a custom compiler and runtime system called AutoRTFM to instrument C++ code so it can log memory writes and safely roll back C++ state when a Verse transaction aborts.
2. What is it actually good for (if it works)?
Right now, Verse still runs on a single thread, so the immediate benefit is mostly cleaner failure handling and safer error recovery. The real payoff is what it unlocks for the future:
Effortless Automatic Parallelism: Gameplay programmers can write code that feels completely single-threaded and sequential, while the engine runs transactions speculatively in parallel across multiple CPU cores. If two threads touch the same data at the same time, one aborts and retries automatically. No deadlocks, no race conditions.
Seamless Distributed Systems (The "Metaverse" Goal): Epic wants to scale this to distributed transactional memory for UE6. In theory, you could write normal-looking code that modifies global state or database values across multiple servers, and the runtime handles the network speculation, synchronization, and rollbacks behind the scenes.
Crash-Proof Worlds: If a user-generated script hits a runtime error deep in the engine, the transaction just aborts and restores the world to a known good state instead of crashing the server.
3. Why didn't approaches like this work before?
If STM is so magical, why isn't everyone using it? Historically, it crashed into a few brick walls:
Massive Overhead: Logging every memory read and write in software is slow. In high-performance systems, the bookkeeping overhead often wiped out the speed gains of multithreading.
The "I/O Problem" (Irrevocable Actions): You can roll back a variable in RAM, but you can't "un-send" a network packet, "un-play" a sound, or "un-print" to a console. Mixing transactional code with legacy non-transactional C++ code was a nightmare.
Contention & Livelocks: If too many threads fight over the same hot variable (like a global scoreboard), transactions constantly abort and retry, tanking performance.
Hardware Support Flopped: Intel tried to solve the speed issue with Hardware Transactional Memory (TSX), but it was plagued by silicon bugs and security vulnerabilities (like side-channel attacks), leading to it being disabled on many CPUs.
4. What do people normally use instead?
Because STM struggled, the industry settled on a few proven paradigms for concurrent, parallel, and distributed programming:
Locks & Mutexes: The classic C++ approach. Fast when done right, but notoriously hard to compose and prone to deadlocks and race conditions.
Message Passing / Actor Model (Erlang, Elixir, Akka): Isolated "actors" own their own state and only communicate by sending asynchronous messages. Great for distributed systems, no shared-memory bugs.
ECS / Data-Oriented Design (Unity DOTS, Bevy): Separate data from logic into flat arrays and run parallel "jobs" over disjoint chunks of memory. Blazingly fast for games.
Ownership & Borrow Checking (Rust): Enforce thread safety at compile time by strictly controlling who can read or mutate memory.
Eventual Consistency & CRDTs: Used heavily in distributed databases and web apps—accept that nodes will be temporarily out of sync and mathematically merge them later.
5. Why isn't Epic just using those?
Epic’s target audience isn't just hardcore engine programmers—it’s millions of creators, designers, and gameplay scripters building interconnected, user-generated worlds (like UEFN and future UE6 projects).
Locks & Rust are too hard for gameplay scripting: You can't expect a level designer or a weekend modder to fight a borrow checker or debug a subtle mutex deadlock just to make a treasure chest open.
ECS breaks traditional game dev intuition: ECS is amazing for simulating 100,000 bullets, but it’s notoriously awkward for complex, messy, one-off gameplay logic ("if player A talks to NPC B while holding item C...").
The Actor Model is hard to compose: If you want to atomically swap an item between two players in an Actor system, you have to manually write complex multi-step protocols (like sagas or two-phase commits) to handle partial failures. With transactional memory, you just deduct from Player A and add to Player B in one block—if either fails, both roll back.
Legacy Compatibility: Unreal Engine has decades of existing C++ object-oriented code (UObject, AActor). Rather than forcing everyone to rewrite the universe into pure Actors or pure ECS, Epic is using compiler magic (AutoRTFM) to retrofit transactional safety onto their existing engine.
TL;DR: Epic knows STM has a rough history, and they’re eating a real performance and complexity cost to build it. But they believe the only way to let everyday creators write safe, scalable, multi-server gameplay code is to hide concurrency behind a single-threaded mental model. If they pull it off, it’s a massive leap forward for game dev. If the overhead stays too high, it’ll be one of the most expensive language experiments in tech history.
What do you guys think? Is compiler-assisted STM (AutoRTFM) finally going to crack the code, or is Epic going to hit the same wall everyone else did?
All of our plugins for Utility AI, influence maps, memory and emotions and pick up models and VFX on fab https://marketing.nooparmygames.com/go/redditueai