Re: Trying to use gdb on OS X
- Posted by mattlewis (admin) Jun 11, 2013
- 3051 views
jaygade said...
While this should be tested on ARM to make sure, I am still currently of the opinion that casting double to long long (or int64_t) prior to casting to unsigned long (or whatever portable type) is the correct thing to do for all platforms, and that eliminating an #ifdef and eliminating a separate function to convert doubles to int is the best solution.
In cases where that's big enough, yes it will work. The problem comes when you have a value that's too large for the target type. I hadn't even considered stuff like SSE instructions.
Matt