-
Notifications
You must be signed in to change notification settings - Fork 8
Using SIMD
Starting from version 2.8, Brain4J includes SIMD (Single Instruction, Multiple Data) support via the Java Vector API (JEP 448). This enables significant performance improvements by leveraging hardware-level parallelism.
For technical details and implementation discussions, refer to the related pull request.
To take advantage of SIMD acceleration, you must explicitly enable the jdk.incubator.vector
module when running your application. This can be done in two main ways:
If you're using Gradle, add this piece of code to your build.gradle
:
tasks.withType(JavaExec).configureEach {
jvmArgs(['--add-modules', 'jdk.incubator.vector'])
}
Alternatively, you can enable the module via JVM options. Add the following argument when launching your application:
--add-modules jdk.incubator.vector
Check out Benchmark & Performance
This wiki is still under construction. If you feel that you can contribute, please do so! Thanks.