Function Compiler
by EpicPix
Function Compiler is a server-side Fabric and Quilt mod that compiles datapack functions into Java bytecode so they run faster than plain command execution.
What it does
When a server loads datapacks, the mod automatically compiles most functions into Java bytecode. The compiled code runs all of a function's commands in one pass rather than executing them one at a time, which is the source of the performance gain the author describes. Functions that contain only commands are the ones it can compile; the mod does not support other constructs.
Compilation respects the maxCommandChainLength gamerule, so a function that would exceed the chain limit is not compiled in a way that breaks it. Macros are handled only in part: some macro values are interpreted in ways that are hard to implement, so those cannot be compiled, and some values are known at compile time while others are guessed. The list of supported commands is in the Command Support file, and selectors are supported with their options. Players join without it, since only the server has to run the mod.
The mod is open source under the GNU Lesser General Public License v3.0 only. Its source code and issue tracker are public. Files are published for Fabric and Quilt across 13 release versions, 1.19.4 – 1.21.4, with 0.3.2-alpha.2+1.21.4 as the latest file for 1.21.4 on both loaders, released 2025-03-16 on the alpha channel.
Key features
Automatic function compilation
Most datapack functions are compiled to Java bytecode on the server without any per-function setup.
Single-pass execution
Compiled functions run their whole command sequence at once instead of issuing each command separately.
Macro support in part
Functions with macros are compiled where the values can be resolved, and the rest fall back to normal execution.
Compatibility
Latest build for each game version and loader.
1.21.x5 of 5 versions with builds
1.20.x7 of 7 versions with builds
1.19.x1 of 1 version with builds
Only full game releases are shown. This mod publishes no snapshot builds.
How it compares
Redstonecompiler is server-side only and runs on Fabric and Quilt, but its files cover only 1.20.1 and its license is Creative Commons Attribution Non Commercial Share Alike 4.0, so it is not open source. Material Rule Compiler is also server-side only and open source under the Mozilla Public License 2.0, but it targets 26.1 – 26.3 and does not overlap with Function Compiler's version range. Jasione is open source under the GNU Lesser General Public License v3.0 only and spans Fabric, Forge, NeoForge and Quilt for 1.18.2 – 26.3. Players and servers can run it on either side, and neither needs it.
| Mod | Loaders | Game versions | Environment | Updated |
|---|---|---|---|---|
| Function Compiler | Fabric and Quilt | 1.19.4 – 1.21.4 | Server-side only | 2025-03-16 |
| Redstonecompiler | Fabric and Quilt | 1.20.1 | Server-side only | 2026-06-09 |
| Material Rule Compiler | Fabric and Quilt | 26.1 – 26.3 | Server-side only | 2026-10-11 |
| Jasione | Fabric, Forge, NeoForge and Quilt | 1.18.2 – 26.3 | Client or server, optional | 2026-10-02 |
Questions
Does Function Compiler need to be installed on clients?
Which loaders does Function Compiler support?
Are all datapack functions compiled?
In the catalog
Function Compiler is one of 3,545 Optimization mods on ModsFinder, and one of 2,575 Optimization mods for Fabric. 17,979 mods support Minecraft 1.21.4.
More from EpicPix
Similar mods
What the author says
This mod allows the server to compile functions from datapacks on load to Java bytecode, which results in increased performance, because compiled code can run everything at once instead of running commands one by one. Some statistics are automatically collected when using this mod. Feel free to check the code to…
Official listing
- Modrinth page
- modrinth.com/mod/mcfc
- Owner
- EpicPix
- Published
- 2023-10-29
- Updated on Modrinth
- 2025-03-16
- Facts verified
- 2026-10-15
