re PR rtl-optimization/9325 (wrong conversion of constants: (int)(float)(int) (INT_MAX))
PR optimization/9325 * gcc.c-torture/execute/20031003-1.c: Remove non-portable tests for overflowing floating point to integer conversion during RTL simplification. From-SVN: r72467
This commit is contained in:
parent
91de08c377
commit
e157d7777a
2 changed files with 7 additions and 19 deletions
|
@ -1,3 +1,10 @@
|
|||
2003-10-14 Roger Sayle <roger@eyesopen.com>
|
||||
|
||||
PR optimization/9325
|
||||
* gcc.c-torture/execute/20031003-1.c: Remove non-portable tests
|
||||
for overflowing floating point to integer conversion during RTL
|
||||
simplification.
|
||||
|
||||
2003-10-13 Ziemowit Laski <zlaski@apple.com>
|
||||
|
||||
* objc/execute/_cmd.m: Fix typo.
|
||||
|
|
|
@ -12,31 +12,12 @@ int f2()
|
|||
return (int)(float)(2147483647);
|
||||
}
|
||||
|
||||
int f3()
|
||||
{
|
||||
float a = 2147483648.0f;
|
||||
return (int)a;
|
||||
}
|
||||
|
||||
int f4()
|
||||
{
|
||||
int a = 2147483647;
|
||||
float b = (float)a;
|
||||
return (int)b;
|
||||
}
|
||||
|
||||
int main()
|
||||
{
|
||||
if (f1() != 2147483647)
|
||||
abort ();
|
||||
if (f2() != 2147483647)
|
||||
abort ();
|
||||
#ifdef __OPTIMIZE__
|
||||
if (f3() != 2147483647)
|
||||
abort ();
|
||||
if (f4() != 2147483647)
|
||||
abort ();
|
||||
#endif
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue