Skip to content

Track B hosted tests:每個 test case teardown 在 XCTMemoryChecker autorelease drain SIGSEGV,host 逐 case 重啟、aggregate 恆 FAILED #108

Description

@kiki830621

Problem

Track B hosted tests(LogosHostedTests,app-hosted xcodebuild test)中,每個 test case 執行完在 teardown 階段 SIGSEGVXCTMemoryChecker _assertInvalidObjectsDeallocatedAfterScope:objc_autoreleasePoolPopobjc_release 打到已釋放位址(EXC_BAD_ACCESS / KERN_INVALID_ADDRESS)。host app 整個死掉,xcodebuild 以「Restarting after unexpected exit」重啟、續跑下一個 case,直到 case 燒完後回報 Executed 0 tests ... passed,aggregate 卻是 ** TEST FAILED **

實測序列(-only-testing:LogosHostedTests/RendererAdoptionTests):每次啟動執行一個 case(case 本體有跑,例如 test_metalEngagesWhenWindowAttached 有打出 [renderer] terminal Metal renderer engaged)→ teardown 崩 → 重啟 → 下一個 case。三個 case 三次崩。

Type

bug

時間軸(排除誤歸因)

Evidence

  • Crash reports:~/Library/Logs/DiagnosticReports/Logos-2026-08-01-{154608,154612,161753,161755,161758}.ips,faulting stack 一致:
    objc_release
    AutoreleasePoolPage::releaseUntil
    objc_autoreleasePoolPop
    -[XCTMemoryChecker _assertInvalidObjectsDeallocatedAfterScope:]
    -[XCTestCase assertInvalidObjectsDeallocatedAfterScope:]
    
  • 嫌疑方向:TeedLocalProcessTerminalView(SwiftTerm fork)在 test scope 結束、autorelease drain 時 over-release / 錯 thread dealloc;或 macOS 27 seed(26A5388g)× SDK 26.5 的互動。

Expected

xcodebuild test(Track B hosted)單一 launch 跑完整個 suite,無 host 崩潰、aggregate 綠燈。

Impact

Notes

  • 環境:macOS 27.0(26A5388g)、Xcode SDK macosx26.5、Apple M5 Max

Current Status

Phase: diagnosed

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions