August 29, 2008
On Fri, 29 Aug 2008, Steven Schveighoffer wrote:

> "Brad Roberts" wrote
> > 
> > On Thu, 28 Aug 2008, Jarrett Billingsley wrote:
> > 
> > > "Brad Roberts" <braddr@bellevue.puremagic.com> wrote in message news:alpine.DEB.1.10.0808281424310.21051@bellevue.puremagic.com...
> > > > On Thu, 28 Aug 2008, Jarrett Billingsley wrote:
> > > >
> > > >> Be warned though: the DMD backend sometimes generates buggy or >>
> > > incorrect
> > > >> code when using -inline, so be sure to test thoroughly both with and
> > > >> without
> > > >> the flag.
> > > >
> > > > Can you substantiate that with reproducable bug reports?  I'm sure >
> > > Walter
> > > > would appreciate it and place high prioirty on fixing such problems.
> > > >
> > > > Thanks,
> > > > Brad
> > > 
> > > You know, I'd love to be able to track down every heisenbug that
> > > spuriously
> > > shows up and then disappears with the smallest change in my 25000-line
> > > library when I use -inline, but I unfortunately don't have the time.
> > 
> > How about starting with _one_?
> > 
> > Without substantiation that it's actually a bug with inlining and not just a bug in your code or some other problem, these types of reports have to be considered FUD.
> > 
> > Sigh,
> > Brad
> 
> Jarrett is right.  And it is REALLY difficult to narrow these things down. The problem is with these types of bugs, one seemingly unrelated change makes the whole thing start working, so I bet a lot of these types of things go unreported (as he said, who wants to paste a 25k line program to bugzilla? It'll just get ignored).
> 
> Here is one I stumbled across while helping someone debug Tango's filesystem abstraction.  This is the smallest I could get it to (took me about 2 hours to narrow it down).  I'd really appreciate if Walter or whoever would fix this one:
> 
> http://d.puremagic.com/issues/show_bug.cgi?id=2232
> 
> -Steve

Trust me, I'm _well_ aware of the difficulty.  I'm also just as aware that saying it's buggy will never result in a bug being fixed.  Reports, such as yours, will.  Thanks for going through the effort of trimming it down to something relatively small.

I've tracked down bugs in quite a few different compilers over the years, in code bases much much larger than talked about in this thread.  It's a pain, but it's important.  I've also tracked down bugs that I coulda sworn were compiler bugs but turned out to be my own bugs.  Until you do the work, you can't ever be sure.

Ok Walter, don't make a liar outta me.. go look at Steve's report. :)

Thanks,
Brad
August 30, 2008
Brad Roberts wrote:
> Ok Walter, don't make a liar outta me.. go look at Steve's report. :)

Yes, it's a real bug, and I have it fixed now (will go out in next update). Thanks, Steven!
August 30, 2008
Walter Bright wrote:
> Brad Roberts wrote:
>> Ok Walter, don't make a liar outta me.. go look at Steve's report. :)
> 
> Yes, it's a real bug, and I have it fixed now (will go out in next
> update). Thanks, Steven!

Out of curiosity, what part of the compiler contained the bug?

Thanks,
Brad
August 30, 2008
"Walter Bright" wrote
> Brad Roberts wrote:
>> Ok Walter, don't make a liar outta me.. go look at Steve's report. :)
> 
> Yes, it's a real bug, and I have it fixed now (will go out in next update). Thanks, Steven!

No, thank you!

:D 

-Steve
August 30, 2008
Brad Roberts wrote:
> Out of curiosity, what part of the compiler contained the bug?

The back end that dealt with comma operators.
September 01, 2008
Steven Schveighoffer:
> (took me about 2 hours to narrow it down).

Take a look at the Python program in the Zeller directory here: http://examples.oreilly.com/9780596510046/examples.zip

It may do what you have done in matter of minutes, by itself. A similar but more refined tool in Python may be added to Phobos/Tango (and no, translating it into D isn't an improvement).

Bye,
bearophile
1 2 3
Next ›   Last »