What can cause EXC_BAD_INSTRUCTION in dyldbootstrap?

I have porting a larger project on the iPhone in the simulator, but trying to run it on an iPad leads to EXC_BAD_INSTRUCTION in the dyld code with the following backtrace:

 #0 0x2fe01088 in __dyld__ZN13dyldbootstrapL30randomizeExecutableLoadAddressEPK12macho_headerPPKcPm () #1 0x2fe06a72 in __dyld__ZN4dyld5_mainEPK12macho_headermiPPKcS5_S5_ () #2 0x2fe06d3c in __dyld__ZN9__gnu_cxx13new_allocatorIPFPKc17dyld_image_statesjPK15dyld_image_infoEE8allocateEmPKv () #3 0x2fe0b398 in __dyld__ZN9__gnu_cxx13new_allocatorISt13_Rb_tree_nodeIPK11ImageLoaderEE8allocateEmPKv () #4 0x2fe05fa6 in __dyld__ZN4dyld11removeImageEP11ImageLoader () #5 0x2fe06506 in __dyld__ZN4dyld5_mainEPK12macho_headermiPPKcS5_S5_ () #6 0x2fe0128c in __dyld__ZN13dyldbootstrapL30randomizeExecutableLoadAddressEPK12macho_headerPPKcPm () #7 0x2fe01060 in __dyld_branch_to_lookupDyldFunction () 

This is the building for the iPhone Device 3.2 with the architecture of armv6 armv7 and happens before main() ever introduced.

Currently I do not understand how to find the reason for this, any ideas?

+4
source share
1 answer

I had a similar problem with ipad when it was compiled initially in a more modern version of xcode than mine.

It worked in the simulator, but when the debugging on the device crashed badly. However, when the device was turned off, it worked. The solution for me was updating xcode.

If you have the same problem, try running it on the device without a debugger (install, enable it to minimize, then disconnect and restart it).

+2
source

Source: https://habr.com/ru/post/1335856/


All Articles