www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.ldc - LDC 1.0.0-alpha1 has been released! Please help testing!

reply Kai Nacke <kai redstar.de> writes:
Hi everyone!

The LDC team moves fast to a major milestone: we're aiming for a 
1.0.0 release!

On behalf of the LDC team I am proud to announce the new 
1.0.0-alpha1 release!
It is based on the 2.069.2 front-end and supports LLVM 3.5-3.8.

This is the first ALPHA version of the release. The main purpose 
is to find the remaining bug. Thus please help testing!

The Travis-CI shows all green but there are still issues left:

- The build system does not use a D compiler for linking. This 
can result in link failures due to missing libraries.
- LDC on Win64 is not yet able to compile itself.
- A bug with vararg handling in version 0.17.0 prevents linking 
of LDC on ARM
- Other architectures and operating systems must be still 
evaluated

Again, we need to help to test this alpha release! Every feedback 
is welcomed!

Be sure to read the change log at the GitHub release page which 
also has the package download links:
https://github.com/ldc-developers/ldc/releases/tag/v1.0.0-alpha1

MD5 checksums for the release packages:

accd5cf2222cb633ce059f047ed96ccb ldc-1.0.0-alpha1-src.tar.gz
b69dca5b9c39fda00bcb853d1b966412 
ldc2-1.0.0-alpha1-linux-x86.tar.gz
35a4aea5b1ca4f9b46bbd728ca05e7ad 
ldc2-1.0.0-alpha1-linux-x86.tar.xz
a15f4c903c9636c6f2c4b41a7539a716 
ldc2-1.0.0-alpha1-linux-x86_64.tar.gz
4eaa7f0ed273a06abb80f66e82a081ca 
ldc2-1.0.0-alpha1-linux-x86_64.tar.xz
8c29a88a39790eaf2aeb2fb7bf11ffb7 
ldc2-1.0.0-alpha1-osx-x86_64.tar.xz
cea6d778edc4464397e93770ce5952e8 ldc2-1.0.0-alpha1-win64-msvc.zip

Regarding the binaries:
The Linux binaries are built on Ubuntu 12.04 LTS with gcc 4.8.x, 
ldc2 0.17.0 and LLVM 3.7.1. They work on Ubuntu 12.04 LTS (or 
later) without installing additional software.

The OS X binaries are built with LLVM 3.6.2 on OS X 10.10.

The Win64 MSVC version is built with VS2015 (update 1) using dmd 
2.069.2 and LLVM 3.7.1 in release mode. The distribution now 
contains a precompiled libcurl 7.46.0 from 
http://d.darktech.org/libcurl.html. For any other VisualStudio 
version you need to rebuild the library.
You find the build script here: 
https://github.com/ldc-developers/ldc-scripts/blob/master/ldc2-win64/RELEASE.proj

Please be sure to report any bugs at 
https://github.com/ldc-developers/ldc/issues, and feel free to 
drop by at the digitalmars.D.ldc forums 
(http://forum.dlang.org/group/digitalmars.D.ldc) for any 
questions or comments.

Thanks to everybody involved in making this happen!

Regards,
Kai
Feb 26 2016
next sibling parent reply David Nadlinger via digitalmars-d-ldc <digitalmars-d-ldc puremagic.com> writes:
Hi all,

On 26 Feb 2016, at 22:12, Kai Nacke via digitalmars-d-ldc wrote:
 The OS X binaries are built with LLVM 3.6.2 on OS X 10.10.
The OS X binaries are actually built on OS X 10.11, with the MACOSX_DEPLOYMENT_TARGET being set to 10.7. The latter is new (previously it was not being set at all) and should fix linker warnings when using the pre-built binaries on earlier OS versions. — David
Feb 26 2016
parent Jon D <jond noreply.com> writes:
On Friday, 26 February 2016 at 21:46:00 UTC, David Nadlinger 
wrote:
 Hi all,

 On 26 Feb 2016, at 22:12, Kai Nacke via digitalmars-d-ldc wrote:
 The OS X binaries are built with LLVM 3.6.2 on OS X 10.10.
The OS X binaries are actually built on OS X 10.11, with the MACOSX_DEPLOYMENT_TARGET being set to 10.7. The latter is new (previously it was not being set at all) and should fix linker warnings when using the pre-built binaries on earlier OS versions. — David
Thanks, nice to have the warnings disappear. The 1.0 alpha works fine on my simple test programs on both Mac OSX and Linux (64-bit). --Jon
Feb 27 2016
prev sibling next sibling parent reply Guillaume Piolat <name.lastname gmail.com> writes:
On Friday, 26 February 2016 at 21:12:43 UTC, Kai Nacke wrote:
 accd5cf2222cb633ce059f047ed96ccb ldc-1.0.0-alpha1-src.tar.gz
 b69dca5b9c39fda00bcb853d1b966412 
 ldc2-1.0.0-alpha1-linux-x86.tar.gz
 35a4aea5b1ca4f9b46bbd728ca05e7ad 
 ldc2-1.0.0-alpha1-linux-x86.tar.xz
 a15f4c903c9636c6f2c4b41a7539a716 
 ldc2-1.0.0-alpha1-linux-x86_64.tar.gz
 4eaa7f0ed273a06abb80f66e82a081ca 
 ldc2-1.0.0-alpha1-linux-x86_64.tar.xz
 8c29a88a39790eaf2aeb2fb7bf11ffb7 
 ldc2-1.0.0-alpha1-osx-x86_64.tar.xz
 cea6d778edc4464397e93770ce5952e8 
 ldc2-1.0.0-alpha1-win64-msvc.zip
I don't see win32 binaries, does that mean ldc2-1.0.0-alpha1-win64-msvc.zip can build both 32-bit and 64-bit Windows programs now?
Feb 26 2016
parent Kai Nacke <kai redstar.de> writes:
On Friday, 26 February 2016 at 22:48:42 UTC, Guillaume Piolat 
wrote:
 On Friday, 26 February 2016 at 21:12:43 UTC, Kai Nacke wrote:
 accd5cf2222cb633ce059f047ed96ccb ldc-1.0.0-alpha1-src.tar.gz
 b69dca5b9c39fda00bcb853d1b966412 
 ldc2-1.0.0-alpha1-linux-x86.tar.gz
 35a4aea5b1ca4f9b46bbd728ca05e7ad 
 ldc2-1.0.0-alpha1-linux-x86.tar.xz
 a15f4c903c9636c6f2c4b41a7539a716 
 ldc2-1.0.0-alpha1-linux-x86_64.tar.gz
 4eaa7f0ed273a06abb80f66e82a081ca 
 ldc2-1.0.0-alpha1-linux-x86_64.tar.xz
 8c29a88a39790eaf2aeb2fb7bf11ffb7 
 ldc2-1.0.0-alpha1-osx-x86_64.tar.xz
 cea6d778edc4464397e93770ce5952e8 
 ldc2-1.0.0-alpha1-win64-msvc.zip
I don't see win32 binaries, does that mean ldc2-1.0.0-alpha1-win64-msvc.zip can build both 32-bit and 64-bit Windows programs now?
Hi Guillaume it just means that I did not take the extra effort to integrate the ALPHA Win32 code into the ALPHA version of the release. First we need to make the bootstrap process smooth before integrating more stuff. But nice to see the interest in the compiler! Regards, Kai
Feb 28 2016
prev sibling next sibling parent Adrian Matoga <dlang.spam matoga.info> writes:
On Friday, 26 February 2016 at 21:12:43 UTC, Kai Nacke wrote:
 The LDC team moves fast to a major milestone: we're aiming for 
 a 1.0.0 release!

 On behalf of the LDC team I am proud to announce the new 
 1.0.0-alpha1 release!
 It is based on the 2.069.2 front-end and supports LLVM 3.5-3.8.
 (...)
This is an excellent news, finally a fairly recent front-end with decent optimization! The alpha works great so far for all my projects. BTW I was pleased to notice that LDC produces the smallest binaries of all D compilers, especially when templates are in heavy use.
Feb 26 2016
prev sibling next sibling parent reply Jacob Carlborg <doob me.com> writes:
On 2016-02-26 22:12, Kai Nacke wrote:
 Hi everyone!

 The LDC team moves fast to a major milestone: we're aiming for a 1.0.0
 release!

 On behalf of the LDC team I am proud to announce the new 1.0.0-alpha1
 release!
 It is based on the 2.069.2 front-end and supports LLVM 3.5-3.8.
I would be a big disappointment if the Objective-C support is not included. -- /Jacob Carlborg
Feb 27 2016
parent reply Dan Olson <gorox comcast.net> writes:
Jacob Carlborg <doob me.com> writes:

 On 2016-02-26 22:12, Kai Nacke wrote:
 Hi everyone!

 The LDC team moves fast to a major milestone: we're aiming for a 1.0.0
 release!

 On behalf of the LDC team I am proud to announce the new 1.0.0-alpha1
 release!
 It is based on the 2.069.2 front-end and supports LLVM 3.5-3.8.
I would be a big disappointment if the Objective-C support is not included.
Agree. I think I can take a look and at least figure how much work there is.
Feb 27 2016
parent reply Dan Olson <gorox comcast.net> writes:
Dan Olson <gorox comcast.net> writes:

 Jacob Carlborg <doob me.com> writes:

 On 2016-02-26 22:12, Kai Nacke wrote:
 Hi everyone!

 The LDC team moves fast to a major milestone: we're aiming for a 1.0.0
 release!

 On behalf of the LDC team I am proud to announce the new 1.0.0-alpha1
 release!
 It is based on the 2.069.2 front-end and supports LLVM 3.5-3.8.
I would be a big disappointment if the Objective-C support is not included.
Agree. I think I can take a look and at least figure how much work there is.
Well, it isn't pretty but can pass the dmd testsuite for objc. I'll organize it a litte better, get a pull going to show work in progress. ... compilable/objc_interface.d -g () ... fail_compilation/objc_interface1.d -g () ... fail_compilation/objc_interface2.d -g () ... fail_compilation/objc_interface3.d -g () ... runnable/objc_call.d -L-framework -LFoundation -g () ... runnable/objc_objc_msgSend.d -L-framework -LFoundation -g () ... runnable/objc_self_test.d -L-framework -LFoundation -g ()
Feb 28 2016
parent reply Jacob Carlborg <doob me.com> writes:
On 2016-02-28 09:46, Dan Olson wrote:

 Well, it isn't pretty but can pass the dmd testsuite for objc.  I'll
 organize it a litte better, get a pull going to show work in progress.
That was quick :). Please let me know when you have a pull request available, I can help with the code review. Would be inserting to enable all tests in objc_objc_msgSend.d and see if they work in LDC. -- /Jacob Carlborg
Feb 28 2016
parent reply Dan Olson <gorox comcast.net> writes:
Jacob Carlborg <doob me.com> writes:

 On 2016-02-28 09:46, Dan Olson wrote:

 Well, it isn't pretty but can pass the dmd testsuite for objc.  I'll
 organize it a litte better, get a pull going to show work in progress.
That was quick :). Please let me know when you have a pull request available, I can help with the code review. Would be inserting to enable all tests in objc_objc_msgSend.d and see if they work in LDC.
I uncommented lines in main (I think that is what you mean) to this: void main() { test_stret(); test_fp2ret(); test_fpret(); test_float32(); test_double64(); } And it works. I was unsure if the fp2ret and C++/D complex types would work, but for this test they do.
Feb 28 2016
next sibling parent reply Temtaime <temtaime gmail.com> writes:
Hi Kai !
I wonder if there plans to convert driver and gen parts into d 
too, to get rid of c++ code.
Thanks for a reply.
Feb 28 2016
parent Johan Engelen <j j.nl> writes:
On Sunday, 28 February 2016 at 21:54:22 UTC, Temtaime wrote:
 I wonder if there plans to convert driver and gen parts into d 
 too, to get rid of c++ code.
Some code has already been converted to D (out of necessity / ease of transitioning to DDMD). At least for code that does not interface with LLVM, it'd be nice to convert it to D (imho). cheers, Johan
Feb 28 2016
prev sibling parent reply Jacob Carlborg <doob me.com> writes:
On 2016-02-28 20:33, Dan Olson wrote:

 I uncommented lines in main (I think that is what you mean) to this:

 void main()
 {
      test_stret();
      test_fp2ret();
      test_fpret();
      test_float32();
      test_double64();
 }

 And it works.  I was unsure if the fp2ret and C++/D complex types would
 work, but for this test they do.
Awesome :) -- /Jacob Carlborg
Feb 28 2016
parent reply Dan Olson <gorox comcast.net> writes:
Jacob Carlborg <doob me.com> writes:

 On 2016-02-28 20:33, Dan Olson wrote:

 I uncommented lines in main (I think that is what you mean) to this:

 void main()
 {
      test_stret();
      test_fp2ret();
      test_fpret();
      test_float32();
      test_double64();
 }

 And it works.  I was unsure if the fp2ret and C++/D complex types would
 work, but for this test they do.
Awesome :)
I made https://github.com/ldc-developers/ldc/pull/1325 from my hack session last saturday. It is no where close, but at least you can see a start. Maybe we can make a branch in LDC repo for this so you and others can collaborate? -- Dan
Feb 29 2016
parent David Nadlinger via digitalmars-d-ldc <digitalmars-d-ldc puremagic.com> writes:
On 29 Feb 2016, at 18:35, Dan Olson via digitalmars-d-ldc wrote:
 I made https://github.com/ldc-developers/ldc/pull/1325 from my hack
 session last saturday. It is no where close, but at least you can see a
 start. Maybe we can make a branch in LDC repo for this so you and others
 can collaborate?
Yes, I'd say let's just create a branch in ldc-developers/ldc. — David
Feb 29 2016
prev sibling next sibling parent reply Andrea Fontana <nospam example.com> writes:
On Friday, 26 February 2016 at 21:12:43 UTC, Kai Nacke wrote:
 Again, we need to help to test this alpha release! Every 
 feedback is welcomed!
It takes me a lot to understand what's wrong in a parser code. I finally reduced code to this: size_t inc(size_t* v) { (*v)++; return 10; } size_t pos = 10; immutable tst = pos + inc(&pos); // <-- this writeln(tst); writeln(pos); The marked line was an unintended mistake inside original code. Anyway it gives different result with dmd and ldc2 1.0. I neither know if is a undefined behaviour.
Feb 29 2016
next sibling parent reply kink <noone nowhere.com> writes:
On Monday, 29 February 2016 at 11:51:31 UTC, Andrea Fontana wrote:
 It takes me a lot to understand what's wrong in a parser code.
 I finally reduced code to this:

 size_t inc(size_t* v)
 {
    (*v)++;
    return 10;
 }

 size_t pos = 10;
 	
 immutable tst = pos + inc(&pos); // <-- this
 writeln(tst);
 writeln(pos);

 The marked line was an unintended mistake inside original code.
 Anyway it gives different result with dmd and ldc2 1.0. I 
 neither know if is a undefined behaviour.
I hope LDC computes tst = 20. ;) Iirc, there were some inconsistencies wrt. this. LDC and GDC do it one way (the proper one imo), dmd another way.
Feb 29 2016
parent reply Andrea Fontana <nospam example.com> writes:
On Monday, 29 February 2016 at 13:36:59 UTC, kink wrote:
 I hope LDC computes tst = 20. ;)
 Iirc, there were some inconsistencies wrt. this. LDC and GDC do 
 it one way (the proper one imo), dmd another way.
"Proper" depends on specs. If is an undefined behaviour i think it should be defined or a warning should be triggered
Feb 29 2016
parent reply Johan Engelen <j j.nl> writes:
On Monday, 29 February 2016 at 14:47:58 UTC, Andrea Fontana wrote:
 On Monday, 29 February 2016 at 13:36:59 UTC, kink wrote:
 I hope LDC computes tst = 20. ;)
 Iirc, there were some inconsistencies wrt. this. LDC and GDC 
 do it one way (the proper one imo), dmd another way.
"Proper" depends on specs. If is an undefined behaviour i think it should be defined or a warning should be triggered
Spec: https://dlang.org/spec/expression.html#order-of-evaluation Strict left-to-right order evaluation, as the spec prescribes, would give tst=20. Is there a DMD bug report for this? I didn't test with DMD, but if tst!=20, it is a pretty severe issue.
Feb 29 2016
parent Andrea Fontana <nospam example.com> writes:
On Monday, 29 February 2016 at 15:19:19 UTC, Johan Engelen wrote:
 On Monday, 29 February 2016 at 14:47:58 UTC, Andrea Fontana 
 wrote:
 On Monday, 29 February 2016 at 13:36:59 UTC, kink wrote:
 I hope LDC computes tst = 20. ;)
 Iirc, there were some inconsistencies wrt. this. LDC and GDC 
 do it one way (the proper one imo), dmd another way.
"Proper" depends on specs. If is an undefined behaviour i think it should be defined or a warning should be triggered
Spec: https://dlang.org/spec/expression.html#order-of-evaluation Strict left-to-right order evaluation, as the spec prescribes, would give tst=20. Is there a DMD bug report for this? I didn't test with DMD, but if tst!=20, it is a pretty severe issue.
Dmd gives 20. Ldc gives 21: andrea ububocs:/tmp$ cat tmp.d import std.stdio; void main() { size_t inc(size_t* v) { (*v)++; return 10; } size_t pos = 10; immutable tst = pos + inc(&pos); // <-- this writeln(tst); writeln(pos); } andrea ububocs:/tmp$ rdmd tmp.d 20 11 andrea ububocs:/tmp$ ldc2 tmp.d && ./tmp 21 11
Feb 29 2016
prev sibling parent reply Andrea Fontana <nospam example.com> writes:
On Monday, 29 February 2016 at 11:51:31 UTC, Andrea Fontana wrote:
 On Friday, 26 February 2016 at 21:12:43 UTC, Kai Nacke wrote:
 Again, we need to help to test this alpha release! Every 
 feedback is welcomed!
It takes me a lot to understand what's wrong in a parser code.
Another problem. Reduced code: http://dpaste.dzfl.pl/33434c9ba374 This print "LEN:3" with dmd and "LEN:0" with ldc2 1.0. (using online compiler ldc 0.12, it prints LEN:3)
Feb 29 2016
next sibling parent Andrea Fontana <nospam example.com> writes:
On Monday, 29 February 2016 at 14:49:44 UTC, Andrea Fontana wrote:
 On Monday, 29 February 2016 at 11:51:31 UTC, Andrea Fontana 
 wrote:
 On Friday, 26 February 2016 at 21:12:43 UTC, Kai Nacke wrote:
 Again, we need to help to test this alpha release! Every 
 feedback is welcomed!
It takes me a lot to understand what's wrong in a parser code.
Another problem. Reduced code: http://dpaste.dzfl.pl/33434c9ba374 This print "LEN:3" with dmd and "LEN:0" with ldc2 1.0. (using online compiler ldc 0.12, it prints LEN:3)
(please notice that if "auto" is used instead of "enum", len is computed correctly)
Feb 29 2016
prev sibling parent Johan Engelen <j j.nl> writes:
On Monday, 29 February 2016 at 14:49:44 UTC, Andrea Fontana wrote:
 On Monday, 29 February 2016 at 11:51:31 UTC, Andrea Fontana 
 wrote:
 On Friday, 26 February 2016 at 21:12:43 UTC, Kai Nacke wrote:
 Again, we need to help to test this alpha release! Every 
 feedback is welcomed!
It takes me a lot to understand what's wrong in a parser code.
Another problem. Reduced code: http://dpaste.dzfl.pl/33434c9ba374 This print "LEN:3" with dmd and "LEN:0" with ldc2 1.0. (using online compiler ldc 0.12, it prints LEN:3)
Thanks for finding that bug, filed it: https://github.com/ldc-developers/ldc/issues/1324
Feb 29 2016
prev sibling next sibling parent Fynn =?UTF-8?B?U2NocsO2ZGVy?= <fynnos live.com> writes:
On Friday, 26 February 2016 at 21:12:43 UTC, Kai Nacke wrote:
 Hi everyone!

 The LDC team moves fast to a major milestone: we're aiming for 
 a 1.0.0 release!
Great news! I've tried the latest alpha on most of my projects - works like a charm on Linux64. :) On Windows there is still that nasty library extension naming issue with dub.. however, that should be fixed with dub 0.9.25. (https://github.com/D-Programming-Language/dub/issues/687) Many thanks to the ldc dev team and keep up the amazing work! Best regards, Fynn
Feb 29 2016
prev sibling parent John Colvin <john.loughran.colvin gmail.com> writes:
On Friday, 26 February 2016 at 21:12:43 UTC, Kai Nacke wrote:
 [...]
Apologies for slow movement on this release, took me a while to figure out the bootstrapping. Anyway, `brew install ldc --devel` :)
Mar 02 2016