Message58566
> if you can give me a sample testcase I can bug GCC developers, this
> doesn't look good from GCC side at all. Btw from my limited C knowledge
> marking variables would volatile would prevent optimizations of them.
The example would be something like
void foo(ssize_t x)
{
if (x >= 0) {
if (x+x < 0) printf("Overflow\n");
}
}
main()
{
foo(2147483647);
}
This should print "Overflow" but won't if the evil optimization
triggers. (However you may have to tweak the example program so the
compiler can't inline the argument to foo.) |
|
| Date |
User |
Action |
Args |
| 2007-12-13 19:16:37 | gvanrossum | set | spambayes_score: 0.00427966 -> 0.00427966 recipients:
+ gvanrossum, loewis, cartman |
| 2007-12-13 19:16:37 | gvanrossum | link | issue1608 messages |
| 2007-12-13 19:16:37 | gvanrossum | create | |
|