Uploaded image for project: 'Swift'
  1. Swift
  2. SR-4726

Clang abort in Function Pass Manager on aarch64

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Medium
    • Resolution: Unresolved
    • Component/s: Compiler
    • Labels:
    • Environment:

      Description

      I'm trying to build Swift 3.1.1 on a Scaleway ARMv8 instance. This goes surprisingly far, but eventually clang fails on libdispatch/src/source.c.

      clang-4.0: /swiftsrc/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp:7065: void llvm::SelectionDAGBuilder::visitInlineAsm(llvm::ImmutableCallSite): Assertion `ConstraintID != InlineAsm::Constraint_Unknown && "Failed to convert memory constraint code to constraint id."' failed.
      #0 0x00000000014da90c llvm::sys::PrintStackTrace(llvm::raw_ostream&) (/swiftsrc/build/buildbot_linux/llvm-linux-aarch64/bin/clang-4.0+0x14da90c)
      Stack dump:
      0.	Program arguments: /swiftsrc/build/buildbot_linux/llvm-linux-aarch64/bin/clang-4.0 -cc1 -triple aarch64-unknown-linux-gnu -emit-obj -disable-free -main-file-name source.c -mrelocation-model pic -pic-level 2 -mthread-model posix -mdisable-fp-elim -fmath-errno -masm-verbose -mconstructor-aliases -fuse-init-array -target-cpu generic -target-feature +neon -target-abi aapcs -momit-leaf-frame-pointer -dwarf-column-info -debugger-tuning=gdb -coverage-file /swiftsrc/build/buildbot_linux/libdispatch-linux-aarch64/src/.libs/source.o -resource-dir /swiftsrc/build/buildbot_linux/llvm-linux-aarch64/bin/../lib/clang/4.0.0 -isystem /usr/include/bsd -D HAVE_CONFIG_H -I . -I /swiftsrc/swift-corelibs-libdispatch/src -I ../config -I .. -I /swiftsrc/swift-corelibs-libdispatch -I /swiftsrc/swift-corelibs-libdispatch/private -I /swiftsrc/swift-corelibs-libdispatch/libpwq/include -D LIBBSD_OVERLAY -I /swiftsrc/swift-corelibs-libdispatch/src/BlocksRuntime -D PIC -internal-isystem /usr/local/include -internal-isystem /swiftsrc/build/buildbot_linux/llvm-linux-aarch64/bin/../lib/clang/4.0.0/include -internal-externc-isystem /usr/include/aarch64-linux-gnu -internal-externc-isystem /include -internal-externc-isystem /usr/include -O2 -Wall -fdebug-compilation-dir /swiftsrc/build/buildbot_linux/libdispatch-linux-aarch64/src -ferror-limit 19 -fmessage-length 132 -fvisibility hidden -fallow-half-arguments-and-returns -fblocks -fno-signed-char -fobjc-runtime=gcc -fdiagnostics-show-option -fcolor-diagnostics -vectorize-loops -vectorize-slp -o .libs/source.o -x c /swiftsrc/swift-corelibs-libdispatch/src/source.c 
      1.	<eof> parser at end of file
      2.	Code generation
      3.	Running pass 'Function Pass Manager' on module '/swiftsrc/swift-corelibs-libdispatch/src/source.c'.
      4.	Running pass 'AArch64 Instruction Selection' on function '@_dispatch_mgr_invoke'
      clang-4.0: error: unable to execute command: Aborted
      clang-4.0: error: clang frontend command failed due to signal (use -v to see invocation)
      clang version 4.0.0 (https://github.com/apple/swift-clang.git f38438fc0161d13f2deb8b1cfb201af562692364) (https://github.com/apple/swift-llvm.git 9cb6a3ccee03e78b4258d2af093de0891b003d60)
      Target: aarch64-unknown-linux-gnu
      Thread model: posix
      InstalledDir: /swiftsrc/build/buildbot_linux/llvm-linux-aarch64/bin
      clang-4.0: note: diagnostic msg: PLEASE submit a bug report to http://llvm.org/bugs/ and include the crash backtrace, preprocessed source, and associated run script.
      

        Attachments

        1. build-log.txt
          11 kB
        2. source-5b2bda.c
          2.28 MB
        3. source-5b2bda.sh
          3 kB

          Activity

            People

            Assignee:
            Unassigned
            Reporter:
            helge Helge Heß
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated: