[PATCH] D64746: Add constrained intrinsics for lrint and lround

Nuno Lopes via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Feb 15 10:43:51 PST 2022


nlopes added a comment.
Herald added a subscriber: pengfei.

Hi,

The semantics described by patch for `lrint` regarding the rounding mode is a bit peculiar and different from all the other constrained FP instrinsics.
It says:

  The rounding mode is described, not determined, by the rounding mode argument. The actual rounding mode is determined by the runtime floating-point environment. The rounding mode argument is only intended as information to the compiler.

So does this means that the only accepted rounding mode is !dynamic? Why is `lrint` different from the remaining intrinsics?

I was trying to implement the semantics of lrint in Alive2 and came across this discrepancy.

Thanks!


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D64746/new/

https://reviews.llvm.org/D64746



More information about the llvm-commits mailing list