[PATCH] D102343: [clang][patch][FPEnv] Make Initialization of C++ globals strictfp aware

Fangrui Song via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Jul 29 11:13:32 PDT 2021


MaskRay added inline comments.


================
Comment at: clang/lib/Sema/SemaExpr.cpp:19531
+            SC_None, S.getCurFPFeatures().isFPConstrained(),
+            false /*isInlineSpecified*/, FD->hasPrototype(),
             /*ConstexprKind*/ ConstexprSpecKind::Unspecified);
----------------
canonical form is `/*XXX=*/YYY`


================
Comment at: clang/test/CodeGen/fp-floatcontrol-stack.cpp:226
+                                        float y();
+// CHECK-DDEFAULT Function Attrs: noinline nounwind optnone mustprogress
+// CHECK-DEBSTRICT Function Attrs: noinline nounwind optnone strictfp mustprogress
----------------
Missing colon


================
Comment at: clang/test/CodeGen/fp-floatcontrol-stack.cpp:249
 #pragma float_control(except, off)
+// CHECK-DDEFAULT Function Attrs: noinline nounwind optnone
+// CHECK-DEBSTRICT Function Attrs: noinline nounwind optnone
----------------
Missing colon?


================
Comment at: clang/test/CodeGen/fp-floatcontrol-stack.cpp:282
+
+// CHECK-DDEFAULT Function Attrs: noinline nounwind
+// CHECK-DEBSTRICT Function Attrs: noinline nounwind strictfp
----------------
You need `{{$}}` to check there is no `strictfp` at the end.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D102343



More information about the cfe-commits mailing list