Describe the bug
The synchronized block in the char array pool appears to be a bottleneck on the concurrent serialization of many small objects to json:
https://github.com/Kotlin/kotlinx.serialization/blob/4667a1891a925dc9e3e10490c274a[…]n/jvmMain/src/kotlinx/serialization/json/internal/ArrayPools.kt
We observe this in the https://github.com/TechEmpower/FrameworkBenchmarks for Ktor using kotlinx.serialization
Describe the bug
The synchronized block in the char array pool appears to be a bottleneck on the concurrent serialization of many small objects to json:
https://github.com/Kotlin/kotlinx.serialization/blob/4667a1891a925dc9e3e10490c274a[…]n/jvmMain/src/kotlinx/serialization/json/internal/ArrayPools.kt
We observe this in the https://github.com/TechEmpower/FrameworkBenchmarks for Ktor using kotlinx.serialization