[PATCH] D44909: [DAGCombine] (float)((int) f) --> ftrunc (PR36617)
Sanjay Patel via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jun 11 08:33:31 PDT 2018
spatel added a comment.
In https://reviews.llvm.org/D44909#1126945, @rdhindsa wrote:
> What is the expected behavior for casting float values in range (-1.0 , 0.0) from float->int->float? If the expected value is -0.0 (instead of 0.0), what is the reason for that?
Not sure I understand the question. Casting FP (-1.0, 0.0) to int with round-to-zero mode results in integer 0. Converting that back to FP is always 0.0.
Repository:
rL LLVM
https://reviews.llvm.org/D44909
More information about the llvm-commits
mailing list