[PATCH] D69272: Restricted variant of '#pragma STDC FENV_ACCESS'

Serge Pavlov via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Oct 21 10:55:44 PDT 2019


sepavloff created this revision.
sepavloff added reviewers: rsmith, rjmccall, andrew.w.kaylor, kpn, hfinkel, cameron.mcinally, uweigand.
Herald added a project: clang.

This change implements support of '#pragma STDC FENV_ACCESS' in
frontend. The pragma is supported only at namespace level and in
topmost block in functions.

Use of the pragma results in using constrained intrinsics to represent
floating point operations in the function to which it applies. Such
function is marked by the attribute 'FPEnvironment' in AST and
'fenv_access' in IR.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D69272

Files:
  clang/include/clang/Basic/Attr.td
  clang/include/clang/Basic/DiagnosticParseKinds.td
  clang/include/clang/Basic/DiagnosticSemaKinds.td
  clang/include/clang/Sema/Sema.h
  clang/lib/CodeGen/CodeGenFunction.cpp
  clang/lib/CodeGen/CodeGenModule.cpp
  clang/lib/CodeGen/CodeGenModule.h
  clang/lib/Parse/ParsePragma.cpp
  clang/lib/Parse/ParseStmt.cpp
  clang/lib/Sema/SemaAttr.cpp
  clang/lib/Sema/SemaStmt.cpp
  clang/lib/Sema/TreeTransform.h
  clang/test/CodeGen/pragma-fenv_access.c
  clang/test/Parser/pragma-fenv_access.c
  clang/test/Preprocessor/pragma_unknown.c

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D69272.225919.patch
Type: text/x-patch
Size: 14245 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20191021/6e767df8/attachment-0001.bin>


More information about the cfe-commits mailing list