diff options
| author | Nick <[email protected]> | 2019-08-29 14:18:26 -0400 |
|---|---|---|
| committer | Nick <[email protected]> | 2019-08-29 14:18:26 -0400 |
| commit | 13b2410ef3f178e7adb7d7b1d634648e6be37715 (patch) | |
| tree | 491d643ccb4ba78d4b6a90b0da186dada7c94018 /src/cuda-sim/half.h | |
| parent | 403a5e7e77641f3c95bc26e29199b3a27fbf8f98 (diff) | |
Fix a few ambiguity warning
Diffstat (limited to 'src/cuda-sim/half.h')
| -rw-r--r-- | src/cuda-sim/half.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/cuda-sim/half.h b/src/cuda-sim/half.h index 8f1a8eb..9f74bb7 100644 --- a/src/cuda-sim/half.h +++ b/src/cuda-sim/half.h @@ -642,10 +642,10 @@ namespace half_float if(exp > 16)
{
if(R == std::round_toward_infinity)
- return hbits | 0x7C00 - (hbits>>15);
+ return hbits | (0x7C00 - (hbits>>15));
else if(R == std::round_toward_neg_infinity)
- return hbits | 0x7BFF + (hbits>>15);
- return hbits | 0x7BFF + (R!=std::round_toward_zero);
+ return hbits | (0x7BFF + (hbits>>15));
+ return hbits | (0x7BFF + (R!=std::round_toward_zero));
}
if(exp < -13)
value = std::ldexp(value, 24);
|
