[dmd-internals] default dmd target == debdmd?
Don Clugston
dclugston at googlemail.com
Fri Aug 27 13:46:05 PDT 2010
On 27 August 2010 22:34, Steve Schveighoffer <schveiguy at yahoo.com> wrote:
>
>
>
>
> ----- Original Message ----
>> From: Don Clugston <dclugston at googlemail.com>
>> To: Discuss the internals of DMD <dmd-internals at puremagic.com>
>> Sent: Fri, August 27, 2010 4:27:13 PM
>> Subject: Re: [dmd-internals] default dmd target == debdmd?
>>
>> On 27 August 2010 17:28, Steve Schveighoffer <schveiguy at yahoo.com> wrote:
>> >
>> >
>> >
>> >
>> > ----- Original Message ----
>> >> From: Don Clugston <dclugston at googlemail.com>
>> >> To: Discuss the internals of DMD <dmd-internals at puremagic.com>
>> >> Sent: Fri, August 27, 2010 11:21:20 AM
>> >> Subject: Re: [dmd-internals] default dmd target == debdmd?
>> >>
>> >> On 27 August 2010 17:15, Steve Schveighoffer <schveiguy at yahoo.com> wrote:
>> >> > I was in the process of doing some windows phobos development, so I
>>decided
>> >>to
>> >> > start using the latest compiler from trunk. But when I started
> building
>> >> > druntime and phobos, I was getting these printouts:
>> >> >
>> >> > Max # of fixups = 0
>> >> > Max # of fixups = 1
>> >> > Max # of fixups = 4
>> >> > Max # of fixups = 1
>> >> > ...
>> >> >
>> >> > I thought WTF? Well, it turns out the default build of dmd if you just
>>do
>> >>make
>> >> > -f win32.mak is debdmd, not dmd.
>> >> >
>> >> > Is there a good reason for this? If not, can we change the default
>>target
>> >>to
>> >> > dmd?
>> >>
>> >> It's so you can debug the compiler.Pretty much the only time you want
>> >> the release version is when making an official release.
>> >
>> > Or when you want to utilize unreleased fixes...
>>
>> I do not think we should encourage that. Nobody should really be doing
>> that unless they are helping debug/test the compiler. If the fixes are
>> that important, we should be doing a release.
>>
>> Note that even when developing Phobos, you shouldn't ordinarily be
>> checking in code which depends on the latest compiler bugfix. Every
>> time that has happened so far, a compiler beta release has been made.
>> It's not reasonable to expect everyone working on or testing Phobos,
>> to build the compiler themselves.
>
> I understand this point of view, and I agree. I won't use the trunk version in
> the future. I still don't think the default should be debug mode, it's very
> confusing. I can envision people building a released version of the source
> (i.e. from a downloaded tarball) and expecting it to be a release version
> without having to specify different arguments. How much will this happen? Not
> sure, but why provide the source if you don't want people to compile it...
>
> -Steve
It's often happened that someone hits a compiler segfault. By
compiling a debug version, and running:
windbg dmd foo.d
they can find which line it's segfaulting on. This has been quite
useful in the past; even people with absolutely no knowledge of C++
have been able to provide helpful info about bugs.
Hopefully, though, most of the segfaults are gone, now <g>.
More information about the dmd-internals
mailing list