https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80498
--- Comment #2 from jonne <gcc at zutt dot org> --- Thanks Martin. I tried to run it with gdb. With gdb, I seem to get an unknown signal immediately. (running gdb as root at the moment, because of an issue with code-signing) # gdb ./a.out GNU gdb (GDB) 7.12.1 Copyright (C) 2017 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-apple-darwin16.3.0". Type "show configuration" for configuration details. For bug reporting instructions, please see: <http://www.gnu.org/software/gdb/bugs/>. Find the GDB manual and other documentation resources online at: <http://www.gnu.org/software/gdb/documentation/>. For help, type "help". Type "apropos word" to search for commands related to "word"... Reading symbols from ./a.out...Reading symbols from /private/tmp/a.out.dSYM/Contents/Resources/DWARF/a.out...done. done. (gdb) run Starting program: /private/tmp/a.out During startup program terminated with signal ?, Unknown signal. (gdb) bt No stack. I'll see if I can find more information about this. I also have lldb, which produces the following (after I hit ctrl-c after about 10 seconds): @laptop906 tmp $ lldb -- ./a.out (lldb) target create "./a.out" Current executable set to './a.out' (x86_64). (lldb) run Process 21192 launched: './a.out' (x86_64) Process 21192 stopped * thread #1, queue = 'com.apple.main-thread', stop reason = signal SIGSTOP frame #0: 0x00007fffc8342bc9 libsystem_platform.dylib`_platform_bzero$VARIANT$Haswell + 41 libsystem_platform.dylib`_platform_bzero$VARIANT$Haswell: -> 0x7fffc8342bc9 <+41>: rep 0x7fffc8342bca <+42>: stosb %al, %es:(%rdi) 0x7fffc8342bcb <+43>: movq %rdx, %rax 0x7fffc8342bce <+46>: popq %rbp (lldb) bt * thread #1, queue = 'com.apple.main-thread', stop reason = signal SIGSTOP * frame #0: 0x00007fffc8342bc9 libsystem_platform.dylib`_platform_bzero$VARIANT$Haswell + 41 frame #1: 0x0000000100479300 libasan.3.dylib`__asan_register_globals + 1248 frame #2: 0x0000000100046fbb a.out`_GLOBAL__sub_I_00099_1_m.cpp + 31 frame #3: 0x0000000100165a1b dyld`ImageLoaderMachO::doModInitFunctions(ImageLoader::LinkContext const&) + 385 frame #4: 0x0000000100165c1e dyld`ImageLoaderMachO::doInitialization(ImageLoader::LinkContext const&) + 40 frame #5: 0x00000001001614aa dyld`ImageLoader::recursiveInitialization(ImageLoader::LinkContext const&, unsigned int, char const*, ImageLoader::InitializerTimingList&, ImageLoader::UninitedUpwards&) + 338 frame #6: 0x0000000100160524 dyld`ImageLoader::processInitializers(ImageLoader::LinkContext const&, unsigned int, ImageLoader::InitializerTimingList&, ImageLoader::UninitedUpwards&) + 138 frame #7: 0x00000001001605b9 dyld`ImageLoader::runInitializers(ImageLoader::LinkContext const&, ImageLoader::InitializerTimingList&) + 75 frame #8: 0x000000010015247a dyld`dyld::initializeMainExecutable() + 195 frame #9: 0x00000001001568c6 dyld`dyld::_main(macho_header const*, unsigned long, int, char const**, char const**, char const**, unsigned long*) + 3966 frame #10: 0x0000000100151249 dyld`dyldbootstrap::start(macho_header const*, int, char const**, long, macho_header const*, unsigned long*) + 470 frame #11: 0x0000000100151036 dyld`_dyld_start + 54 (lldb) quit Quitting LLDB will kill one or more processes. Do you really want to proceed: [Y/n] y