aboutsummaryrefslogtreecommitdiffstats
path: root/lib/builtins/fp_trunc_impl.inc
diff options
context:
space:
mode:
Diffstat (limited to 'lib/builtins/fp_trunc_impl.inc')
-rw-r--r--lib/builtins/fp_trunc_impl.inc2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/builtins/fp_trunc_impl.inc b/lib/builtins/fp_trunc_impl.inc
index 133c8bbe5c2f..6662be7607e7 100644
--- a/lib/builtins/fp_trunc_impl.inc
+++ b/lib/builtins/fp_trunc_impl.inc
@@ -113,7 +113,7 @@ static __inline dst_t __truncXfYf2__(src_t a) {
if (shift > srcSigBits) {
absResult = 0;
} else {
- const bool sticky = significand << (srcBits - shift);
+ const bool sticky = (significand << (srcBits - shift)) != 0;
src_rep_t denormalizedSignificand = significand >> shift | sticky;
absResult = denormalizedSignificand >> (srcSigBits - dstSigBits);
const src_rep_t roundBits = denormalizedSignificand & roundMask;