<div dir="ltr">
<p class=""><span class="">I compiled clang, llvm and swift static libraries for iOS.</span></p><p class=""><span class="">I created default single-page view ios swift project, added frontend_main.cpp and an objective c wrapper with a single method that calls frontend_main. I added the bridge header and when run on iOS simulator i got EXC_BAD_ACCESS.</span></p><p class="">I have not even called any methods of the libraries yet.</p><p class="">The control never reached the AppDelegate.</p><p class="">below is the<b> backtrace</b>:</p><p class="">* thread #1: tid = 0xc25cb, 0x0d1ffddb libsystem_pthread.dylib`_pthread_rwlock_check_init + 11, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS (code=1, address=0x0)</p><p class=""> * frame #0: 0x0d1ffddb libsystem_pthread.dylib`_pthread_rwlock_check_init + 11</p><p class=""> frame #1: 0x0d1ffaf0 libsystem_pthread.dylib`_pthread_rwlock_lock + 25</p><p class=""> frame #2: 0x0d204fcc libsystem_pthread.dylib`pthread_rwlock_wrlock$UNIX2003 + 23</p><p class=""> frame #3: 0x1210ef13 libLLVMContainer.dylib`llvm::sys::RWMutexImpl::writer_acquire() + 19</p><p class=""> frame #4: 0x12069b12 libLLVMContainer.dylib`llvm::PassRegistry::addRegistrationListener(llvm::PassRegistrationListener*) + 34</p><p class=""> frame #5: 0x1206567e libLLVMContainer.dylib`llvm::PassNameParser::PassNameParser() + 78</p><p class=""> frame #6: 0x1205cad3 libLLVMContainer.dylib`_GLOBAL__sub_I_LegacyPassManager.cpp + 1299</p><p class=""> frame #7: 0x0991b20f</p><p class=""> frame #8: 0x0991b368</p><p class=""> frame #9: 0x09916a01</p><p class=""> frame #10: 0x09916994</p><p class=""> frame #11: 0x09916994</p><p class=""> frame #12: 0x09916994</p><p class=""> frame #13: 0x09916994</p><p class=""> frame #14: 0x09916994</p><p class=""> frame #15: 0x09916994</p><p class=""> frame #16: 0x09916994</p><p class=""> frame #17: 0x09916994</p><p class=""> frame #18: 0x09915d54</p><p class=""> frame #19: 0x09915de3</p><p class=""> frame #20: 0x0990bc50</p><p class=""> frame #21: 0x0990f2c7</p><p class=""> frame #22: 0x0990b1f9</p><p class=""> frame #23: 0x8fe61118 dyld`dyld::useSimulatorDyld(int, macho_header const*, char const*, int, char const**, char const**, char const**, unsigned long*) + 1053</p><p class=""> frame #24: 0x8fe601f2 dyld`dyld::_main(macho_header const*, unsigned long, int, char const**, char const**, char const**, unsigned long*) + 202</p><p class=""> frame #25: 0x8fe5c232 dyld`dyldbootstrap::start(macho_header const*, int, char const**, long, macho_header const*, unsigned long*) + 428</p><p class=""> frame #26: 0x8fe5c047 dyld`_dyld_start + 71</p><p class="">(lldb) </p><p class="">Does anyone have any idea what gone wrong.</p><p class=""><br></p><p class="">Thanks</p><p class="">Ramakrishna</p>
<p class=""><span class=""><br></span></p></div>