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

Building Apple Swift on ppc64le for ubuntu 16.04

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Medium
    • Resolution: Done
    • Component/s: None
    • Labels:

      Description

      Hi,
      We are trying to build Apple Swift on ppc64le Ubuntu16.04. We built it on ppc64le using a build script at the following link:-

      https://github.com/ppc64le/build-scripts/blob/60b7885f4f0915a8671b3cfb86ddbb65f9b988a8/swift/swift41_ubuntu_16.04.sh

      With this we were able to run the 'swiftc' and REPL environment for some basic "Hello World" type of code. However for complex codes, like import Foundation, it fails(probably due to Package manager issues). When we use "import Foundation" with swift, compile error occurs as below is seen:
      (swift) import Foundation <REPL Input>:1:8: error: no such module 'Foundation' import Foundation    ^

      We are trying to build Swift 4.2(since Swift v4.1 has been released now and no further development is happening on this branch.) on Power8/LE (ppc64le) using the build-toolchain, in order to build the Swift package manager and other tools.

      We are seeing a crash which is traceable till following function in HeapObject.cpp file:
      static HeapObject *swift_retain(HeapObject *object) {   SWIFT_RT_TRACK_INVOCATION(object, swift_retain);   if (isValidPointerForNativeRetain(object)) object->refCounts.increment(1);   return object; }

      Beyond this debugging using simple print statements is tricky and the code flow is unclear. Breakpoints cannot be set since building code in debug mode is not possible as it runs out of resources and hangs.

      Any help here would be greatly appreciated. Any more outputs, errors can be shared.
      Looking forward to port Apple Swift on Ubuntu16.04.

      Regards,

      Sarvesh Tamba

        Attachments

          Activity

            People

            Assignee:
            stamba Sarvesh Tamba
            Reporter:
            stamba Sarvesh Tamba
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: