Skip to content

Kokoro ANE: libBNNS vadd_fp16_sme SIGSEGV reproduces on iOS 27.0 on the Metal-free route (#843's default); MPSGraph abort unchanged on 27 beta 8 #889

Description

@rfrmd

Summary

Two data points from the field that bear on #843 / #844, both captured from devices, both on Kokoro ANE (the laishere chain via FluidAudio):

  1. The libBNNS vadd_fp16_sme SIGSEGV reproduces on iOS 27.0 — on the exact route iPadOS 27.0 beta: default routing's GPU stages (noise/tail) abort in MPSGraph under CoreML — #667 family, new OS (FB24243070) #843 ships as the OS‑27 default (aneTailCpu: noise + tail on .cpuOnly, RNN stages on ANE). iPadOS 27.0 beta: default routing's GPU stages (noise/tail) abort in MPSGraph under CoreML — #667 family, new OS (FB24243070) #843 describes that route as "fine there" and the BNNS segfault as "a 26.x‑line bug (Kokoro ANE: libBNNS EXC_BAD_ACCESS is time/environment-gated — same binary flips 40/40 PASS to 0/15 CRASH same day (controlled evidence; follow-up to #328/#587) #817/Kokoro ANE: BnnsCpuInferenceOperation SIGSEGV still reproduces on iOS 26.6 (follow-up to #817) #844)". It is not 26.x‑only.
  2. The MPSGraph abort (iPadOS 27.0 beta: default routing's GPU stages (noise/tail) abort in MPSGraph under CoreML — #667 family, new OS (FB24243070) #843) is unchanged on iOS 27 beta 8 (24A5430a) — re‑tested 2026‑09‑04 with the GPU route deliberately re‑armed.

Together: on the 27 line, by evidence, neither route survives — Metal aborts, and the BNNS fallback the Metal‑free route relies on segfaults intermittently, exactly as #817's title says ("time/environment‑gated — same binary flips 40/40 PASS to 0/15 CRASH"). Our BNNS crash came 54 minutes into a plain foreground listen; a short validation run would not see it.

1. BNNS SIGSEGV on iOS 27.0 — the Metal‑free route

Device iPhone18,1 (iPhone 17 Pro, A19 Pro — SME‑class silicon, same class as #844's 17 Pro Max)
OS iPhone OS 27.0 (24A5418b)
App SchriftOhr 0.9.1 (460) (FluidAudio 0.15.5)
When 2026-08-24 20:16:27.0283 -0500 — ~54 min into a foreground listen
Routing noise = .cpuOnly, tail = .cpuOnly, all other stages .cpuAndNeuralEngine — i.e. what 0.15.6 now ships as aneTailCpu
Exception EXC_BAD_ACCESS (SIGSEGV) — KERN_INVALID_ADDRESS at 0x0000000158d3c000
Triggered by Thread 8
0  libBNNS.dylib  0x00000002640f0c74 void vadd_fp16_sme_internal<(BNNSActivationFunction)0>(_Float16*, _Float16 const*, _Float16 const*, long long) + 420 (:-1)
1  libBNNS.dylib  0x00000002640f0aa8 void bnns_vadd_fp16_sme2p1<(BNNSActivationFunction)0>(_Float16*, _Float16 const*, _Float16 const*, unsigned long) + 52 (:-1)
2  libBNNS.dylib  0x0000000263bc3fd4 invocation function for block in int bnns::graph::execute_typed_binary_forwards<_Float16, _Float16, _Float16>(void (*)(_Float16*, _Float16 const*, _Float16 const*, unsigned long), void*, void const... + 372 (:-1)
3  libdispatch.dylib  0x00000001ce06afd8 _dispatch_client_callout2 + 16 (:-1)
4  libdispatch.dylib  0x00000001ce065d7c _dispatch_apply_invoke3 + 172 (:-1)
5  libdispatch.dylib  0x00000001ce06afc0 _dispatch_client_callout + 16 (:-1)
6  libdispatch.dylib  0x00000001ce053b60 _dispatch_once_callout + 32 (:-1)
7  libdispatch.dylib  0x00000001ce065130 _dispatch_once_f + 24 (:-1)
8  libdispatch.dylib  0x00000001ce065130 _dispatch_apply_invoke2 + 120 (:-1)

No app frame on the stack — the SIGSEGV is inside Apple's SME fp16 vector kernel, reached from bnns::graph::execute_typed_binary_forwards<_Float16> on a dispatch_apply worker: Core ML's own scheduler dispatching a boundary op to CPU/BNNS. Same family as #817 (26.5, iPhone 17e) and #844 (26.6, 17 Pro Max): 26.5, 26.6 and 27.0 all reproduce it on SME‑class chips.

2. MPSGraph abort still present on iOS 27 beta 8

Device iPad16,2 (iPad mini, A17 Pro)
OS iPhone OS 27.0 (24A5430a)
App SchriftOhr 0.9.5 (531)
Signal 6 (SIGABRT), exceptionType 10
Routing the normal ladder with the GPU stages on .cpuAndGPU, re‑armed on purpose to test the seed

Innermost frames (MetricKit callStackTree, deepest first):

libsystem_pthread.dylib
libsystem_pthread.dylib
MetalPerformanceShadersGraph
MetalPerformanceShadersGraph
libc++.1.dylib
libsystem_pthread.dylib
libsystem_kernel.dylib
libsystem_pthread.dylib

Same signature as #843 / FB24243070: assertion → abort() inside MetalPerformanceShadersGraph under Core ML, on a dispatch worker, no app frames. Minutes in.

What we do about it (for anyone shipping on 27)

We gate the neural voice off entirely on OS 27 and fall back to system voices, because a SIGSEGV or SIGABRT inside Apple's library cannot be caught in‑process and no fallback ladder runs. The per‑route re‑tests are behind self‑clearing tester switches (a crash while armed disarms it on next launch). Happy to share the full .ips and the MetricKit crash JSON for either crash — say the word and I'll attach them.

Filed with Apple: FB24243070 (Metal abort). The BNNS crash on 27 is attached to the same Feedback.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions