Xcode 14.3 - is launching apps in x86_64 no longer allowed?

I saw that launching Xcode 14.3 in Rosetta is no longer allowed. Does this include running app processes in x86_64 arch?

I have some snapshot tests that normally run in x86_64 arch (via setting EXCLUDED_ARCHS = "arm64". When I try this in Xcode 14.3, I get this crash when the test app host tries to launch in the simulator:

-------------------------------------
Translated Report (Full Report Below)
-------------------------------------

Incident Identifier: 985D648C-E527-49B0-9D4D-4A5DCF2557F0
CrashReporter Key:   176AA0CA-224F-6BF0-5B11-C89E6E4E9523
Hardware Model:      MacBookPro18,1
Process:             Foo [98923]
Path:                /Users/USER/Library/Developer/CoreSimulator/Devices/CF27FF91-AFEA-453C-A622-FA2FCD644E9A/data/Containers/Bundle/Application/FECE196B-6964-44AB-B63B-C7B7A2DBCCEA/Foo.app/Foo
Identifier:          com.foo.bar
Version:             1.0.0 (1)
Code Type:           X86-64 (Native)
Role:                Foreground
Parent Process:      Exited process [98950]
Coalition:           com.apple.CoreSimulator.SimDevice.CF27FF91-AFEA-453C-A622-FA2FCD644E9A [12254]
Responsible Process: SimulatorTrampoline [12603]

Date/Time:           2023-02-21 19:23:01.2964 -0800
Launch Time:         2023-02-21 19:22:43.1879 -0800
OS Version:          macOS 13.2.1 (22D68)
Release Type:        User
Report Version:      104

Exception Type:  EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Triggered by Thread:  0

Thread 0 Crashed:
0   ???                           	       0x10572d9a8 ???
1   ???                           	       0x1057ec714 ???
2   dyld                          	       0x2059d9d07 abort_with_payload_wrapper_internal + 82
3   dyld                          	       0x2059d9d39 abort_with_payload + 9
4   dyld_sim                      	       0x10dd8b8eb abort_with_payload + 26
5   dyld_sim                      	       0x10dd4b4eb dyld4::halt(char const*) + 375
6   dyld_sim                      	       0x10dd47c1c dyld4::prepare(dyld4::APIs&, dyld3::MachOAnalyzer const*) + 3070
7   dyld_sim                      	       0x10dd47e42 _dyld_sim_prepare + 379
8   dyld                          	       0x20595eff1 dyld4::prepareSim(dyld4::RuntimeState&, char const*) + 1551
9   dyld                          	       0x20595d5be dyld4::prepare(dyld4::APIs&, dyld3::MachOAnalyzer const*) + 244
10  dyld                          	       0x20595d281 start + 2289

Thread 1:: com.apple.rosetta.exceptionserver
0   ???                           	    0x7ff7ffc3e614 ???
1   ???                           	    0x7ff7ffc56a50 ???

Thread 2:: com.apple.rosetta.debugserver
0   ???                           	    0x7ff7ffc3e614 ???
1   ???                           	    0x7ff7ffc56a50 ???


Thread 0 crashed with X86 Thread State (64-bit):
  rax: 0x0000000000000006  rbx: 0x00000000000001eb  rcx: 0x0000000000000004  rdx: 0x000000030ea288c0
  rdi: 0x000000201cf81da8  rsi: 0x000000011cf6e5b0  rbp: 0x0000000000000000  rsp: 0x000000030ea284c0
   r8: 0x000000030ea284c0   r9: 0x0000000000000000  r10: 0x00000000000001eb  r11: 0xfefefefefefefeff
  r12: 0x00000000000001eb  r13: 0x000000030ea288c0  r14: 0x0000000000000004  r15: 0x0000000000000006
  rip: <unavailable>       rfl: 0x0000000000000283
 tmp0: 0xffffffffffffffff tmp1: 0x000000010572d97c tmp2: 0x00000002059d9d07


Binary Images:
               0x0 - 0xffffffffffffffff ??? (*) <00000000-0000-0000-0000-000000000000> ???
       0x205957000 -        0x2059eefff dyld (*) <bba77709-6cad-3592-ab03-09d0f7b8610e> /usr/lib/dyld
       0x10dd46000 -        0x10dd93fff dyld_sim (*) <7276a69b-e3b9-3f23-957f-061350a501b4> /Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 15.5.simruntime/Contents/Resources/RuntimeRoot/usr/lib/dyld_sim

Error Formulating Crash Report:
dyld_process_snapshot_get_shared_cache failed

EOF

 launching Xcode 14.3 in Rosetta is no longer allowed. Does this include running app processes in x86_64 arch?

They actually added an “official” way to do that, via new menu command Product → Destination → Destination Architectures → Show Rosetta Destinations or Show Both.

If you set your destination as a Rosetta simulator explicitly this way, does it still crash?

@Scott - very cool new setting -t hanks for the info! Unfortunately, when removing my EXCLUDED_ARCH setting and running to a Rosetta destination with the new UI, it crashes with this:

-------------------------------------
Translated Report (Full Report Below)
-------------------------------------

Process:               Xcode [94954]
Path:                  /Applications/Xcode14.3-beta.app/Contents/MacOS/Xcode
Identifier:            com.apple.dt.Xcode
Version:               14.3 (21801.3)
Build Info:            IDEFrameworks-21801003000000000~2 (14E5197f)
Code Type:             ARM-64 (Native)
Parent Process:        launchd [1]
User ID:               503

Date/Time:             2023-02-24 11:22:48.8882 -0800
OS Version:            macOS 13.2.1 (22D68)
Report Version:        12
Anonymous UUID:        176AA0CA-224F-6BF0-5B11-C89E6E4E9523

Sleep/Wake UUID:       78A1DAC5-9F17-43F3-8DA3-9084F8D27ABB

Time Awake Since Boot: 84000 seconds
Time Since Wake:       10945 seconds

System Integrity Protection: enabled

Crashed Thread:        0  Dispatch queue: com.apple.main-thread

Exception Type:        EXC_CRASH (SIGABRT)
Exception Codes:       0x0000000000000000, 0x0000000000000000

Application Specific Information:
abort() called
com.apple.main-thread


Application Specific Signatures:
0

Kernel Triage:
VM - pmap_enter retried due to resource shortage
VM - pmap_enter retried due to resource shortage
VM - pmap_enter retried due to resource shortage
VM - pmap_enter retried due to resource shortage
VM - pmap_enter retried due to resource shortage


Thread 0 Crashed::  Dispatch queue: com.apple.main-thread
0   libsystem_kernel.dylib        	       0x18750e868 __pthread_kill + 8
1   libsystem_pthread.dylib       	       0x187545cec pthread_kill + 288
2   libsystem_c.dylib             	       0x18747e2c8 abort + 180
3   IDEKit                        	       0x10798f648 +[IDEAssertionHandler _handleAssertionWithLogString:assertionSignature:assertionReason:extraBacktrace:] + 980
4   IDEKit                        	       0x10798fa88 -[IDEAssertionHandler handleFailureInMethod:object:fileName:lineNumber:assertionSignature:messageFormat:arguments:] + 872
5   DVTFoundation                 	       0x104323198 _DVTAssertionHandler + 424
6   DVTFoundation                 	       0x104323318 _DVTAssertionFailureHandler + 196
7   IDEFoundation                 	       0x108f8dca8 -[DVTDevice(IDEFoundationAdditions) isTranslationSupportInstalledForArchitecture:] + 140
8   IDEFoundation                 	       0x108f8de1c -[DVTDevice(IDEFoundationAdditions) supportsRunningExecutableAtPath:usingArchitecture:error:] + 208
9   IDEFoundation                 	       0x10911254c __23-[IDERunOperation main]_block_invoke.18 + 56
10  DVTFoundation                 	       0x104367338 __DVT_CALLING_CLIENT_BLOCK__ + 16
11  DVTFoundation                 	       0x104367b54 __DVTSyncPerformBlock_block_invoke + 68
12  CoreFoundation                	       0x1876255a0 __CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__ + 28
13  CoreFoundation                	       0x1876254b4 __CFRunLoopDoBlocks + 368
14  CoreFoundation                	       0x187624960 __CFRunLoopRun + 2452
15  CoreFoundation                	       0x187623878 CFRunLoopRunSpecific + 612
16  HIToolbox                     	       0x190d03fa0 RunCurrentEventLoopInMode + 292
17  HIToolbox                     	       0x190d03c30 ReceiveNextEventCommon + 236
18  HIToolbox                     	       0x190d03b2c _BlockUntilNextEventMatchingListInModeWithFilter + 72
19  AppKit                        	       0x18a8a984c _DPSNextEvent + 632
20  AppKit                        	       0x18a8a89dc -[NSApplication(NSEvent) _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 728
21  DVTKit                        	       0x1032c6404 -[DVTApplication nextEventMatchingMask:untilDate:inMode:dequeue:] + 300
22  AppKit                        	       0x18a89ce0c -[NSApplication run] + 464
23  DVTKit                        	       0x1032c560c -[DVTApplication run] + 60
24  AppKit                        	       0x18a874250 NSApplicationMain + 880
25  dyld                          	       0x18721be50 start + 2544

...

Crashing Xcode itself is definitely worth submitting a Feedback report. And of course let the crash reporter submit the crash report to Apple when it offers to do so.

I'm seeing the same crash as @dangwu when creating just a simple project via Xcode template and then trying to run it in Xcode Beta 14.3 beta 2 (14E5207e) with a Rosetta simulator. I opened a Feedback report but encourage others to do the same if running into the same issue.

Hi Michael,

You can still run the rosetta simulators on Xcode 14.3. It's now built-in in the Xcode. I wrote a quick tutorial. https://armen-mkrtchian.medium.com/run-rosetta-simulator-on-xcode-14-3-381d341364ee

Does anyone know how to force rosetta using CLI? Like running on react-native you can do react-native run-ios --simulator "iPad (10th generation)" but if I do something like react-native run-ios --simulator "iPad (10th generation) (Rosetta, 16.4)" it doesn't work

I've raised an issue in the cli repo regarding this. Please upvote /comment to increase visibility. See here: https://github.com/react-native-community/cli/issues/1918

Xcode 14.3 - is launching apps in x86_64 no longer allowed?
 
 
Q