Android/ARM: fixing exception-handling

Dan Olson via digitalmars-d-ldc digitalmars-d-ldc at puremagic.com
Tue Jun 16 23:50:50 PDT 2015


"David Nadlinger" <code at klickverbot.at> writes:

> On Tuesday, 16 June 2015 at 23:07:45 UTC, Joakim wrote:
>> David, what remains to be done for ARM support, if you know anything
>> more specific than simply finding and fixing the remaining stuff
>> that doesn't work?
>
> Unfortunately, I don't know of anything more specific than the couple
> EH-related of test case failures on Linux/EABI.
>
> It has been quite some while since I last worked on LDC/ARM to be
> honest; most of my ARM work is getting embedded stuff done with C++14
> these days. Maybe Dan knows of some other codegen/math-related issues
> still to be solved?

There might be some clues in the iOS branch for ldc/eh.d even though it
is dealing with SjLj style exceptions and landing pads are interpreted
differently.  It has few version variations but uses much of the same
code.  It seems to work ok during the unittests.  I haven't encountered
any weirdness since I spent some late nights with a debugger a year ago.

https://github.com/smolt/druntime/blob/ios/src/ldc/eh.d

Diff with tag v0.15.1 to see where I changed stuff.  All my published
ios branches are currently based on 0.15.1 and using LLVM 3.5.1.

Joakim, what branch of LDC are you basing your Android stuff on?

I can publish to github ios merges with 0.15.2-beta and 0.16.0 (branch
merge-2.067), but I don't think there is any additional help there with
regard to EH, even though ldc/eh.d did change for druntime ldc branch.

As far as codegen problems - there is nothing related to EH that I can
think of.  The optimizer occassionally gets some alignment wrong with
neon instructions in LLVM 3.5.1, but that does not show up as a EH
problem.  Currently neon is disabled when building optimized libs.

If you haven't created a gen/abi-arm.{h,cpp}, you will need to as the
default has a few problems on ARM, but still not related to EH.  If you
are on LLVM 3.5.1, try the one on the ios branch named abi-ios.{h,cpp}.
There are additional abi-ios changes for 0.15.2 because D variadic
functions handling changed.
-- 
Dan


More information about the digitalmars-d-ldc mailing list