February 13, 2015
On Monday, 9 February 2015 at 22:38:51 UTC, Elie Morisse wrote:
> On Monday, 9 February 2015 at 07:10:56 UTC, Suliman wrote:
>> If somebody have working Windows build, could you please share it?
>
> It would be nice to know if someone even managed to build Calypso on Windows yet :)
>

Hello Elie,

I have tried to build and use a few versions of Calypso/ldc with vs2013 and only the newest combination of LLVM and ldc from git work. llvm-3.6 with the corresponding ldc doesn't compile cleanly and neither does llvm-3.5 with ldc or Calypso with vs2013. Lastly Calypso with llvm3.7git doesn't compile, which is to be expected because of the many win64 patches that have been pushed to ldc the last couple months.

Anyways, I just thought I would let you, and any interested others, know that Calypso won't build and run properly (or at least I couldn't get it to build/run) on Win7 with vs2013 today. Maybe things would work with llvm-3.5 and mingw with clang? I don't think so, though.

I'll take a look at merging together Calypso and ldc since the split, if you like...hopefully not many conflicts. Not sure what all changed in llvm between 3.5 and 3.7, though.

Thanks,
Kelly
February 13, 2015
On Monday, 9 February 2015 at 22:38:51 UTC, Elie Morisse wrote:
> On Monday, 9 February 2015 at 07:10:56 UTC, Suliman wrote:
>> If somebody have working Windows build, could you please share it?
>
> It would be nice to know if someone even managed to build Calypso on Windows yet :)
>

Hello Elie,

Ok, I have merged in the newest LDC with Calypso from github today and built it with vs2013 on Win7 :)

There is a small diff involved in getting things to compile. The resulting ldc2 runs and builds a simple hello world program, but it fails when trying to use calypso.

I guess I've made a mistake with my patch since I am getting an assert in ASTReader with input for calypso to compile. I will look at it tomorrow and once I can get calypso to work I will push to my github fork.

Hoping for better news tomorrow,
Kelly
February 13, 2015
On Friday, 13 February 2015 at 09:49:51 UTC, Kelly wrote:
> Hello Elie,
>
> Ok, I have merged in the newest LDC with Calypso from github today and built it with vs2013 on Win7 :)
>
> There is a small diff involved in getting things to compile. The resulting ldc2 runs and builds a simple hello world program, but it fails when trying to use calypso.
>
> I guess I've made a mistake with my patch since I am getting an assert in ASTReader with input for calypso to compile. I will look at it tomorrow and once I can get calypso to work I will push to my github fork.
>
> Hoping for better news tomorrow,
> Kelly

Awesome news Kelly. Did you use rebase to merge? You've probably saved me a lot of work which I was planning to do this week-end after seeing your post about Win64 support.

There are a dozen of new commits in store since last week-end for operator support and groundwork for class values, but mapping operators trigger new bugs which prevent std::vector from instantiating so I haven't pushed them yet to master, but do you want me to push them into a new branch so you can merge with the latest?

Let me know when you make your fork available so I can check your merge and then incorporate it into master.
February 13, 2015
Anyway I'm probably fixing the last issue right now preventing std::vector from instantiating so I'm going to push the commits to master in the hour.
February 13, 2015
On Friday, 13 February 2015 at 17:54:25 UTC, Elie Morisse wrote:
> Anyway I'm probably fixing the last issue right now preventing std::vector from instantiating so I'm going to push the commits to master in the hour.

Hello Elie,

You can push to master, if you like, because we'll just have to go through and update everything either way. Hopefully not too many collisions or changes for llvm-3.7. Most of the changes I made are just slight modifications without new code, so there really shouldn't be too many collisions.

Just going to start working on this ASTReader assert. Once it works, I will push to my fork, or I might just pull in your changes and see what happens.

Thanks,
Kelly
February 14, 2015
Ok, I have pushed my changes to Calypso on github. I did this mostly for testing because I wanted to make sure things still compiled on linux.

Unfortunately, we need specific versions of llvm and clang to get things compiled as ldc2 hasn't been updated to the bleeding edge as of today. The versions I used on Win64 and Linux (didn't test OS X, but I can if needed) are:

llvm:   77b557430c1315ef50c3256cdc5e73ac54d0154e
Clang:  baa701f47b7856f848080b51bc4fbcf984d29faa

So, it took me a while to figure out that some problems weren't ours, but rather with compiling calypso (or ldc) with llvm from git today. Things build and will compile D programs as is, but fail on Win64 and Linux today for calypso specific code.

Elie, perhaps you can see what is wrong just looking at my revisions? I would suspect the problem is in astunit.cpp because ASTReader is where the error is coming from.

Anyways, take a look if you like. I would like to get this problem figured out before importing the last couple days worth of Calypso changes. I'll work on it some more in a few hours since I have a usable linux install again...WIN64 is just painful to work on for me, so I'll get things working and merged on Linux first and then move back to WIN64 :)

Thanks,
Kelly


February 15, 2015
Alirighty, Calypso builds and runs on both Linux and Win64 with that last change from today in my fork. Now when I say 'runs' on Linux, I mean it runs properly and fully (compiling and running all examples from Feb 8th)...but when I say 'runs' on Win64, I should say 'runs as far as it can' because there is an internal LLVM assert with getVTableContext "Microsoft VTableContext not yet supported"  ....  UGH! :(

Well...that is a stopper on Win64, period. I imagine this will be addressed fairly quickly because LLVM is moving extremely fast on Win64...at least I hope that will be the case!!

So that leaves us with Calypso up to the last commit on February 8th, LDC from yesterday (Feb 14th) and with LLVM-3.7/Clang using the revision hashes above.

I will make sure all this builds and works on OS X now...wish me luck :)

I will also try to pull in the latest Calypso commits from the last couple days, and merge it with LDC so that we are all up to date and synced with LDC from yesterday. Unfortunately we are stuck with bleeding edge on all this stuff, (even when LLVM-3.6 stable comes out next week) because most of the Win64 code in LLVM and LDC has been added in just the last few weeks.

Anyways, hopefully you can just spend time on the internal Calypso stuff this way Elie, and not waste time poking around with the Win64 build right now.


Thanks,
Kelly
February 15, 2015
On Sunday, 15 February 2015 at 11:48:50 UTC, Kelly wrote:
> Alirighty, Calypso builds and runs on both Linux and Win64 with that last change from today in my fork. Now when I say 'runs' on Linux, I mean it runs properly and fully (compiling and running all examples from Feb 8th)...but when I say 'runs' on Win64, I should say 'runs as far as it can' because there is an internal LLVM assert with getVTableContext "Microsoft VTableContext not yet supported"  ....  UGH! :(

It's from Calypso actually, the assert is in gen/dcxxclasses.cpp and is only triggered by D classes inheriting from C++ classes with a vtable.

If the rest works as usual on Linux you got the most important covered. I'll check your merge as soon as I'm done fixing a linking error with the std::string example the latest additions introduced, then I'll add the Microsoft VTableContext support so we could get those first working binaries for Windows users :)

However LLVM and Clang 3.6 aren't even released yet (next week), IMHO it would be wiser to stick with 3.6 and get LDC/Calypso working with 3.6 until 3.7 is more stable. Did you mean that even LDC can't be built by MSVC with LLVM 3.6 atm?
February 15, 2015
On Sunday, 15 February 2015 at 14:03:22 UTC, Elie Morisse wrote:
> It's from Calypso actually, the assert is in gen/dcxxclasses.cpp and is only triggered by D classes inheriting from C++ classes with a vtable.

Ah, sorry I see it now...there is the assert and then a backtrace
that indicates that an llvm file had the assert, but the actual
error does print from within dxxclasses.cpp before the assert
code backtrace.


> If the rest works as usual on Linux you got the most important covered. I'll check your merge as soon as I'm done fixing a linking error with the std::string example the latest additions introduced, then I'll add the Microsoft VTableContext support so we could get those first working binaries for Windows users :)

Ok, cool. Hopefully that is the only difficulty left.

> However LLVM and Clang 3.6 aren't even released yet (next week), IMHO it would be wiser to stick with 3.6 and get LDC/Calypso working with 3.6 until 3.7 is more stable. Did you mean that even LDC can't be built by MSVC with LLVM 3.6 atm?

Actually, I am not totally sure whether the current LDC will
build with 3.6 on Win64. I didn't want to try it until 3.6 is
finalized because building takes forever on Windoze!!!!!!!
Probably 10 times slower than Linux/OSX...and my Win7 machine
is a dual quad-core i7 with 12GB RAM!! A much better machine
than my Linux machines.

Anyways, once 3.6 final comes out we'll have to  see if it
works, I guess.

Thanks,
Kelly
February 16, 2015
http://forum.dlang.org/post/mbqt88$a6n$1@digitalmars.com looks like C++ class support is shifting to value types.