UD
udalov/kotlin-reflect-benchmark-experiments
kotlin-reflect-benchmark-experiments
This is a simple benchmark comparing a few different possible kotlin-reflect implementations:
DESCRIPTORS– the current implementation which uses K1 descriptorsDESCRIPTORS_WITH_METADATA– create a descriptor, but then extract protobuf, create aKmClassfrom it and use its propertiesMETADATA– createKmClassdirectly from@kotlin.MetadataRAW_PROTOBUF– read@kotlin.Metadata, and then manually extract the needed data from the protobuf
This benchmark depends on a locally built kotlin-reflect from this branch:
https://github.com/JetBrains/kotlin/tree/udalov-reflect
(Run ./gradlew dist install)
Run benchmark via:
./gradlew cleanJmh jmh