multiply by negative value generates incorrect extrema
|
|
Bugzilla Link |
1072 |
Created on |
Apr 28, 2013 22:04 |
Resolution |
FIXED |
Resolved on |
Apr 29, 2013 14:37 |
Version |
svn |
OS |
Linux |
Architecture |
PC |
Extended Description
This returns the wrong result if compiled with -doawlf, due to garbage
extrema being generated for the mul():
int[*] id(int[*] y)
{ return(y);
}
int main()
{
S = id( 42);
S = _max_SxS_( S, 3);
N4 = _sub_SxS_( 0, 4);
S2 = _mul_SxS_( N4, S); /* Mul by Negative constant */
N12 = _sub_SxS_( 0, 12);
z2 = _le_SxS_( S2, N12);
z2 = _toi_S_( z2);
z = _sub_SxS_( z2, 1);
return( z);
}
sac2c -V
sac2c v1.00-beta (Haggis And Apple)
product rev 18121 linux-gnu_x86_64
(Sat Apr 27 17:22:46 EDT 2013 by sac)
Fix is coming.