Backport GCC changes to fix integer overflow detection and enable -fwrapv by default.
[openwrt/svn-archive/archive.git] / openwrt / toolchain / gcc / 3.4.4 / 910-enable_wrapv.patch
1 --- gcc.old/gcc/toplev.c 2005-03-09 01:50:25.000000000 +0100
2 +++ gcc.dev/gcc/toplev.c 2007-01-30 12:25:29.644130224 +0100
3 @@ -991,7 +991,7 @@
4 int flag_trapv = 0;
5
6 /* Nonzero if signed arithmetic overflow should wrap around. */
7 -int flag_wrapv = 0;
8 +int flag_wrapv = 1;
9
10 /* Nonzero if subexpressions must be evaluated from left-to-right. */
11 int flag_evaluation_order = 0;