https://kotlinlang.org logo
#gsoc
Title
# gsoc
a

Aswin Dev SP

03/20/2024, 7:28 PM
Hi @Abduqodiri Qurbonzoda [JB] and @Alexander Shabalin [JB] would you be able to recommend some resources on Kotlin/Native memory management and benchmarking concepts? I've already started looking into kotlinx-benchmark repo, but I'd love some pointers on where to deepen my understanding. Thanks in advance!
a

Abduqodiri Qurbonzoda [JB]

03/22/2024, 12:24 PM
Hi @Aswin Dev SP , I’m glad you found this project interesting. A great starting point is to explore and experiment with the kotlinx-benchmark library. Writing some benchmarks and running them with different configurations is essential to familiarize yourself with both the project and the concept of benchmarking. Please read the README and other documentation in the repo: https://github.com/Kotlin/kotlinx-benchmark/tree/master/docs The next steps would be: 1. Look into how benchmarking/measuring is implemented for Kotlin/Native. A good entry point is here:: https://github.com/Kotlin/kotlinx-benchmark/blob/master/runtime/nativeMain/src/kotlinx/benchmark/native/NativeExecutor.kt 2. Consider how you could integrate measurement of allocations. The API for retrieving allocation information will be provided by the Kotlin/Native standard library. 3. Experiment with the JMH garbage collection profiler (
-prof gc
). Check out https://github.com/openjdk/jmh/blob/master/jmh-samples/src/main/java/org/openjdk/jmh/samples/JMHSample_35_Profilers.java. We aim to produce a similar report for benchmark methods in Kotlin/Native, so understanding the output and its format is crucial.
a

Aswin Dev SP

03/22/2024, 11:03 PM
Thanks, this is really helpful
7 Views