Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LDC for armel #2887

Closed
giulioz opened this issue Oct 28, 2018 · 4 comments
Closed

LDC for armel #2887

giulioz opened this issue Oct 28, 2018 · 4 comments

Comments

@giulioz
Copy link

giulioz commented Oct 28, 2018

Is there any support for armel (arm9) architecture?
I compiled the whole compiler and runtime from source but it yields SIGILL:

Program received signal SIGILL, Illegal instruction. 0x0047f0d8 in _D4core6atomic__T8atomicOpVAyaa2_2b3dTkTiZQzFNaNbNiNeKOkiZk (val=@0xb6980884: 0, mod=1) at /usr/lib/ldc/x86_64-linux-gnu/include/d/core/atomic.d:321

Can you give me any help?

@kinke
Copy link
Member

kinke commented Oct 28, 2018

That line is a call to an LLVM intrinsic, so you'll most likely need to play around with the -mcpu command-line option.
Judging by your import path, you built the compiler on an x64 machine and are cross-compiling to ARM? Which command-line flags are you using?

@kinke
Copy link
Member

kinke commented Oct 28, 2018

Ah, ARM9 is of course ARMv5 (sarcasm off); there are some issues with that, most notably the required usage of -mattr=+strict-align and patching a few places in druntime, like the enum here. See #2058.

On a positive note, I was able to run a pretty sofisticated vibe.d app on my controller (with the tweaks for eh and for some missing functions on my glibc version).

@giulioz
Copy link
Author

giulioz commented Oct 28, 2018

Yes, since i'm compiling for the Lego EV3 i'm using arm-linux-gnueabi-gcc to compile from x86_64 on Docker. I will try rebuilding with the patches you linked, thank you for now.

@kinke
Copy link
Member

kinke commented Mar 5, 2019

Closing, nothing actionable here.

@kinke kinke closed this as completed Mar 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants