Skip to content

Commit

Permalink
Export benchmarking utilities to a separate pack
Browse files Browse the repository at this point in the history
  • Loading branch information
Arcensoth committed Sep 3, 2018
1 parent c2e43b7 commit 9ae2153
Show file tree
Hide file tree
Showing 13 changed files with 1 addition and 68 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# v0.0.4-dev
- Implement automatic benchmarking
- Export benchmarking utilities to a separate pack

# v0.0.3
- Implement benchmarking utilities
Expand Down
17 changes: 0 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,10 @@ Scorespace | `tkb`
- [Where did the idea come from?](#where-did-the-idea-come-from)
- [Configuration](#configuration)
- [Target tick time](#target-tick-time)
- [Benchmarking](#benchmarking)
- [Overclocking](#overclocking)
- [Debug mode](#debug-mode)
- [Scoreboard](#scoreboard)
- [`tkb.config` objective](#tkbconfig-objective)
- [`tkb.bench` objective](#tkbbench-objective)
- [`tkb.math` objective](#tkbmath-objective)
- [Entity Tags](#entity-tags)
- [Event Hooks](#event-hooks)
Expand Down Expand Up @@ -91,9 +89,6 @@ scoreboard players set $target tkb.config 0

Allowed values are `0..50` and anything outside this range will wrap accordingly.

### Benchmarking
TODO

### Overclocking
Normally the target tick time is capped at `50` but there is a toggle that will allow you to go beyond. Generally this is not recommended because it will directly result in lag and high CPU usage. **Use at your own risk.**

Expand All @@ -117,27 +112,15 @@ tag <targets> add tickbuster.debug
Objective | Criteria | Usage | Description
------------- | --------- | --------- | -----------
`tkb.config` | `dummy` | Input | Reserved for configuration options.
`tkb.bench` | `dummy` | Read-only | Reserved for benchmark calculations.
`tkb.math` | `dummy` | Read-only | Reserved for sensitive operations.
`tkb.module` | `dummy` | Read-only | Reserved for SMF.

### `tkb.config` objective
Fakeplayer | Default | Description
------------- | ------- | -----------
`$autobench` | `0` | The number of ticks to automatically benchmark at. Set to `0` to disable.
`$overclock` | `0` | Whether to allow [overclocking](#overclocking) the target tick time.
`$target` | `20` | The [target tick time](#target-tick-time), in milliseconds.

### `tkb.bench` objective
**These values are read-only and should not be altered.**

Fakeplayer | Description
----------------- | -----------
`$current_iters` | The number of iterations, over the course of the current tick.
`$iters_per_tick` | The average number of iterations per tick, over the course of the benchmark.
`$total_iters` | The total number of iterations, over the course of the benchmark.
`$total_ticks` | The totla number of ticks, over the course of the benchmark.

### `tkb.math` objective
**These values are read-only and should not be altered.**

Expand Down
6 changes: 0 additions & 6 deletions data/tickbuster/functions/bench.mcfunction

This file was deleted.

4 changes: 0 additions & 4 deletions data/tickbuster/functions/bench/calc.mcfunction

This file was deleted.

4 changes: 0 additions & 4 deletions data/tickbuster/functions/bench/clear.mcfunction

This file was deleted.

8 changes: 0 additions & 8 deletions data/tickbuster/functions/bench/handles/after_loop.mcfunction

This file was deleted.

This file was deleted.

5 changes: 0 additions & 5 deletions data/tickbuster/functions/bench/handles/loop.mcfunction

This file was deleted.

10 changes: 0 additions & 10 deletions data/tickbuster/functions/bench/proc.mcfunction

This file was deleted.

3 changes: 0 additions & 3 deletions data/tickbuster/functions/bench/tell.mcfunction

This file was deleted.

2 changes: 0 additions & 2 deletions data/tickbuster/functions/module/api/load.mcfunction
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
# tickbuster:module/api/load

function tickbuster:bench/clear
2 changes: 0 additions & 2 deletions data/tickbuster/functions/module/api/setup.mcfunction
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
# tickbuster:module/api/setup

scoreboard objectives add tkb.config dummy
scoreboard objectives add tkb.bench dummy
scoreboard objectives add tkb.math dummy

# defaults
scoreboard players set $autobench tkb.config 0
scoreboard players set $overclock tkb.config 0
scoreboard players set $target tkb.config 20

Expand Down
1 change: 0 additions & 1 deletion data/tickbuster/functions/module/api/teardown.mcfunction
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
# tickbuster:module/api/teardown

scoreboard objectives remove tkb.config
scoreboard objectives remove tkb.bench
scoreboard objectives remove tkb.math

0 comments on commit 9ae2153

Please sign in to comment.