diff --git a/performance/src/main/kotlin-jvm/FakeKonanNamespace.kt b/performance/src/main/kotlin-jvm/FakeKonanNamespace.kt new file mode 100644 index 00000000000..0e09a23a64e --- /dev/null +++ b/performance/src/main/kotlin-jvm/FakeKonanNamespace.kt @@ -0,0 +1,5 @@ +package org.jetbrains.ring + +class konan { + annotation class ThreadLocal +} \ No newline at end of file diff --git a/performance/src/main/kotlin/org/jetbrains/ring/Utils.kt b/performance/src/main/kotlin/org/jetbrains/ring/Utils.kt index 166d8e961f9..4d8aaca0cae 100644 --- a/performance/src/main/kotlin/org/jetbrains/ring/Utils.kt +++ b/performance/src/main/kotlin/org/jetbrains/ring/Utils.kt @@ -21,6 +21,7 @@ import kotlin.system.measureNanoTime //-----------------------------------------------------------------------------// class Blackhole { + @konan.ThreadLocal companion object { var consumer = 0 fun consume(value: Any) { @@ -32,6 +33,7 @@ class Blackhole { //-----------------------------------------------------------------------------// class Random() { + @konan.ThreadLocal companion object { var seedInt = 0 fun nextInt(boundary: Int = 100): Int {