On Wednesday, 8 January 2014 at 01:27:28 UTC, Walter Bright wrote:
I've used this to port D to new platforms that have no druntime or phobos, because I need a working & tested compiler to compile those two.

But DMD doesn't support ARM in any flavor (Cortex-A nor Cortex-M - thumb), and that is the platform Dwhatever and myself are working on. Have you tried this with LDC and GDC? These compilers are quickly improving, but their current in their current state, it's a very different story when compared with C/C++.

It's not that hard. Use the -betterC switch to prevent ModuleInfo records and their dependencies from being emitted, and then you can write D code that has zero dependence on druntime or phobos.

As the creator of D and a significant author of the runtime, I think you are taking a lot for granted. I think from your perpective, it probably isn't all that hard, and certainly as I study D and the runtime, it is becoming significantly easier. But in comparison with C, Dwhatever is right... it's a bear, but I don't necessarily believe that that's bad.

Mostly, it is due to the current expectations of the LDC and GDC compiler. Currently they require a large part of the runtime, that has no hope of every being called, just to get the simplest thing to compile. GDC has made significant improvement here recently, and I hope LDC will join the trend. There's some very constructive discussion going on about this right now in other parts of this thread.

Furthtermore, the way the D Runtime is organizized, it's quite difficult to see the abstractions (if there are any). Putting some weight behind this issue (https://d.puremagic.com/issues/show_bug.cgi?id=11666) would certainly help.

The origin of this thread was really about a porting guide; an excellent idea! You can wait several months for me learn D and the runtime and I'll create one, or you and the other D Runtime authors can create one and show us just how easy it is. A simple wiki post like this (http://wiki.osdev.org/Porting_Newlib) would be an excellent start.

That being said, Thanks for D. I'm quite excited about this language.

Mike

Reply via email to