Comment #0 by dlang-bugzilla — 2012-07-11T06:40:11Z
Trying to build DFeed using DMD git head results in an OPTLINK crash.
Steps to reproduce:
1) Build DMD/Druntime/Phobos from latest Git
2) Clone https://github.com/CyberShadow/DFeed and its submodules (ae)
3) rdmd --build-only -version=WindowsXP dfeed_web.d
I'm not going to even reduce this one unless there's an indication that someone is going to look at it (it literally takes days, and my previous OPTLINK report was ignored).
Comment #1 by bugzilla — 2012-07-11T11:35:50Z
Why is this a regression? The linker hasn't changed.
Comment #2 by code — 2012-07-11T11:49:17Z
It is a regression if you consider Optlink to be just an internal component of DMD "as a whole". Yes, it technically might not be a new bug, just a bug that didn't show up before. But the point is that code which compiled fine in previous versions would break if a new release was made right now.
Comment #3 by dlang-bugzilla — 2012-08-03T16:29:46Z
The problem still exists in the DMD 2.060 release. The problem seems to be triggered by some code in a library. I can't build many of my projects with DMD 2.060 on Windows, which includes DFeed.
Comment #4 by WorksOnMyMachine — 2012-08-03T21:09:05Z
*** Issue 8501 has been marked as a duplicate of this issue. ***
Comment #5 by Sergey.Chelombitko — 2012-08-04T13:31:50Z
I'm facing the same problem with DMD 2.060 when taking address of constant from module that was compiled into static library. It seems to be directly related to number (or total size, probably) of constants in that module. Looks like having too many constants causes bad code generation.
DMD 2.059 - no such problem.
Comment #6 by bugzilla — 2012-08-04T18:54:25Z
Can someone please provide a zip with just the obj files and the linker command? I don't need the source code.
Comment #7 by dlang-bugzilla — 2012-08-04T19:09:26Z
Created attachment 1134
A troublesome object file
Running either "dmd file.obj" or "link file.obj" triggers the error.
Comment #8 by bugzilla — 2012-08-04T20:17:50Z
ok, I can duplicate the problem with this .obj file.
Comment #9 by github-bugzilla — 2012-08-04T23:07:31Z
This is definitely a regression in the compiler, where it puts out a corrupted .obj file when the align directive is used.
It's a disastrous bug, and affects all platforms.
Comment #16 by dlang-bugzilla — 2012-08-05T02:30:05Z
Confirming fix - all my projects now build correctly. Thank you!
Comment #17 by WorksOnMyMachine — 2012-08-05T23:37:10Z
I just built dmd for windows from the github sources, and all my projects compile and run properly now dropping in the fixed binary into the 2.060 installation.