Re: GCC optimizes integer overflow: bug or feature?

2006-12-20 Thread Matthew Woehlke
Dave Korn wrote: Particularly lock-free queues whose correct operation is critically dependent on the order in which the loads and stores are performed. No, absolutely not. Lock-free queues work by (for example) having a single producer and a single consumer, storing the queue in a circular

Re: GCC optimizes integer overflow: bug or feature?

2006-12-20 Thread Matthew Woehlke
Dave Korn wrote: On 20 December 2006 02:28, Andrew Pinski wrote: Paul Brook wrote: Pretty much all optimization will change the behavior of your program. Now that's a bit TOO strong a statement, critical optimizations like register allocation and instruction scheduling will generally not chan