Subject

a11e99z black80 at bk.ru
Thu Aug 8 19:39:14 UTC 2019


On Thursday, 8 August 2019 at 18:22:56 UTC, Atila Neves wrote:
> On Thursday, 8 August 2019 at 13:03:17 UTC, Exil wrote:
>> On Thursday, 8 August 2019 at 00:27:03 UTC, Walter Bright 
>> wrote:
>>> [...]
>>
>> That's simply because of the backend you chose, and ultimately 
>> it is the limiting factor now. LDC originally attempted to 
>> just implement their own frontend. Now it is basically what 
>> DMD should have been. I don't ever expect DMD to get ARM 
>> support, or cross compiling capability. The amount of work 
>> needed just isn't worth it, especially when there's a project 
>> that takes care of that for you. It seems like the decision is 
>> based on some kind of ego thing (as seems to keep being 
>> demonstrated) rather than a rational process.
>>
>> So why continue to use an old dead project in your current 
>> active project?
>
> I like the DMC++ backend, because it runs faster than the 
> alternatives. If I actually need code that runs as fast as 
> possible I'll use ldc, but that hardly ever happens. 
> Compilation takes too long as it is, I don't want to wait for 
> LLVM as well.

idk how to LDC working right now but u have many options to 
compile D modules with LLVM:
- u can generate IR for CTFE for each func in module and run it 
concurrently by JIT while generating IR for next funcs.
- u don't need optimize CTFE code with 60+ opt passes, maybe 
0-10, cuz this code only for generating final source/IR for 
module. BUT u still need do best optimization for compiling 
final/Release App/user code (non CTFE). and no need optimize 
Debug final code. need to say that Rust-ers complains on LLVM 
long compilation too.
- u can interoperate with any generated LLVM-IR modules generated 
by other langs (Swift/ObjC/C++/Rust/..) at IR level not at arch 
ABI.
- C++ 2x will add dynamic compilation that already supported by 
LLVM.
- LLVM supports exceptions, coroutines, GC, intrinsics, int128, 
modules, metadata, debuggers at IR level too.
- LLVM supports many archs: bare-metal that u wanted with 
betterC, WASM that can be useful to D as native and compatible 
(WASM wants add exceptions, GC). others users of LLVM adds 
different Passes/Filters to LLVM for parsing/optimizations and D 
can use it for free.

someday LLVM users will speed generating/compilation time.
probably D is better compatible with LLVM than with home DMC++. 
probably DMD is only one user of DMC++.
good projects for all of us such as LLVM should be supported by 
using/fixing it, not to reinventing own bicycle.
imo if D switches to LLVM, then we will all win.

PS
   I want to remind and waiting
   
https://forum.dlang.org/post/lcrsrevmvtnbqsqktsbe@forum.dlang.org


More information about the Digitalmars-d mailing list