Re: [computer-go] Re: compiler optimizations

2007-11-22 Thread Raymond Wold
Dave Dyer wrote: Arguments about the quality of compiler optimizations vs. hand coding are pointless, because programmers optimize programs in ways that compilers are (correctly) forbidden to do; by changing the algorithm. I've heard of no such law or rule. There are several compilers or

[computer-go] Re: compiler optimizations

2007-11-22 Thread Dave Dyer
Languages like SQL and Prolog don't specify algorithms, they describe the desired result. I agree that the quality of compilers that turn these specifications into algorithms can improve dramatically, and that this kind of specification is a great way to increase the productivity of programming

[computer-go] Re: compiler optimizations

2007-11-22 Thread Dave Dyer
Languages like SQL and Prolog don't specify algorithms, they describe the desired result. I agree that the quality of compilers that turn these specifications into algorithms can improve dramatically, and that this kind of specification is a great way to increase the productivity of programming

Re: [computer-go] Re: compiler optimizations

2007-11-22 Thread Don Dailey
Dave Dyer wrote: Languages like SQL and Prolog don't specify algorithms, they describe the desired result. I agree that the quality of compilers that turn these specifications into algorithms can improve dramatically, and that this kind of specification is a great way to increase the

Re: [computer-go] Re: compiler optimizations

2007-11-22 Thread Moi de Quoi
On Thu, 2007-11-22 at 10:10 -0800, Dave Dyer wrote: Getting back to go In my dreams I could write select groups where safetyalpha and sizebeta and color=black That is not that hard to implement, given a proper definition of safety. Subqueries are left as an exercise to the

Re: [computer-go] Re: compiler optimizations

2007-11-22 Thread Raymond Wold
Dave Dyer wrote: Languages like SQL and Prolog don't specify algorithms, they describe the desired result. What's the difference? The two are very much intermingled when you get to high-level optimizations. I agree that the quality of compilers that turn these specifications into

Re: [computer-go] Re: compiler optimizations

2007-11-22 Thread Stefan Nobis
Dave Dyer [EMAIL PROTECTED] writes: Languages like SQL and Prolog don't specify algorithms, they describe the desired result. Take a look as Haskell -- it's a very high level language but functional, so you are describing algorithms in it. Yet the compiler has so much knowledge (because of a

[computer-go] Re: compiler optimizations

2007-11-21 Thread Dave Dyer
Arguments about the quality of compiler optimizations vs. hand coding are pointless, because programmers optimize programs in ways that compilers are (correctly) forbidden to do; by changing the algorithm. For example, if I happen to know x will always be an integer from 0 to 359, I can

Re: [computer-go] Re: compiler optimizations

2007-11-21 Thread Benjamin Teuber
Why should a super-sophisticated compiler with algebraic type inference not be able to do this one day? On Nov 22, 2007 12:36 AM, Dave Dyer [EMAIL PROTECTED] wrote: Arguments about the quality of compiler optimizations vs. hand coding are pointless, because programmers optimize programs in

Re: [computer-go] Re: compiler optimizations

2007-11-21 Thread wing
Because many optimizations take exponential or worse time to figure out if they apply. This means that the sun would explode before your compile would finish. Yes, compilers will get more sophisticated over time. No, they will not replace any algorithms or data structures. Michael Wing Why

Re: [computer-go] Re: compiler optimizations

2007-11-21 Thread Darren Cook
Arguments about the quality of compiler optimizations vs. hand coding are pointless, because programmers optimize programs in ways that compilers are (correctly) forbidden to do; by changing the algorithm. For example, if I happen to know x will always be an integer from 0 to 359, I can

Re: [computer-go] Re: compiler optimizations

2007-11-21 Thread Nick Apperson
I agree with you 100%. You embody the methodology behind C++. The only problem I can see with adding something like that to C++ is that many times the compiler can't determine at compile time if a value is violating the contract. If the feature were added to C++, the programmer would have to be