------- Comment #1 from rguenth at gcc dot gnu dot org 2007-03-13 22:00 ------- Confirmed. C testcase:
typedef int int32_t; int32_t round32hi(const __int128_t arg) { const int SHIFT = 96; const int mshift = 96; const __int128_t M = (~(__int128_t)0)<<mshift; const __int128_t L = (~M) + 1; const __int128_t L1 = ((__int128_t)L)>>1; const __int128_t Mlo = ((__int128_t)(~M))>>1; __int128_t vv = arg & M; if( (arg & (L1)) // hi bit of discard set && ( (arg & Mlo) // and ( any other bits of discard set || (arg & L) ) ) // or lo bit of keep set ) vv += L; return (int32_t)(vv>>SHIFT); } -- rguenth at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Ever Confirmed|0 |1 Last reconfirmed|0000-00-00 00:00:00 |2007-03-13 22:00:38 date| | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31167