[Dlang-internal] druntime: proposed changes in code organization
Denis Feklushkin
feklushkin.denis at gmail.com
Sun Dec 17 11:00:02 UTC 2023
On Sunday, 17 December 2023 at 09:37:33 UTC, Johan wrote:
>> This is a meaningless block that has formed historically
>> because it was easier and faster to implement by this way
>
> If it's meaningless, it can be removed today without your big
> file change.
*Tiny file change
>> (At first, I don't see what currently druntime is distributed
>> as ready for cross-compilation bundle. I.e., ldc2 archieve
>> isn't contains druntime binary for Windows, Linux and *BSDs
>> simultaneously, right? In this case we should not change
>> anything particularly much in the config)
>
> For cross-compilation, you don't need druntime _binaries_.
Only in dynamic linking mode, yes
> The binaries are only needed for linking. But if linking with
> druntime/phobos is needed, then LDC has a specific tool to make
> it easier for users to build druntime+phobos for a different
> target platform. And then you just specify the location of
> those binaries on the cmdline. Yes, this can be simplified for
> continued use by editing ldc2.conf, but it is not required to
> do so; nor is it needed to have a separate druntime source tree
> stored somewhere else.
For example, no one is surprised by the different Linux kernel
headers packages, coresponding to a different kernel binaries,
but derrived from one kernel source tree
Also, we can generate and provide import/ dirs for a few
platforms (what you mentioned below) simultaneously if it will be
decided as more convient
>> As for me, we don't know common this case or not.
>> "Non-standard OS" includes thousands variations of
>> hardware+software from realtime embedded software to modern
>> gaming consoles support or so on.
>>
>> But it will be simpler to be always at second place (after
>> invincible C and C++) on D support implementation timeline in
>> the event of the appearance of some new (revolutionary, of
>> course) devices or OS inventions. So I think I guess that the
>> impact of such a changes will be great.
>
> You make it sound as if it is currently impossible to implement
> druntime for linux, Apple, Windows, Solaris, OpenBSD, NetBSD,
> FreeBSD, DragonFly, Android, ... x86, x86_64, arm32, aarch64,
> riscv, ... Yet, the implementation for all these exists.
Sorry, but this is obvious demagoguery - matrix of 3 RTOSes, 3
CPU architectures and 3 LIBCs easily give us 27 platforms in this
terms
>> ldc2.conf will obtain 3-6 sections (i.e. about ~50 lines
>> total) for common platforms like Linux, Windows and *BSD. Is
>> that too expensive?
>
> Please show us the PR where you fix LDC, Dub,
What's wrong with DUB?
> and GDC for the problems you are introducing.
Sorry, but now your turn to propose solution other than these 3
listed in the previous message
More information about the Dlang-internal
mailing list