[PATCH] D50913: [FPEnv] Don't need copysign/fabs/fneg constrained intrinsics

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 20 21:24:15 PDT 2018


arsenm added a comment.

In https://reviews.llvm.org/D50913#1206536, @spatel wrote:

> In https://reviews.llvm.org/D50913#1206373, @cameron.mcinally wrote:
>
> > Cool, I like that idea. I'll let this sit for a day or so to see if there are further comments. If not, I'll start a discussion on llvm-dev for a wider audience.
>
>
> I think fneg as an IR instruction or intrinsic has come up for discussion before, but I don't know why it wasn't implemented at the time. An intrinsic is the lighter weight solution and would line up with the similar:
>  http://llvm.org/docs/LangRef.html#llvm-copysign-intrinsic
>  http://llvm.org/docs/LangRef.html#llvm-fabs-intrinsic
>
> Any reason to prefer an actual instruction over an intrinsic?


I thjnk there’s unnecessary resistance to adding new instructions, but they are nicer to deal with. The existing set of basic operators are instructions, so fneg should be as well. They’re common enough to justify it. Isn’t the representation of intrinsic calls more expensive? I’d prefer if we had more of the IEEE ops as full instructions, like fma and fabs


Repository:
  rL LLVM

https://reviews.llvm.org/D50913





More information about the llvm-commits mailing list