Skip to content

iOS: re-read the view size when a covering modal is dismissed (#6080) - #6115

Merged
shai-almog merged 5 commits into
masterfrom
ios-camera-landscape-6080
Oct 28, 2026
Merged

shai-almog merged 5 commits into
masterfrom
ios-camera-landscape-6080

Conversation

@shai-almog

Copy link
Copy Markdown
Collaborator

Fixes the remaining case of #6080: app in landscape, portrait-only camera opened, phone kept landscape, photo accepted -> the app returns with portrait display/Form dimensions over a landscape view.

Presenting the portrait-only modal sends the covered controller a portrait viewWillTransitionToSize:, which publishes the portrait size, but the covered view is never laid out portrait. On dismissal its bounds are unchanged, so no layout pass runs and #6085's viewDidLayoutSubviews sync never fires.

  • viewDidLayoutSubviews' sync is now cn1PublishViewSizeIfChanged, also called from viewDidAppear and from the transition completion (skipped while still covered).
  • NativeModalRotationTest gains a landscape-stays-landscape case that requires the precondition (portrait display over a landscape view under the modal) and then asserts the display matches the view after dismissal.

🤖 Generated with Claude Code

shai-almog and others added 3 commits October 26, 2026 20:18
Presenting the portrait-only camera over a landscape app sends the covered
controller a portrait viewWillTransitionToSize:, but its bounds never change,
so staying in landscape leaves no layout pass to correct the published size.
viewDidAppear and the transition completion now re-sync from the bounds.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ays-landscape case (#6080)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@shai-almog

shai-almog commented Oct 26, 2026 •

Copy link
Copy Markdown
Collaborator Author

Compared 191 screenshots: 191 matched.

Native Android coverage

  • 📊 Line coverage: 18.89% (48254/255385 lines covered) [HTML preview] (artifact android-coverage-report, jacocoAndroidReport/html/index.html)
    • Other counters: instruction 17.64% (229221/1299370), branch 12.04% (16822/139693), complexity 9.67% (12915/133497), method 14.56% (9124/62650), class 25.13% (1775/7062)
    • Lowest covered classes
      • kotlin.collections.kotlin.collections.ArraysKt___ArraysKt – 0.00% (0/6367 lines covered)
      • kotlin.collections.unsigned.kotlin.collections.unsigned.UArraysKt___UArraysKt – 0.00% (0/2384 lines covered)
      • org.jacoco.agent.rt.internal_0e20598.asm.org.jacoco.agent.rt.internal_0e20598.asm.ClassReader – 0.00% (0/1524 lines covered)
      • org.jacoco.agent.rt.internal_0e20598.asm.org.jacoco.agent.rt.internal_0e20598.asm.MethodWriter – 0.00% (0/922 lines covered)
      • kotlin.sequences.kotlin.sequences.SequencesKt___SequencesKt – 0.00% (0/736 lines covered)
      • com.google.common.cache.com.google.common.cache.LocalCache$Segment – 0.00% (0/726 lines covered)
      • okio.okio.Buffer – 0.00% (0/687 lines covered)
      • kotlin.text.kotlin.text.StringsKt___StringsKt – 0.00% (0/625 lines covered)
      • com.codename1.androidcompat.rt.com.codename1.androidcompat.rt.TextXmlPullParser – 0.00% (0/623 lines covered)
      • com.codename1.androidcompat.androidx.constraintlayout.core.widgets.com.codename1.androidcompat.androidx.constraintlayout.core.widgets.Flow – 0.00% (0/576 lines covered)

✅ Native Android screenshot tests passed.

Native Android coverage

  • 📊 Line coverage: 18.89% (48254/255385 lines covered) [HTML preview] (artifact android-coverage-report, jacocoAndroidReport/html/index.html)
    • Other counters: instruction 17.64% (229221/1299370), branch 12.04% (16822/139693), complexity 9.67% (12915/133497), method 14.56% (9124/62650), class 25.13% (1775/7062)
    • Lowest covered classes
      • kotlin.collections.kotlin.collections.ArraysKt___ArraysKt – 0.00% (0/6367 lines covered)
      • kotlin.collections.unsigned.kotlin.collections.unsigned.UArraysKt___UArraysKt – 0.00% (0/2384 lines covered)
      • org.jacoco.agent.rt.internal_0e20598.asm.org.jacoco.agent.rt.internal_0e20598.asm.ClassReader – 0.00% (0/1524 lines covered)
      • org.jacoco.agent.rt.internal_0e20598.asm.org.jacoco.agent.rt.internal_0e20598.asm.MethodWriter – 0.00% (0/922 lines covered)
      • kotlin.sequences.kotlin.sequences.SequencesKt___SequencesKt – 0.00% (0/736 lines covered)
      • com.google.common.cache.com.google.common.cache.LocalCache$Segment – 0.00% (0/726 lines covered)
      • okio.okio.Buffer – 0.00% (0/687 lines covered)
      • kotlin.text.kotlin.text.StringsKt___StringsKt – 0.00% (0/625 lines covered)
      • com.codename1.androidcompat.rt.com.codename1.androidcompat.rt.TextXmlPullParser – 0.00% (0/623 lines covered)
      • com.codename1.androidcompat.androidx.constraintlayout.core.widgets.com.codename1.androidcompat.androidx.constraintlayout.core.widgets.Flow – 0.00% (0/576 lines covered)

Benchmark Results

Detailed Performance Metrics

Metric Duration
SIMD kernel backend scalar fallback (no native SIMD)
SIMD int-add (64K x300) java 540ms / native 486ms = 1.1x speedup
SIMD float-mul (64K x300) java 204ms / native 189ms = 1.0x speedup
SIMD kernel correctness PASS (native result == scalar reference)
Base64 payload size 8192 bytes
Base64 benchmark iterations 6000
Base64 SIMD byte path gated to scalar (CPU autovectorizes scalar; explicit SIMD not beneficial here)
Base64 CN1 encode 78.000 ms
Base64 CN1 decode 84.000 ms
Base64 native encode 455.000 ms
Base64 encode ratio (CN1/native) 0.171x (82.9% faster)
Base64 native decode 274.000 ms
Base64 decode ratio (CN1/native) 0.307x (69.3% faster)
Image encode benchmark status skipped (SIMD unsupported)

@shai-almog

shai-almog commented Oct 26, 2026 •

Copy link
Copy Markdown
Collaborator Author

Compared 206 screenshots: 206 matched.
Native Windows port, REAL shipping pipeline: the hellocodenameone screenshot suite rendered by a binary CROSS-COMPILED on Linux (clang-cl + xwin, WebView2 linked) and RUN on a Windows x64 runner. Compared against the in-repo baseline in scripts/windows/screenshots.

Benchmark Results

Detailed Performance Metrics

Metric Duration
SIMD kernel backend SSE2 (x64) / NEON (arm64) native kernels
SIMD int-add (64K x300) java 57ms / native 5ms = 11.4x speedup
SIMD float-mul (64K x300) java 57ms / native 4ms = 14.2x speedup
SIMD kernel correctness PASS (native result == scalar reference)
Base64 native bridge unavailable (CN1 + SIMD + image benchmarks only)
Base64 payload size 8192 bytes
Base64 benchmark iterations 6000
Base64 SIMD byte path gated to scalar (CPU autovectorizes scalar; explicit SIMD not beneficial here)
Base64 CN1 encode 75.000 ms
Base64 CN1 decode 90.000 ms
Base64 SIMD encode 109.000 ms
Base64 encode ratio (SIMD/CN1) 1.453x (45.3% slower)
Base64 SIMD decode 106.000 ms
Base64 decode ratio (SIMD/CN1) 1.178x (17.8% slower)
Image encode benchmark iterations 100
Image createMask (SIMD off) 9.000 ms
Image createMask (SIMD on) 3.000 ms
Image createMask ratio (SIMD on/off) 0.333x (66.7% faster)
Image applyMask (SIMD off) 28.000 ms
Image applyMask (SIMD on) 30.000 ms
Image applyMask ratio (SIMD on/off) 1.071x (7.1% slower)
Image modifyAlpha (SIMD off) 31.000 ms
Image modifyAlpha (SIMD on) 18.000 ms
Image modifyAlpha ratio (SIMD on/off) 0.581x (41.9% faster)
Image modifyAlpha removeColor (SIMD off) 29.000 ms
Image modifyAlpha removeColor (SIMD on) 15.000 ms
Image modifyAlpha removeColor ratio (SIMD on/off) 0.517x (48.3% faster)

@github-actions

github-actions Bot commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

✅ Continuous Quality Report

Test & Coverage

Static Analysis

  • SpotBugs [Report archive]
    • ✅ ByteCodeTranslator: 0 findings (no issues)
    • ✅ android: 0 findings (no issues)
    • ✅ android-compat: 0 findings (no issues)
    • ✅ android-res-compiler: 0 findings (no issues)
    • ✅ backend: 0 findings (no issues)
    • ✅ backend-test: 0 findings (no issues)
    • ✅ build-engine: 0 findings (no issues)
    • ✅ build-hint-catalog: 0 findings (no issues)
    • ✅ build-hint-tools: 0 findings (no issues)
    • ✅ codenameone-gradle-plugin: 0 findings (no issues)
    • ✅ codenameone-maven-plugin: 0 findings (no issues)
    • ✅ core-unittests: 0 findings (no issues)
    • ✅ desktop-compat-runtime: 0 findings (no issues)
    • ✅ fxml-compiler: 0 findings (no issues)
    • ✅ ios: 0 findings (no issues)
    • ✅ javac: 0 findings (no issues)
    • ✅ javafx-compat: 0 findings (no issues)
    • ✅ project-model: 0 findings (no issues)
    • ✅ swing-compat: 0 findings (no issues)
  • ❌ PMD: 1 findings (P3: 1) [HTML preview] [Download]
  • ✅ Checkstyle: 0 findings (no issues) [Report archive]

Generated automatically by the PR CI workflow.

@shai-almog

shai-almog commented Oct 26, 2026 •

Copy link
Copy Markdown
Collaborator Author

Compared 227 screenshots: 227 matched.
✅ JavaScript-port screenshot tests passed.

@shai-almog

shai-almog commented Oct 26, 2026 •

Copy link
Copy Markdown
Collaborator Author

Compared 206 screenshots: 206 matched.
Native Windows port (x64 / Intel-AMD): full hellocodenameone screenshot suite rendered offscreen with Direct2D/DirectWrite, plus the real benchmarks (base64 native/CN1/SIMD, image createMask/applyMask/modifyAlpha/PNG/JPEG, SSE2 SIMD kernels). Compared against the in-repo baseline in scripts/windows/screenshots.

Benchmark Results

Detailed Performance Metrics

Metric Duration
SIMD kernel backend SSE2 (x64) / NEON (arm64) native kernels
SIMD int-add (64K x300) java 45ms / native 3ms = 15.0x speedup
SIMD float-mul (64K x300) java 44ms / native 4ms = 11.0x speedup
SIMD kernel correctness PASS (native result == scalar reference)
Base64 native bridge unavailable (CN1 + SIMD + image benchmarks only)
Base64 payload size 8192 bytes
Base64 benchmark iterations 6000
Base64 SIMD byte path gated to scalar (CPU autovectorizes scalar; explicit SIMD not beneficial here)
Base64 CN1 encode 59.000 ms
Base64 CN1 decode 74.000 ms
Base64 SIMD encode 80.000 ms
Base64 encode ratio (SIMD/CN1) 1.356x (35.6% slower)
Base64 SIMD decode 76.000 ms
Base64 decode ratio (SIMD/CN1) 1.027x (2.7% slower)
Image encode benchmark iterations 100
Image createMask (SIMD off) 9.000 ms
Image createMask (SIMD on) 5.000 ms
Image createMask ratio (SIMD on/off) 0.556x (44.4% faster)
Image applyMask (SIMD off) 32.000 ms
Image applyMask (SIMD on) 29.000 ms
Image applyMask ratio (SIMD on/off) 0.906x (9.4% faster)
Image modifyAlpha (SIMD off) 35.000 ms
Image modifyAlpha (SIMD on) 21.000 ms
Image modifyAlpha ratio (SIMD on/off) 0.600x (40.0% faster)
Image modifyAlpha removeColor (SIMD off) 35.000 ms
Image modifyAlpha removeColor (SIMD on) 22.000 ms
Image modifyAlpha removeColor ratio (SIMD on/off) 0.629x (37.1% faster)

ParparVM vs HotSpot (JDK 25): Windows x64

Runner CPU: Intel64 Family 6 Model 207 Stepping 2, GenuineIntel (baseline windows-x64@intel64-family-6-model-207-genuineintel)

2 improvements past the baseline (not a failure; rebaseline to lock them in):

  • hello (WinHelloMain) on all 4 CPUs: RAM 0.55x against a 0.86x baseline (-35.9%, tolerance 35%)
  • recursion on all 4 CPUs: time 0.94x against a 1.20x baseline (-21.9%, tolerance 20%)

Ratios are ParparVM / JDK 25: below 1.00x ParparVM is faster (time) or smaller (RAM). Median of 5 interleaved, paired rounds; every run's output was verified. A ratio more than 20% (time) / 25% (RAM) above its baseline in vm/selfhost/perf-baseline/ is a regression and fails; one that far below is an improvement, reported but not failed (a row whose calibration runs were noisier carries a wider tolerance), and for RAM the change must also exceed 0.05x in absolute terms. Both run unpinned on all of the runner's CPUs, with their own default thread counts.

Benchmark Cores Time RAM Status
hello (WinHelloMain) 4 1.24x (base 1.07x, +16.2%) 0.55x (base 0.86x, -35.9%) improved: rebaseline to lock in (RAM -35.9%)
translator (self) 4 0.79x (base 0.79x, +0.3%) 0.52x (base 0.53x, -1.6%) ok
intArithmetic 4 1.02x (base 1.02x, -0.1%) 0.06x (base 0.06x, -3.2%) ok
longArithmetic 4 0.97x (base 0.97x, -0.3%) 0.06x (base 0.05x, +2.7%) ok
mathTranscendental 4 0.89x (base 0.89x, +0.6%) 0.06x (base 0.06x, +1.9%) ok
arraySequential 4 1.53x (base 1.98x, -22.9%) 0.38x (base 0.38x, +0.2%) ok
arrayRandom 4 1.01x (base 1.01x, +0.0%) 0.23x (base 0.23x, +0.6%) ok
objectAllocation 4 0.95x (base 1.22x, -21.5%) 0.38x (base 0.37x, +3.3%) ok
valueEscape 4 0.13x (base 0.13x, +2.1%) 0.05x (base 0.04x, +3.7%) ok
hashMapChurn 4 1.15x (base 1.14x, +0.5%) 0.10x (base 0.10x, +1.6%) ok
stringBuilding 4 1.47x (base 1.42x, +3.9%) 0.27x (base 0.22x, +20.3%) ok
recursion 4 0.94x (base 1.20x, -21.9%) 0.06x (base 0.06x, +2.8%) improved: rebaseline to lock in (time -21.9%)
quicksort 4 1.03x (base 1.07x, -3.5%) 0.12x (base 0.12x, +1.3%) ok

A change that moves performance ON PURPOSE records the new baseline in vm/selfhost/perf-baseline/pr/6115.json, with the reason, from this job's perf-results.json. The rebaseline is then part of this pull request's diff:

python3 vm/selfhost/calibrate-perf-baseline.py --pr 6115 --reason "<why these benchmarks moved>" perf-results.json

Result: no regression (improved past the baseline: consider rebaselining)

@shai-almog

shai-almog commented Oct 26, 2026 •

Copy link
Copy Markdown
Collaborator Author

Compared 206 screenshots: 206 matched.
Native Linux port (arm64), GTK3/Cairo/Pango, ParparVM bytecode-to-C (no JVM): the hellocodenameone screenshot suite rendered by a native ELF built + run on the GitHub arm64 runner. Baseline: scripts/linux/screenshots-arm.

ParparVM vs HotSpot (JDK 25): Linux arm64

Runner CPU: Neoverse-N2 (baseline linux-arm64@neoverse-n2)

Ratios are ParparVM / JDK 25: below 1.00x ParparVM is faster (time) or smaller (RAM). Median of 5 interleaved, paired rounds; every run's output was verified. A ratio more than 20% (time) / 25% (RAM) above its baseline in vm/selfhost/perf-baseline/ is a regression and fails; one that far below is an improvement, reported but not failed (a row whose calibration runs were noisier carries a wider tolerance), and for RAM the change must also exceed 0.05x in absolute terms. Both run unpinned on all of the runner's CPUs, with their own default thread counts.

Benchmark Cores Time RAM Status
hello (LinuxHelloMain) 4 0.97x (base 1.02x, -5.0%) 0.66x (base 0.93x, -29.4%) ok
translator (self) 4 0.76x (base 0.70x, +9.6%) 0.46x (base 0.43x, +5.9%) ok
intArithmetic 4 1.05x (base 1.04x, +0.0%) 0.03x (base 0.03x, +4.6%) ok
longArithmetic 4 0.79x (base 0.79x, -0.0%) 0.03x (base 0.03x, +5.0%) ok
mathTranscendental 4 1.09x (base 1.10x, -0.3%) 0.04x (base 0.03x, +9.1%) ok
arraySequential 4 0.39x (base 0.36x, +7.0%) 0.37x (base 0.37x, +0.3%) ok
arrayRandom 4 0.94x (base 0.94x, +0.2%) 0.20x (base 0.20x, +0.6%) ok
objectAllocation 4 1.95x (base 1.77x, +10.4%) 0.37x (base 0.37x, -0.6%) ok
valueEscape 4 0.51x (base 0.51x, -0.1%) 0.03x (base 0.03x, +4.8%) ok
hashMapChurn 4 0.83x (base 0.84x, -1.9%) 0.12x (base 0.12x, -2.8%) ok
stringBuilding 4 1.45x (base 1.57x, -7.7%) 0.27x (base 0.26x, +2.7%) ok
recursion 4 1.41x (base 1.43x, -1.6%) 0.04x (base 0.04x, +2.5%) ok
quicksort 4 1.00x (base 0.99x, +1.1%) 0.09x (base 0.09x, +1.2%) ok

Result: no regression

@shai-almog

shai-almog commented Oct 26, 2026 •

Copy link
Copy Markdown
Collaborator Author

Compared 206 screenshots: 206 matched.
Native Windows port (arm64 / Apple Silicon - Arm): full hellocodenameone screenshot suite rendered offscreen with Direct2D/DirectWrite, plus the real benchmarks (base64 native/CN1/SIMD, image createMask/applyMask/modifyAlpha/PNG/JPEG, NEON SIMD kernels). Compared against the in-repo baseline in scripts/windows/screenshots.

Benchmark Results

Detailed Performance Metrics

Metric Duration
SIMD kernel backend SSE2 (x64) / NEON (arm64) native kernels
SIMD int-add (64K x300) java 49ms / native 2ms = 24.5x speedup
SIMD float-mul (64K x300) java 48ms / native 3ms = 16.0x speedup
SIMD kernel correctness PASS (native result == scalar reference)
Base64 native bridge unavailable (CN1 + SIMD + image benchmarks only)
Base64 payload size 8192 bytes
Base64 benchmark iterations 6000
Base64 SIMD byte path gated to scalar (CPU autovectorizes scalar; explicit SIMD not beneficial here)
Base64 CN1 encode 62.000 ms
Base64 CN1 decode 70.000 ms
Base64 SIMD encode 78.000 ms
Base64 encode ratio (SIMD/CN1) 1.258x (25.8% slower)
Base64 SIMD decode 68.000 ms
Base64 decode ratio (SIMD/CN1) 0.971x (2.9% faster)
Image encode benchmark iterations 100
Image createMask (SIMD off) 5.000 ms
Image createMask (SIMD on) 1.000 ms
Image createMask ratio (SIMD on/off) 0.200x (80.0% faster)
Image applyMask (SIMD off) 19.000 ms
Image applyMask (SIMD on) 21.000 ms
Image applyMask ratio (SIMD on/off) 1.105x (10.5% slower)
Image modifyAlpha (SIMD off) 17.000 ms
Image modifyAlpha (SIMD on) 14.000 ms
Image modifyAlpha ratio (SIMD on/off) 0.824x (17.6% faster)
Image modifyAlpha removeColor (SIMD off) 20.000 ms
Image modifyAlpha removeColor (SIMD on) 10.000 ms
Image modifyAlpha removeColor ratio (SIMD on/off) 0.500x (50.0% faster)

ParparVM vs HotSpot (JDK 25): Windows arm64

Runner CPU: ARMv8 (64-bit) Family 8 Model D49 Revision 0, MICROSOFT CORPORATION (baseline windows-arm64@armv8-64-bit-family-8-model-d49-microsoft-corporation)

Ratios are ParparVM / JDK 25: below 1.00x ParparVM is faster (time) or smaller (RAM). Median of 5 interleaved, paired rounds; every run's output was verified. A ratio more than 20% (time) / 25% (RAM) above its baseline in vm/selfhost/perf-baseline/ is a regression and fails; one that far below is an improvement, reported but not failed (a row whose calibration runs were noisier carries a wider tolerance), and for RAM the change must also exceed 0.05x in absolute terms. Both run unpinned on all of the runner's CPUs, with their own default thread counts.

Benchmark Cores Time RAM Status
hello (WinHelloMain) 4 1.00x (base 1.11x, -9.9%) 0.61x (base 0.75x, -19.0%) ok
translator (self) 4 0.90x (base 0.84x, +7.0%) 0.50x (base 0.51x, -2.1%) ok
intArithmetic 4 1.04x (base 1.04x, +0.0%) 0.06x (base 0.06x, +3.1%) ok
longArithmetic 4 0.79x (base 0.80x, -0.0%) 0.06x (base 0.06x, +3.5%) ok
mathTranscendental 4 0.72x (base 0.72x, +0.0%) 0.07x (base 0.06x, +1.6%) ok
arraySequential 4 0.36x (base 0.46x, -21.2%) 0.39x (base 0.39x, -0.1%) ok
arrayRandom 4 0.93x (base 0.94x, -0.5%) 0.23x (base 0.23x, +0.6%) ok
objectAllocation 4 1.77x (base 1.82x, -2.6%) 0.32x (base 0.43x, -24.8%) ok
valueEscape 4 0.76x (base 0.76x, +0.1%) 0.05x (base 0.05x, +3.7%) ok
hashMapChurn 4 1.01x (base 0.98x, +2.2%) 0.12x (base 0.12x, +4.3%) ok
stringBuilding 4 1.60x (base 1.43x, +12.1%) 0.27x (base 0.27x, -0.4%) ok
recursion 4 1.55x (base 1.46x, +6.0%) 0.07x (base 0.07x, +1.4%) ok
quicksort 4 1.01x (base 1.00x, +0.4%) 0.12x (base 0.12x, +0.5%) ok

Result: no regression

@shai-almog

shai-almog commented Oct 26, 2026 •

Copy link
Copy Markdown
Collaborator Author

Compared 206 screenshots: 206 matched.
Native Linux port (x64), GTK3/Cairo/Pango, ParparVM bytecode-to-C (no JVM): the hellocodenameone screenshot suite rendered by a native ELF built + run on the GitHub x64 runner. Baseline: scripts/linux/screenshots.

ParparVM vs HotSpot (JDK 25): Linux x64

Runner CPU: AMD EPYC 9V74 80-Core Processor (baseline linux-x64@amd-epyc-9v74-80-core-processor)

1 improvement past the baseline (not a failure; rebaseline to lock it in):

  • hello (LinuxHelloMain) on all 4 CPUs: RAM 0.68x against a 0.96x baseline (-29.3%, tolerance 25%)

Ratios are ParparVM / JDK 25: below 1.00x ParparVM is faster (time) or smaller (RAM). Median of 5 interleaved, paired rounds; every run's output was verified. A ratio more than 20% (time) / 25% (RAM) above its baseline in vm/selfhost/perf-baseline/ is a regression and fails; one that far below is an improvement, reported but not failed (a row whose calibration runs were noisier carries a wider tolerance), and for RAM the change must also exceed 0.05x in absolute terms. Both run unpinned on all of the runner's CPUs, with their own default thread counts.

Benchmark Cores Time RAM Status
hello (LinuxHelloMain) 4 0.91x (base 0.90x, +1.8%) 0.68x (base 0.96x, -29.3%) improved: rebaseline to lock in (RAM -29.3%)
translator (self) 4 0.69x (base 0.63x, +9.8%) 0.44x (base 0.46x, -5.3%) ok
intArithmetic 4 1.10x (base 1.10x, -0.0%) 0.08x (base 0.06x, +37.7%) ok
longArithmetic 4 1.08x (base 1.08x, +0.0%) 0.07x (base 0.06x, +34.4%) ok
mathTranscendental 4 1.09x (base 1.09x, -0.3%) 0.08x (base 0.07x, +16.6%) ok
arraySequential 4 2.61x (base 2.81x, -7.1%) 0.38x (base 0.35x, +6.6%) ok
arrayRandom 4 1.02x (base 1.02x, -0.3%) 0.23x (base 0.21x, +7.7%) ok
objectAllocation 4 1.22x (base 1.21x, +0.9%) 0.28x (base 0.39x, -28.2%) ok
valueEscape 4 0.10x (base 0.10x, +0.5%) 0.05x (base 0.06x, -21.6%) ok
hashMapChurn 4 1.40x (base 1.10x, +27.5%) 0.10x (base 0.10x, -0.8%) ok
stringBuilding 4 1.43x (base 1.49x, -3.8%) 0.26x (base 0.26x, +0.3%) ok
recursion 4 1.14x (base 1.24x, -8.2%) 0.06x (base 0.06x, +2.2%) ok
quicksort 4 1.10x (base 1.07x, +3.0%) 0.13x (base 0.11x, +19.1%) ok

A change that moves performance ON PURPOSE records the new baseline in vm/selfhost/perf-baseline/pr/6115.json, with the reason, from this job's perf-results.json. The rebaseline is then part of this pull request's diff:

python3 vm/selfhost/calibrate-perf-baseline.py --pr 6115 --reason "<why these benchmarks moved>" perf-results.json

Result: no regression (improved past the baseline: consider rebaselining)

@shai-almog

shai-almog commented Oct 26, 2026 •

Copy link
Copy Markdown
Collaborator Author

Compared 192 screenshots: 192 matched.
✅ Native Mac screenshot tests passed.

Benchmark Results

  • VM Translation Time: 0 seconds
  • Compilation Time: 526 seconds

Detailed Performance Metrics

Metric Duration
SIMD kernel backend SSE2 (x64) / NEON (arm64) native kernels
SIMD int-add (64K x300) java 57ms / native 3ms = 19.0x speedup
SIMD float-mul (64K x300) java 54ms / native 2ms = 27.0x speedup
SIMD kernel correctness PASS (native result == scalar reference)
Base64 native bridge unavailable (CN1 + SIMD + image benchmarks only)
Base64 payload size 8192 bytes
Base64 benchmark iterations 6000
Base64 SIMD byte path active (NEON-accelerated)
Base64 CN1 encode 74.000 ms
Base64 CN1 decode 73.000 ms
Image encode benchmark iterations 100
Image createMask (SIMD off) 9.000 ms
Image createMask (SIMD on) 5.000 ms
Image createMask ratio (SIMD on/off) 0.556x (44.4% faster)
Image applyMask (SIMD off) 73.000 ms
Image applyMask (SIMD on) 86.000 ms
Image applyMask ratio (SIMD on/off) 1.178x (17.8% slower)
Image modifyAlpha (SIMD off) 84.000 ms
Image modifyAlpha (SIMD on) 53.000 ms
Image modifyAlpha ratio (SIMD on/off) 0.631x (36.9% faster)
Image modifyAlpha removeColor (SIMD off) 66.000 ms
Image modifyAlpha removeColor (SIMD on) 52.000 ms
Image modifyAlpha removeColor ratio (SIMD on/off) 0.788x (21.2% faster)

ParparVM vs HotSpot (JDK 25): macOS arm64

Runner CPU: Apple M1 (Virtual) (baseline macos-arm64)

Ratios are ParparVM / JDK 25: below 1.00x ParparVM is faster (time) or smaller (RAM). Median of 5 interleaved, paired rounds; every run's output was verified. A ratio more than 20% (time) / 25% (RAM) above its baseline in vm/selfhost/perf-baseline/ is a regression and fails; one that far below is an improvement, reported but not failed (a row whose calibration runs were noisier carries a wider tolerance), and for RAM the change must also exceed 0.05x in absolute terms. Both run unpinned on all of the runner's CPUs, with their own default thread counts.

Benchmark Cores Time RAM Status
hello (HelloCodenameOne) 3 0.79x (base 0.96x, -17.5%) 0.87x (base 0.93x, -6.5%) ok
translator (self) 3 0.60x (base 0.62x, -4.3%) 0.57x (base 0.78x, -26.5%) ok
intArithmetic 3 1.04x (base 1.03x, +1.0%) 0.12x (base 0.12x, +1.6%) ok
longArithmetic 3 0.97x (base 1.03x, -5.6%) 0.12x (base 0.07x, +66.2%) ok
mathTranscendental 3 0.99x (base 1.01x, -1.5%) 0.12x (base 0.12x, +0.3%) ok
arraySequential 3 0.44x (base 0.42x, +5.3%) 0.53x (base 0.53x, +0.6%) ok
arrayRandom 3 0.98x (base 0.99x, -1.3%) 0.33x (base 0.32x, +0.4%) ok
objectAllocation 3 1.01x (base 1.11x, -8.4%) 0.63x (base 0.72x, -12.9%) ok
valueEscape 3 0.50x (base 0.51x, -1.5%) 0.09x (base 0.09x, +1.9%) ok
hashMapChurn 3 1.00x (base 1.18x, -14.8%) 0.07x (base 0.07x, +10.8%) ok
stringBuilding 3 0.82x (base 0.84x, -3.1%) 0.47x (base 0.46x, +0.6%) ok
recursion 3 1.24x (base 1.24x, +0.7%) 0.11x (base 0.12x, -2.7%) ok
quicksort 3 0.94x (base 1.01x, -6.9%) 0.11x (base 0.11x, +0.8%) ok

Result: no regression

@shai-almog

shai-almog commented Oct 27, 2026 •

Copy link
Copy Markdown
Collaborator Author

Compared 184 screenshots: 184 matched.
✅ Native Apple TV (tvOS, Metal) screenshot tests passed.

@shai-almog

shai-almog commented Oct 27, 2026 •

Copy link
Copy Markdown
Collaborator Author

Compared 188 screenshots: 188 matched.
✅ Native Mac screenshot tests passed.

Benchmark Results

  • VM Translation Time: 0 seconds
  • Compilation Time: 624 seconds

Detailed Performance Metrics

Metric Duration
SIMD kernel backend SSE2 (x64) / NEON (arm64) native kernels
SIMD int-add (64K x300) java 53ms / native 3ms = 17.6x speedup
SIMD float-mul (64K x300) java 54ms / native 3ms = 18.0x speedup
SIMD kernel correctness PASS (native result == scalar reference)
Base64 payload size 8192 bytes
Base64 benchmark iterations 6000
Base64 SIMD byte path active (NEON-accelerated)
Base64 CN1 encode 51.000 ms
Base64 CN1 decode 70.000 ms
Base64 native encode 654.000 ms
Base64 encode ratio (CN1/native) 0.078x (92.2% faster)
Base64 native decode 297.000 ms
Base64 decode ratio (CN1/native) 0.236x (76.4% faster)
Base64 SIMD encode 53.000 ms
Base64 encode ratio (SIMD/CN1) 1.039x (3.9% slower)
Base64 SIMD decode 55.000 ms
Base64 decode ratio (SIMD/CN1) 0.786x (21.4% faster)
Base64 encode ratio (SIMD/native) 0.081x (91.9% faster)
Base64 decode ratio (SIMD/native) 0.185x (81.5% faster)
Image encode benchmark iterations 100
Image createMask (SIMD off) 17.000 ms
Image createMask (SIMD on) 7.000 ms
Image createMask ratio (SIMD on/off) 0.412x (58.8% faster)
Image applyMask (SIMD off) 109.000 ms
Image applyMask (SIMD on) 114.000 ms
Image applyMask ratio (SIMD on/off) 1.046x (4.6% slower)
Image modifyAlpha (SIMD off) 138.000 ms
Image modifyAlpha (SIMD on) 107.000 ms
Image modifyAlpha ratio (SIMD on/off) 0.775x (22.5% faster)
Image modifyAlpha removeColor (SIMD off) 120.000 ms
Image modifyAlpha removeColor (SIMD on) 68.000 ms
Image modifyAlpha removeColor ratio (SIMD on/off) 0.567x (43.3% faster)

@shai-almog

shai-almog commented Oct 27, 2026 •

Copy link
Copy Markdown
Collaborator Author

Compared 189 screenshots: 189 matched.
✅ Native iOS Metal screenshot tests passed.

Benchmark Results

  • VM Translation Time: 0 seconds
  • Compilation Time: 3335 seconds

Build and Run Timing

Metric Duration
Simulator Boot 58000 ms
Simulator Boot (Run) 2000 ms
App Install 26000 ms
App Launch 11000 ms
Test Execution 553000 ms

Detailed Performance Metrics

Metric Duration
SIMD kernel backend SSE2 (x64) / NEON (arm64) native kernels
SIMD int-add (64K x300) java 477ms / native 6ms = 79.5x speedup
SIMD float-mul (64K x300) java 137ms / native 8ms = 17.1x speedup
SIMD kernel correctness PASS (native result == scalar reference)
Base64 payload size 8192 bytes
Base64 benchmark iterations 6000
Base64 SIMD byte path active (NEON-accelerated)
Base64 CN1 encode 114.000 ms
Base64 CN1 decode 88.000 ms
Base64 native encode 2743.000 ms
Base64 encode ratio (CN1/native) 0.042x (95.8% faster)
Base64 native decode 2713.000 ms
Base64 decode ratio (CN1/native) 0.032x (96.8% faster)
Base64 SIMD encode 193.000 ms
Base64 encode ratio (SIMD/CN1) 1.693x (69.3% slower)
Base64 SIMD decode 223.000 ms
Base64 decode ratio (SIMD/CN1) 2.534x (153.4% slower)
Base64 encode ratio (SIMD/native) 0.070x (93.0% faster)
Base64 decode ratio (SIMD/native) 0.082x (91.8% faster)
Image encode benchmark iterations 100
Image createMask (SIMD off) 9.000 ms
Image createMask (SIMD on) 14.000 ms
Image createMask ratio (SIMD on/off) 1.556x (55.6% slower)
Image applyMask (SIMD off) 1076.000 ms
Image applyMask (SIMD on) 554.000 ms
Image applyMask ratio (SIMD on/off) 0.515x (48.5% faster)
Image modifyAlpha (SIMD off) 584.000 ms
Image modifyAlpha (SIMD on) 98.000 ms
Image modifyAlpha ratio (SIMD on/off) 0.168x (83.2% faster)
Image modifyAlpha removeColor (SIMD off) 776.000 ms
Image modifyAlpha removeColor (SIMD on) 102.000 ms
Image modifyAlpha removeColor ratio (SIMD on/off) 0.131x (86.9% faster)

@shai-almog

shai-almog commented Oct 27, 2026 •

Copy link
Copy Markdown
Collaborator Author

Compared 249 screenshots: 249 matched.
✅ Native Apple Watch (watchOS, Core Graphics) screenshot tests passed.

shai-almog and others added 2 commits October 27, 2026 08:08
…6080)

Under a landscape lock UIKit keeps the interface landscape with the
portrait-only modal up, so the covered view is never told portrait.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
)

The simulator cannot stage case 3 (the stand-in modal never makes the covered
view disagree with the scene), so the landscape test case is dropped and the
correction is logged instead, to name the stale publication on a device.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@shai-almog

shai-almog commented Oct 28, 2026 •

Copy link
Copy Markdown
Collaborator Author

Compared 189 screenshots: 189 matched.
✅ Native iOS Metal screenshot tests passed.

Benchmark Results

  • VM Translation Time: 0 seconds
  • Compilation Time: 2166 seconds

Build and Run Timing

Metric Duration
Simulator Boot 90000 ms
Simulator Boot (Run) 2000 ms
App Install 17000 ms
App Launch 10000 ms
Test Execution 522000 ms

Detailed Performance Metrics

Metric Duration
SIMD kernel backend SSE2 (x64) / NEON (arm64) native kernels
SIMD int-add (64K x300) java 80ms / native 4ms = 20.0x speedup
SIMD float-mul (64K x300) java 76ms / native 3ms = 25.3x speedup
SIMD kernel correctness PASS (native result == scalar reference)
Base64 payload size 8192 bytes
Base64 benchmark iterations 6000
Base64 SIMD byte path active (NEON-accelerated)
Base64 CN1 encode 72.000 ms
Base64 CN1 decode 112.000 ms
Base64 native encode 2165.000 ms
Base64 encode ratio (CN1/native) 0.033x (96.7% faster)
Base64 native decode 1273.000 ms
Base64 decode ratio (CN1/native) 0.088x (91.2% faster)
Base64 SIMD encode 80.000 ms
Base64 encode ratio (SIMD/CN1) 1.111x (11.1% slower)
Base64 SIMD decode 78.000 ms
Base64 decode ratio (SIMD/CN1) 0.696x (30.4% faster)
Base64 encode ratio (SIMD/native) 0.037x (96.3% faster)
Base64 decode ratio (SIMD/native) 0.061x (93.9% faster)
Image encode benchmark iterations 100
Image createMask (SIMD off) 6.000 ms
Image createMask (SIMD on) 2.000 ms
Image createMask ratio (SIMD on/off) 0.333x (66.7% faster)
Image applyMask (SIMD off) 257.000 ms
Image applyMask (SIMD on) 69.000 ms
Image applyMask ratio (SIMD on/off) 0.268x (73.2% faster)
Image modifyAlpha (SIMD off) 57.000 ms
Image modifyAlpha (SIMD on) 119.000 ms
Image modifyAlpha ratio (SIMD on/off) 2.088x (108.8% slower)
Image modifyAlpha removeColor (SIMD off) 152.000 ms
Image modifyAlpha removeColor (SIMD on) 357.000 ms
Image modifyAlpha removeColor ratio (SIMD on/off) 2.349x (134.9% slower)

@shai-almog
shai-almog merged commit 238ef3f into master Oct 28, 2026
51 checks passed
@shai-almog
shai-almog deleted the ios-camera-landscape-6080 branch October 28, 2026 08:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant