diff --git a/jcstress-tests/build.gradle.kts b/jcstress-tests/build.gradle.kts index dc62cdcae..6f1943f81 100644 --- a/jcstress-tests/build.gradle.kts +++ b/jcstress-tests/build.gradle.kts @@ -1,6 +1,5 @@ plugins { - id("io.github.reyerizo.gradle.jcstress") version "0.8.13" - id("minestom.common-conventions") + id("io.github.reyerizo.gradle.jcstress") version "0.8.15" } dependencies { diff --git a/jmh-benchmarks/build.gradle.kts b/jmh-benchmarks/build.gradle.kts index 589b3fbbb..e824fd81a 100644 --- a/jmh-benchmarks/build.gradle.kts +++ b/jmh-benchmarks/build.gradle.kts @@ -1,10 +1,9 @@ plugins { - id("me.champeau.jmh") version ("0.6.6") - id("minestom.common-conventions") + id("me.champeau.jmh") version ("0.7.2") } dependencies { jmhImplementation(rootProject) jmh(libs.jmh.core) jmhAnnotationProcessor(libs.jmh.annotationprocessor) -} \ No newline at end of file +} diff --git a/jmh-benchmarks/src/jmh/java/net/minestom/server/command/CommandBenchmark.java b/jmh-benchmarks/src/jmh/java/net/minestom/server/command/CommandBenchmark.java index 27faee7ed..49050cf1c 100644 --- a/jmh-benchmarks/src/jmh/java/net/minestom/server/command/CommandBenchmark.java +++ b/jmh-benchmarks/src/jmh/java/net/minestom/server/command/CommandBenchmark.java @@ -4,15 +4,10 @@ import net.minestom.server.command.builder.Command; import org.openjdk.jmh.annotations.*; import org.openjdk.jmh.infra.Blackhole; -import java.lang.String; import java.util.Set; import java.util.concurrent.TimeUnit; import java.util.function.Function; -import static net.minestom.server.command.builder.arguments.ArgumentType.Double; -import static net.minestom.server.command.builder.arguments.ArgumentType.Float; -import static net.minestom.server.command.builder.arguments.ArgumentType.Integer; -import static net.minestom.server.command.builder.arguments.ArgumentType.Long; import static net.minestom.server.command.builder.arguments.ArgumentType.*; @BenchmarkMode(Mode.AverageTime) @@ -28,8 +23,8 @@ public class CommandBenchmark { public void setup() { var graph = Graph.merge(Set.of( new Command("tp", "teleport") {{ - addSyntax((sender, context) -> {}, Potion("pos")); - addSyntax((sender, context) -> {}, Entity("entity"), Potion("pos")); + addSyntax((sender, context) -> {}, RelativeVec3("pos")); + addSyntax((sender, context) -> {}, Entity("entity"), RelativeVec3("pos")); }}, new Command("setblock", "set") {{ addSyntax((sender, context) -> {}, RelativeBlockPosition("pos"), BlockState("block")); @@ -56,7 +51,7 @@ public class CommandBenchmark { }} )); final CommandParser commandParser = CommandParser.parser(); - this.parser = input -> commandParser.parse(graph, input); + this.parser = input -> commandParser.parse(null, graph, input); } @Benchmark diff --git a/settings.gradle.kts b/settings.gradle.kts index 68ea5a446..486c51ef5 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -2,7 +2,7 @@ rootProject.name = "minestom" include("testing") include("code-generators") -//include("jmh-benchmarks") -//include("jcstress-tests") +include("jmh-benchmarks") +include("jcstress-tests") include("demo")