On Fri, Mar 30, 2018 at 9:30 PM, bartc <b...@freeuk.com> wrote: > On 26/03/2018 16:31, Chris Angelico wrote: >> Yeah. It's so annoying that compilers work so hard to make your code >> fast, when all you want to do is measure exactly how slow it is. >> Compiler authors are stupid. > > > In some ways, yes they are. If they were in charge of Formula 1 pre-race > speed trials, all cars would complete the circuit in 0.00 seconds with an > average speed of infinity mph.
Actually, I think this would be a vast improvement to Formula 1 racing. We just declare out-of-bounds driving to be "undefined behaviour" in the C sense and permit it to crash at run-time, and then optimize the actual driving away. The net effect of the race is to burn certain amounts of fuel; the cars themselves are immaterial. A properly optimized F1 race, therefore, is a bonfire. ChrisA -- https://mail.python.org/mailman/listinfo/python-list