diff --git a/benchmarks/ios/jvm-vs-kotlin-native/README.md b/benchmarks/ios/jvm-vs-kotlin-native/README.md index 2d3a57fa6a..71ac559bc8 100644 --- a/benchmarks/ios/jvm-vs-kotlin-native/README.md +++ b/benchmarks/ios/jvm-vs-kotlin-native/README.md @@ -6,3 +6,6 @@ ## Run native on MacOS - `./gradlew runReleaseExecutableMacosArm64` (Works on Arm64 processors) - `./gradlew runReleaseExecutableMacosX64` (Works on Intel processors) + +## Run in web browser: +- `./gradlew wasmJsBrowserProductionRun` (you can see the results printed on the page itself) \ No newline at end of file diff --git a/benchmarks/ios/jvm-vs-kotlin-native/build.gradle.kts b/benchmarks/ios/jvm-vs-kotlin-native/build.gradle.kts index f2e0a3ea6c..f1d23af7c0 100644 --- a/benchmarks/ios/jvm-vs-kotlin-native/build.gradle.kts +++ b/benchmarks/ios/jvm-vs-kotlin-native/build.gradle.kts @@ -38,6 +38,11 @@ kotlin { } } + wasmJs { + browser() + binaries.executable() + } + sourceSets { val commonMain by getting { dependencies { diff --git a/benchmarks/ios/jvm-vs-kotlin-native/src/wasmJsMain/kotlin/main.wasmjs.kt b/benchmarks/ios/jvm-vs-kotlin-native/src/wasmJsMain/kotlin/main.wasmjs.kt new file mode 100644 index 0000000000..202cdb363b --- /dev/null +++ b/benchmarks/ios/jvm-vs-kotlin-native/src/wasmJsMain/kotlin/main.wasmjs.kt @@ -0,0 +1,4 @@ +fun main() { + runBenchmarks() + println("Completed!") +} \ No newline at end of file diff --git a/benchmarks/ios/jvm-vs-kotlin-native/src/wasmJsMain/resources/index.html b/benchmarks/ios/jvm-vs-kotlin-native/src/wasmJsMain/resources/index.html new file mode 100644 index 0000000000..4168e1755c --- /dev/null +++ b/benchmarks/ios/jvm-vs-kotlin-native/src/wasmJsMain/resources/index.html @@ -0,0 +1,21 @@ + + +
+ +