[PATCH] D67839: [FPEnv] Document requirement of function attributes with constrained floating point

Pengfei Wang via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 25 19:43:16 PDT 2019


pengfei added a comment.

> @pengfei , do you think the "strictfp" attribute on an intrinsic would tell you enough for X86 instruction selection? I think for any x86 instructions that take rounding mode operands the intrinsic would already have that explicitly specified, right?

I think the exception attribute on architecture-specific intrinsics should accept option ignore/maytrap/strict like the constrained intrinsics do. "strictfp" is not enough if we want to attach exception attribute to intrinsic.
For rounding mode, AFAIK, some SSE/AVX intrinsics may implicitly use MXCSR.RC, e.g. `__m128i _mm_cvtpd_epi32 (__m128d a)`, AVX512 intrinsics as well as partial SSE/AVX intrinsics can be specified through parameter, but they still may use MAXCSR.RC if specified with `_MM_FROUND_CUR_DIRECTION`. Should we attach the rounding attribute to intrinsic, if we had explicitly specified MXCSR.RC?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D67839





More information about the llvm-commits mailing list