-
Type: Bug
-
Resolution: Done
-
Priority: Minor - P4
-
Affects Version/s: None
-
Component/s: None
-
None
david.hows, in wtperf/wtperf_throttle.c, there's this code:
throttle_cfg->ops_count = (uint64_t) (float)(usecs_delta / throttle_cfg->usecs_increment) * (float)throttle_cfg->ops_per_increment; throttle_cfg->last_increment = now;
and MSVC complains:
bench\wtperf\wtperf_throttle.c(110): warning C4244: '=': conversion from 'float' to 'uint64_t', possible loss of data
I'm not sure what's going on here – all of the fields are uint64_t, not sure why we're casting everything to float, couldn't we get the same results using an integer expression?
I suspect the warning would go away if we just cast the result of the calculation to uint64_t, but I don't really understand what's going on here.
- is depended on by
-
SERVER-23682 WiredTiger changes for MongoDB 3.2.6
- Closed