Difference between revisions of "Compilers"

From D Wiki
Jump to: navigation, search
m
Line 1: Line 1:
 
__NOTOC__
 
__NOTOC__
 
{{:Compilers_Widget}}
 
{{:Compilers_Widget}}
 +
 +
 
There are currently 3 major D compilers:
 
There are currently 3 major D compilers:
 
<table style="width:100%;" cellspacing="10">
 
<table style="width:100%;" cellspacing="10">

Revision as of 15:03, 24 November 2012

Compilers: OverviewDMDGDCLDC


There are currently 3 major D compilers:

DMD »

Digital Mars D compiler
The formal D compiler.

GDC »

GCC D compiler
Fast and open source.

LDC »

LLVM D compiler
Fast and open source.

Which compiler should I use?

If you're a beginner DMD is the recommended choice, as it is the implementation closest to the D Language Specification. Otherwise it depends on what you need, what platforms you intend to develop for, and your personal preferences. GDC and LDC both generate substantially faster binaries than DMD.

Comparison

DMD GDC LDC
Platforms
  • Linux
  • Mac
  • FreeBSD
  • Win
  • Linux
  • Mac
  • FreeBSD
  • Win
  • Linux
  • Mac
  • FreeBSD
  • Win
Architectures
  • i386
  • amd64
  • i386
  • amd64
  • i386
  • amd64
Installation Automatic ? ?
Backend DMD GCC LLVM
License ? ? ?
Inline assembler Yes, x86 ? ?
SIMD Partial (?) Partial (?) ?

Linux specific
Object file format ? ? ?

Mac specific
Object file format ? ? ?

Windows specific
Object file format ? ? ?