[swift-users] libswift frontend ios

Ramakrishna Mallireddy ramakrishna.malli at gmail.com
Mon Mar 28 15:04:12 CDT 2016


Thanks for pointing my misunderstanding of alignment issue.

Now I have import path issues.

When generating llvm ir from source does llvm require the import lib's too
or just the import headers will be enough i.e I am assuming the linker
phase come's after llvm-ir generation so header's are sufficient for
generating llvm-ir or am I assuming it all wrong.

My input source file has one import statement of UIKit and my target triple
is x86_64
I haven't set the sdk path*[ *no sdk available on the iOS device *]*, but
copied all *.swiftmodule & *.swiftdoc files along with the *.dylib for the
target-tripple that I am trying to generate the llvm-ir for. I receive
an *<unknown>:0:
error: cannot load underlying module for 'CoreGraphics'*

The header path is set correctly and it indeed evaluated the import UIKit
properly and CoreGraphics.swiftmodule is there in along with
UIKit.swiftmodule.

*.modules are there under swift/iPhonesimulator/x86_64/
*.dylib are there under the swift/iPhonesimulator/
the swift path is properly set.

What am I missing here.

Thanks
Ramakrishna


On Thu, Mar 24, 2016 at 10:43 PM, Joe Groff <jgroff at apple.com> wrote:

>
> > On Mar 24, 2016, at 6:12 AM, Ramakrishna Mallireddy <
> ramakrishna.malli at gmail.com> wrote:
> >
> > This may be due to the fact my native OSX being an 64bit architecture.
> Only a 64bit compiler build work on it properly.
> > To make simulator i386 build works properly it may required native 32bit
> architecture OSX.
> >
> > Please correct me if I am wrong.
>
> That shouldn't be a problem. The assertion indicates that the compiler
> thought that ProtocolDecl or ProtocolConformance are not sufficiently
> aligned to hold the tag bit necessary for llvm::PointerUnion in its low
> bits. You might be able to work around this by annotating ProtocolDecl and
> ProtocolConformance as explicitly having `alignof(8)`.
>
> -Joe
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-users/attachments/20160329/9ebe04a2/attachment.html>


More information about the swift-users mailing list