February 18, 2015
Jacob Carlborg <doob@me.com> writes:

> On 2015-02-17 19:10, Dan Olson wrote:
>
>> iOS has a stub tlv_initializer() so nothing gets done automatically. I had to change threadLocalVariables.c to include working tlv_initializer for __arm__.
>
> You can't implement that stub because it's in dyld? Or is it possible to override?

My thought would be that libdyld.dylib is statically linked to its __arm__ stubbed tlv_initializer so my modified version can't override.

See

http://www.opensource.apple.com/source/dyld/dyld-353.2.1/src/dyldAPIsInLibSystem.cpp

and

http://www.opensource.apple.com/source/dyld/dyld-353.2.1/src/threadLocalVariables.c

February 21, 2015
Hi Dan!

On Wednesday, 4 February 2015 at 16:37:05 UTC, Dan Olson wrote:
> Just a quick note.  I started again on LDC for iOS a month ago (new years resolution!).  I bogged down in floating point and optimizer problems.  I think I understand the major issues and have gotten all of phobos unittests to pass with optimizer disabled except for some math unittests that are written for 80-bit floats and some that are off by LSB.
>
> This weekend I'll cleanup the math fixes and put up a new repo on https://github.com/smolt that helps glue it all together.
> --
> Dan

I looked at your sources. I think you should turn the softfp changes and the iOS-ABI into pull requests for ldc.

Regards,
Kai
February 22, 2015
"Kai Nacke" <kai@redstar.de> writes:

> I looked at your sources. I think you should turn the softfp changes and the iOS-ABI into pull requests for ldc.
>
> Regards,
> Kai

The softfp change ok, the iOS abi, not yet.  There is at least a C calling convention problem to fix first.  A small struct (e.g. struct A {int x;}) should be returned in r0 instead of as an sret.

I still owe you the longdouble changes I needed to get it to compile in my env.  I am not using it in my ios branch right now, but I plan to swap to it now that I have a unittest pass/fail baseline.
--
Dan
February 24, 2015
On Wednesday, 18 February 2015 at 07:10:18 UTC, Dan Olson wrote:
> "Joakim" <dlang@joakim.fea.st> writes:
>> I couldn't get most of the phobos unit tests to run on a linux/ARM
>> hard-float board, Cubieboard2.  I'm guessing the issue is hard-float
>> compatibility: I need to try softfp out and make sure.  Almost all the
>> druntime tests passed on the armhf system though.
>
> What kinds of errors are you getting?  Are they all float related?  If
> the linux C libs are using -float-abi=hard, then softfp probably won't
> help.

It's mostly segfaults, several modules segfault when their tests are run.  I'm guessing this is because of some ABI issue.  I believe most Android/ARM systems are softfp, so testing on linux/ARM-hardfp is probably worthless anyway.  I need to try softfp on a softfp system and see what happens.

> If you do decide to look at softfp, I have this commit to get the D
> versions correct:
>
> https://github.com/smolt/ldc/commit/5a19080
>
> Without that change, -float-abi=softfp sets version ARM_Soft instead of
> ARM_SoftFP so std.math ends up incorrectly taking non-FPU paths.

OK, will look at that when I get the tests not to segfault. :)
February 26, 2015
"Dan Olson" <zans4cans@yahoo.com> writes:
>
> https://github.com/smolt/ldc-iphone-dev
>
> This pulls all the pieces together as submodules.  I still need to cleanup and add my sample Xcode apps and add some docs, but this should be enough to build LDC iPhoneOS cross compiler and Phobos. Someone with OS X should see if my build works for them.

I added two Xcode projects to https://github.com/smolt/ldc-iphone-dev.

- helloD to simple demos of D on iOS device
- unittester to run druntime/phobos unittests

I also add more words to the repo README that I hope better explains things.
--
Dan
1 2 3
Next ›   Last »