- Functions
- 1,445 views • 1 today
- 126 downloads • 0 today
6
This is a better vesion of Dominexis' Benchmark
This datapack is designed to test the efficiency of a function or command technique by running it recursively as many times as possible before the game starts to lag. It also supports a live comparison between multiple functions.
This datapack is designed for Java Edition 1.21.11. However, it is written so that it can be used in older versions as well. If you want to use it in versions 1.15-1.20.6, you can just rename the three "function" directories ("benchmark/function/", "benchmark/tags/function/", "minecraft/tags/function") to "functions". Check the game logs for additional errors. The rest applies.
Because this datapack requires that you edit a function to benchmark certain techniques, you must extract the folder from the .zip into a world. This folder is the datapack, not the .zip file. Do this before proceeding.
What's new AKA changelog:
Now you can automate your testing. Just edit the config file and go have a cup of tea, while the datapack collects all the needed data on its own. I have encountered several problems with Dominexis' datapack:
1) The benchmark runs only once. > Now you can set amount of runs you want.
2) Only one function can be run at a time. Not convenient to compare. > Now you can compare 2, 3 or even more functions.
3) First function runs are worse than the next ones. > Now the datapack calculates the measurement uncertainty. You can set a threshold and just wait for the fluctuations to average out.
This datapack is designed to test the efficiency of a function or command technique by running it recursively as many times as possible before the game starts to lag. It also supports a live comparison between multiple functions.
This datapack is designed for Java Edition 1.21.11. However, it is written so that it can be used in older versions as well. If you want to use it in versions 1.15-1.20.6, you can just rename the three "function" directories ("benchmark/function/", "benchmark/tags/function/", "minecraft/tags/function") to "functions". Check the game logs for additional errors. The rest applies.
Because this datapack requires that you edit a function to benchmark certain techniques, you must extract the folder from the .zip into a world. This folder is the datapack, not the .zip file. Do this before proceeding.
What's new AKA changelog:
Now you can automate your testing. Just edit the config file and go have a cup of tea, while the datapack collects all the needed data on its own. I have encountered several problems with Dominexis' datapack:
1) The benchmark runs only once. > Now you can set amount of runs you want.
2) Only one function can be run at a time. Not convenient to compare. > Now you can compare 2, 3 or even more functions.
3) First function runs are worse than the next ones. > Now the datapack calculates the measurement uncertainty. You can set a threshold and just wait for the fluctuations to average out.
| Credit | Dominexis |
| Compatibility | Minecraft 1.15 |
| to | Minecraft 1.21 |
| Tags |
3 Update Logs
v2.2.0 : by Kragast 12/04/2025 6:31:14 pmDecember 4, 2025 @ 11:31 pm UTC
- changed integration time from 41 ms to 40 ms (I think I've messed this up earlier and hope I got it right now)
- added up to 1.21.11 support (gamerules and stopwatch) via overlays
- added check for wrong CALCULATE_EVERY_CYCLE value
- added up to 1.21.11 support (gamerules and stopwatch) via overlays
- added check for wrong CALCULATE_EVERY_CYCLE value
LOAD MORE LOGS
6443027
119




Have something to say?
Very awesome! Good job! :)
How did you even do that?
The same can be done in reverse. If I loop a function in sub-ticks and track the time elapsed, I can stop after, for example, 40 ms and know how many times the function has been executed.