AsyncExtract

Parallel entity extraction that speeds up huge mob farms and arenas.

Entity Dose-Response Sweep: 536 -> 885 -> 1,583 Entities (n=3/dose)

AsyncExtract moves part of the client's per-frame entity extraction onto a dedicated worker thread, but only when a scene is dense enough to benefit. Everywhere else it stays out of the way. It is an independent project and is not affiliated with any other optimization mod.

Why AsyncExtract?

  • Safe by design: entities are split by EntityType, so two threads never share an EntityRenderer. Any renderer exception triggers an automatic synchronous fallback.
  • Zero cost when idle: an adaptive gate stays on vanilla inline extraction until about 950 client entities, or until inline extraction is consistently slow (above 3,000 µs).
  • Measured, not promised: at 1,583 entities the extract() phase dropped from 3,428 µs to 3,048 µs (−11.1%) with 0 fallbacks across 5,400 parallel frames.

Quick Start

  1. Install Fabric Loader 0.20.0 or newer, with Java 25.
  2. Download the JAR from Modrinth.
  3. Drop it into your mods folder and launch Minecraft 26.3 or 26.4.

There are no keybinds or commands. The mod works automatically and is client-side only. Fabric API is not declared as a dependency.

How It Works

MechanismBehavior
PartitioningLevelExtractor.extractVisibleEntities is split by EntityType.
WorkerA dedicated daemon thread, AsyncExtract-Worker. It spins briefly, then parks when idle.
PipeliningThe render thread extracts its own entity types, block entities, weather, sky, world border and particles. It joins at the end of LevelExtractor.extract().
GateTurns offload on at ≥ 950 entities, or at an inline EMA above 3,000 µs over 16+ frames. It turns off when worker time falls below 850 µs EMA.
SafetyA renderer exception falls back to synchronous extraction.

Realistic Expectations

  • Helps with: large mob farms, animal pens, arenas, and heavy custom entity renderers (above about 3 ms inline). Gains start at roughly 950–1,000+ vanilla entities and grow with entity count.
  • Does not help with: normal gameplay, which stays inline at about 0% overhead, or GPU-bound frames. Saving 380 µs on a 25.4 ms frame is a mechanical FPS ceiling of only about 1.5% at 1,583 entities.

Benchmarks

Minecraft 26.3, Ryzen 5 4500 (6C/12T), RTX 3050. Deterministic NoAI forced-offload sweep, n = 3 alternating pairs per row.

Client entitiesBaseline extract()AsyncExtract extract()Wall deltaAvg FPS delta
5361,787 ± 50 µs1,783 ± 100 µs−0.2%−0.1% (p=0.97)
8852,440 ± 135 µs2,485 ± 134 µs+1.8%−2.0% (p=0.51)
1,5833,428 ± 212 µs3,048 ± 49 µs−11.1%+3.1% (p=0.20)
  • Linear interpolation puts break-even near 950 entities. At 1,583 entities the worker offloaded 1,487 ± 243 µs with a 500 ± 249 µs join wait.
  • With the active gate at 536 entities, it stayed inline for 96.2% of frames: 2,491 ± 103 µs baseline against 2,469 ± 129 µs gated (−0.9%).
  • Stability check on a 150-mod stack (n = 5, about 350 entities, EMF/ETF + Sodium + Iris): 0 crashes, 0 fallbacks, 49.2 ± 4.1 vs 49.5 ± 3.6 FPS (not significant). Singleplayer MSPT was too noisy to draw conclusions.
  • The FPS deltas are not statistically significant at n = 3.

Configuration

There is no config file. Tune the gate with JVM arguments:

PropertyDefaultMeaning
-Dasyncextract.entityThreshold950Entity count that enables offload
-Dasyncextract.onInlineUs3000Inline EMA (µs) that enables offload
-Dasyncextract.offWorkerUs850Worker EMA (µs) that disables offload
-Dasyncextract.beThreshold128Adaptive block-entity threshold
-Dasyncextract.disabledfalseTurns the mod off

Showcase

Mob Farms & High-Density Scenes: Dose-Response FPS & Active EMA Gate

Mob Farms & High-Density Scenes: Dose-Response FPS & Active EMA Gate

-380 us saved on 25 ms frame (~1.5% mechanical FPS ceiling at 1,583 mobs); active EMA+count gate verified -0.9% (~0% overhead, 96.2% inline) at 536 mobs.

Compatibility

MinecraftLoaderJavaSide
26.3, 26.4 (snapshots, pre-releases, RC and release)Fabric Loader ≥ 0.20.025+Client only

Forge and NeoForge are not supported. A 150-mod stack with EMF/ETF, Sodium and Iris ran without crashes or fallbacks (see Benchmarks).

Building from Source

Requires JDK 25.

./gradlew build --no-daemon

License

MIT. See LICENSE. Source and issues: GitLab.

AsyncExtract Team

profile avatar
  • 1
    Followers
  • 8
    Projects
  • 444
    Downloads

More from AltRossellView all