On 10/22/2013 01:43 AM, Mike wrote:
Hello,
This is my first post here, but I've been warching D for the past year
and a half.
I currently build small bare-metal (no OS) ARM Cortex-M1/4 embedded
system. These targets typically have less than 1MB of program memory,
less than 512KB of embedded RAM, and run at less than 200MHz. I
currently use C, C++, and assembly, but would very much like to add D to
this mix, hopefully removing the Cs completely.
Language Questions:
1. Is D or WiLL D be a suitable language for these targets?
I have successfully ran D programs on a STM32F1 and STM32F4.
2. Is the D runtime required for bare metal programming? In other words,
if the D runtime has not yet been ported to these targets, how far can
one get using just D the language?
The compiler needs quite some runtime support functions for certain
language features (GC, AA, array ops...). D is targeting OS based
machines currently. A lot of druntime (GC, threads, time) is not
a good fit for bare-metal targets.
You can still benefit a lot from the nicer C parts of D.
Compiler Questions:
1. What is the status of LDC & GDC for these bare-metal targets? Is DMD
even in this game?
DMD is not, GDC and AFAIK LDC can be compiled for ARM targets,
it's somewhat involved though.
2. If not ARM Cortex, can any of the D compilers target Intel's Quark
processor?
Don't know about that.
Finally, if D is not yet ready for these targets, but would like to be,
what work remains to be done to get it there.
https://bitbucket.org/timosi/minlibd