search for: fpto

Displaying 5 results from an estimated 5 matches for "fpto".

Did you mean: flto
2010 Jul 12
1
[LLVMdev] Proposal for adding rounding variant of fpto?i instructions
Hi Peter, > I would appreciate comments/feedback on this proposal to extend the > fpto?i instructions to support rounding. I think this might be useful. Actually, LLVM specifies that fpto?i convert their operand into the nearest (rounding towards zero) signed integer value. Do you have other rounding modes in mind? Currently I use custom metadata to represent conversions with other r...
2010 Jul 13
0
[LLVMdev] Proposal for adding rounding variant of fpto?i instructions
On Jul 12, 2010, at 9:28 AM, Anton Lokhmotov wrote: > Hi Peter, > >> I would appreciate comments/feedback on this proposal to extend the >> fpto?i instructions to support rounding. > I think this might be useful. Actually, LLVM specifies that fpto?i convert > their operand into the nearest (rounding towards zero) signed integer value. > Do you have other rounding modes in mind? Currently I use custom metadata to > represent conv...
2010 Jun 28
0
[LLVMdev] Proposal for adding rounding variant of fpto?i instructions
Hi, I would appreciate comments/feedback on this proposal to extend the fpto?i instructions to support rounding. This is my first proposed significant extension to LLVM so I'd like to know if I'm completely off base here. First of all, I noticed the convert* intrinsics corresponding to the CONVERT_RNDSAT InstructionDAG. I propose not to build my work on top of t...
2016 Apr 15
2
Integer -> Floating point -> Integer cast optimizations
...t this checks whether the bit width of the integer *type* fits in the bit width of the mantissa, not the bit width of the integer value. - CL > On Apr 14, 2016, at 6:02 PM, escha at apple.com wrote: > > We already do this to some extent; see this code in InstCombineCasts: > > // fpto{s/u}i({u/s}itofp(X)) --> X or zext(X) or sext(X) or trunc(X) > // This is safe if the intermediate type has enough bits in its mantissa to > // accurately represent all values of X. For example, this won't work with > // i64 -> float -> i64. > Instruction *InstCombiner::Fo...
2016 Apr 14
2
Integer -> Floating point -> Integer cast optimizations
I'm saying at the IR level, not the C level. IR makes certain assumptions about the representation of floating point numbers. Nothing to do with C, I only used it as an example. - CL > On Apr 14, 2016, at 4:49 PM, Martin J. O'Riordan <martin.oriordan at movidius.com> wrote: > > I don't think that this is correct. > > | Let's say we have an int x, and we