[PATCH] D136786: Fix `unsafe-fp-math` attribute emission.

2022-11-14 Thread Michele Scandale via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGb7d7c448df9a: Fix `unsafe-fp-math` attribute emission. (authored by michele.scandale). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D136786/new/

[PATCH] D136786: Fix `unsafe-fp-math` attribute emission.

2022-11-11 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 474828. michele.scandale added a comment. Rebase on top of compiler driver changes for `-funsafe-math-optimizations` Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D136786/new/

[PATCH] D137578: Fix 'unsafe-math-optimizations' flag dependencies

2022-11-10 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale accepted this revision. michele.scandale added a comment. This revision is now accepted and ready to land. This looks good for me. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D137578/new/ https://reviews.llvm.org/D137578

[PATCH] D136786: Fix `unsafe-fp-math` attribute emission.

2022-11-04 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. In D136786#3903646 , @zahiraam wrote: > The changes in this patch look good to me. > @michele.scandale please make sure not to drop the driver changes that we > agreed upon in this patch. Thanks. I started looking at

[PATCH] D136786: Fix `unsafe-fp-math` attribute emission.

2022-11-01 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale marked an inline comment as done. michele.scandale added inline comments. Comment at: clang/test/CodeGen/func-attr.c:5 // RUN: %clang -c -target x86_64 -funsafe-math-optimizations \ -// RUN: -emit-llvm -S -o - %s | FileCheck %s +// RUN: -fno-math-errno

[PATCH] D136786: Fix `unsafe-fp-math` attribute emission.

2022-10-31 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added inline comments. Comment at: clang/lib/CodeGen/CodeGenFunction.cpp:181 + FPFeatures.allowFPContractAcrossStatement()); } zahiraam wrote: > Shouldn't then this also check for FPFeatures.getFPContractMode() ? This should be

[PATCH] D136786: Fix `unsafe-fp-math` attribute emission.

2022-10-31 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. In D136786#3896341 , @zahiraam wrote: >> I'm going to ignore fast-math right now, because I think the current >> handling is mostly OK, and this review is about unsafe-fp-math. The >> unsafe-fp-math case is a little

[PATCH] D136786: Fix `unsafe-fp-math` attribute emission.

2022-10-29 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. In D136786#3893485 , @andrew.w.kaylor wrote: > My understanding is this: > > unsafe-fp-math = exception_behavior(ignore) + >fenv_access(off) + >no_signed_zeros(on) + >

[PATCH] D136786: Fix `unsafe-fp-math` attribute emission.

2022-10-29 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 471801. michele.scandale added a comment. Use low level properties to set `"unsafe-fp-math"="true"`. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D136786/new/ https://reviews.llvm.org/D136786 Files:

[PATCH] D136786: Fix `unsafe-fp-math` attribute emission.

2022-10-28 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. In D136786#3893485 , @andrew.w.kaylor wrote: > As a first principle, I'd like to clarify a "big picture" item that I was > trying to get at in my earlier comment. I'd like to be able to reason about > this from the

[PATCH] D136786: Fix `unsafe-fp-math` attribute emission.

2022-10-28 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added inline comments. Comment at: clang/lib/CodeGen/CGCall.cpp:1865 FuncAttrs.addAttribute("approx-func-fp-math", "true"); -if ((LangOpts.FastMath || - (!LangOpts.FastMath && LangOpts.AllowFPReassoc && - LangOpts.AllowRecip &&

[PATCH] D136786: Fix `unsafe-fp-math` attribute emission.

2022-10-27 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added inline comments. Comment at: clang/lib/CodeGen/CGCall.cpp:1865 FuncAttrs.addAttribute("approx-func-fp-math", "true"); -if ((LangOpts.FastMath || - (!LangOpts.FastMath && LangOpts.AllowFPReassoc && - LangOpts.AllowRecip &&

[PATCH] D136786: Fix `unsafe-fp-math` attribute emission.

2022-10-26 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added inline comments. Comment at: clang/lib/CodeGen/CGCall.cpp:1865 FuncAttrs.addAttribute("approx-func-fp-math", "true"); -if ((LangOpts.FastMath || - (!LangOpts.FastMath && LangOpts.AllowFPReassoc && - LangOpts.AllowRecip &&

[PATCH] D136786: Fix `unsafe-fp-math` attribute emission.

2022-10-26 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added inline comments. Comment at: clang/lib/CodeGen/CGCall.cpp:1865 FuncAttrs.addAttribute("approx-func-fp-math", "true"); -if ((LangOpts.FastMath || - (!LangOpts.FastMath && LangOpts.AllowFPReassoc && - LangOpts.AllowRecip &&

[PATCH] D136786: Fix `unsafe-fp-math` attribute emission.

2022-10-26 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale created this revision. michele.scandale added reviewers: zahiraam, aaron.ballman, andrew.w.kaylor, rjmccall, efriedma, fhahn. Herald added a subscriber: ormris. Herald added a project: All. michele.scandale requested review of this revision. Herald added a project: clang. Herald

[PATCH] D135097: Remove redundant option '-menable-unsafe-fp-math'.

2022-10-25 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added inline comments. Comment at: clang/lib/CodeGen/CGCall.cpp:1865-1869 +if ((LangOpts.FastMath || + !LangOpts.FastMath && LangOpts.AllowFPReassoc && LangOpts.AllowRecip && + !LangOpts.FiniteMathOnly && LangOpts.NoSignedZero && +

[PATCH] D135097: Remove redundant option '-menable-unsafe-fp-math'.

2022-10-25 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added inline comments. Comment at: clang/lib/CodeGen/CGCall.cpp:1865-1869 +if ((LangOpts.FastMath || + !LangOpts.FastMath && LangOpts.AllowFPReassoc && LangOpts.AllowRecip && + !LangOpts.FiniteMathOnly && LangOpts.NoSignedZero && +

[PATCH] D131698: [Sema] Fix `ExtVectorElementExpr` tree transform for the `isArrow` case.

2022-10-11 Thread Michele Scandale via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGc49cde6467f9: [Sema] Fix `ExtVectorElementExpr` tree transform for the `isArrow` case. (authored by michele.scandale). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D131698: [Sema] Fix `ExtVectorElementExpr` tree transform for the `isArrow` case.

2022-10-11 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. In D131698#3848469 , @michele.scandale wrote: > @rjmccall would you be able to land this on my behalf? Thanks in advance. I got commit access. I will take care of landing the change. Thanks anyway. Repository: rG

[PATCH] D131698: [Sema] Fix `ExtVectorElementExpr` tree transform for the `isArrow` case.

2022-10-10 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. @rjmccall would you be able to land this on my behalf? Thanks in advance. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131698/new/ https://reviews.llvm.org/D131698 ___

[PATCH] D131698: [Sema] Fix `ExtVectorElementExpr` tree transform for the `isArrow` case.

2022-10-10 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 466686. michele.scandale added a comment. Final rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131698/new/ https://reviews.llvm.org/D131698 Files: clang/lib/Sema/TreeTransform.h

[PATCH] D131698: [Sema] Fix `ExtVectorElementExpr` tree transform for the `isArrow` case.

2022-10-10 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. Ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131698/new/ https://reviews.llvm.org/D131698 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D131698: [Sema] Fix `ExtVectorElementExpr` tree transform for the `isArrow` case.

2022-09-28 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 463727. michele.scandale added a comment. Rebased Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131698/new/ https://reviews.llvm.org/D131698 Files: clang/lib/Sema/TreeTransform.h

[PATCH] D128745: [c++] implements DR692, DR1395 and tentatively DR1432, about partial ordering of variadic template partial specialization or function template

2022-08-17 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. I can see failures related to this change in a downstream version of clang where the default `ClangABICompat` value is not `Latest` (after the followup https://reviews.llvm.org/rGda6187f566b7881cb8350621aea9bd582de569b9). My understanding is that with

[PATCH] D131698: [Sema] Fix `ExtVectorElementExpr` tree transform for the `isArrow` case.

2022-08-11 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 451911. michele.scandale added a comment. Clang-format fixes Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D131698/new/ https://reviews.llvm.org/D131698 Files: clang/lib/Sema/TreeTransform.h

[PATCH] D131698: [Sema] Fix `ExtVectorElementExpr` tree transform for the `isArrow` case.

2022-08-11 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale created this revision. michele.scandale added reviewers: rsmith, doug.gregor, rjmccall. Herald added a project: All. michele.scandale requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Make sure we propagate the value for

[PATCH] D83454: [CMake] Make `intrinsics_gen` dependency unconditional.

2020-07-17 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. In D83454#2145086 , @michele.scandale wrote: > In D83454#2144386 , @JDevlieghere > wrote: > > > In D83454#2142719 , > >

[PATCH] D83454: [CMake] Make `intrinsics_gen` dependency unconditional.

2020-07-10 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. In D83454#2144386 , @JDevlieghere wrote: > In D83454#2142719 , > @michele.scandale wrote: > > > I tested locally the standalone build of Clang with D83426 > >

[PATCH] D83454: [CMake] Make `intrinsics_gen` dependency unconditional.

2020-07-09 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. I tested locally the standalone build of Clang with D83426 . I just want to make sure that we all agree this is right way moving forward. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D83426: Unbreak Clang standalone build.

2020-07-09 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. Thanks. Would you be able to land this on my behalf? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83426/new/ https://reviews.llvm.org/D83426 ___ cfe-commits mailing

[PATCH] D83454: [CMake] Make `intrinsics_gen` dependency unconditional.

2020-07-08 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale created this revision. michele.scandale added reviewers: chandlerc, beanz, zturner. Herald added subscribers: lldb-commits, cfe-commits, MaskRay, aheejin, arichardson, sbc100, mgorny, emaste. Herald added a reviewer: espindola. Herald added a reviewer: MaskRay. Herald added

[PATCH] D83426: Unbreak Clang standalone build.

2020-07-08 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale created this revision. michele.scandale added a reviewer: chandlerc. Herald added subscribers: cfe-commits, mgorny. Herald added a project: clang. Add missing C++ language standard setup for Clang standalone build. Repository: rG LLVM Github Monorepo

[PATCH] D82659: Fix missing build dependency on omp_gen.

2020-07-08 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. Uhm.. it looks like it is not needed anymore. In the `LLVMConfig.cmake` that will be installed a `intrinsics_gen` and `omp_gen` custom targets are created for exactly the purpose of allowing out-of-tree or standalone builds to freely depend on them. The Clang

[PATCH] D83414: Unbreak Clang standalone build.

2020-07-08 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale created this revision. michele.scandale added reviewers: clementval, simon_tatham, chandlerc. Herald added subscribers: cfe-commits, sstefan1, martong, arphaman, mgorny. Herald added a reviewer: jdoerfert. Herald added a project: clang. Having the `omp_gen` dependency added

[PATCH] D82659: Fix missing build dependency on omp_gen.

2020-07-08 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. In D82659#2136999 , @clementval wrote: > Looks good but just one question ... When clang is built as standalone it > does not build the OpenMP part inside Clang? I haven't seen any code to avoid > compiling the OpenMP

[PATCH] D82659: Fix missing build dependency on omp_gen.

2020-07-07 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. Why `omp_gen` is now a dependency of `clang-tablegen-targets` rather than being in the `LLVM_COMMON_DEPENDS` list like `clang-tablegen-targets`? Moreover I've noticed that with the recent changes where `omp_gen` has been added as a dependency in several

[PATCH] D80462: Fix floating point math function attributes definition.

2020-06-09 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. As far as I can tell the failures reported shouldn't be caused by this change. John, would you be able to land this on my behalf? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80462/new/

[PATCH] D80462: Fix floating point math function attributes definition.

2020-06-09 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 269417. michele.scandale added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80462/new/ https://reviews.llvm.org/D80462 Files: clang/include/clang/Basic/LangOptions.h

[PATCH] D80462: Fix floating point math function attributes definition.

2020-06-08 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 269387. michele.scandale added a comment. Store `CGF` in RAII object. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80462/new/ https://reviews.llvm.org/D80462 Files:

[PATCH] D80462: Fix floating point math function attributes definition.

2020-06-08 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 269381. michele.scandale added a comment. Modify IR function attribute directly. RAII object modifies IR builder state and function attributes only if needed. Rebase. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D80462: Fix floating point math function attributes definition.

2020-06-05 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. In D80462#2077569 , @rjmccall wrote: > Can we do this conservatively only if something is changed within the > function definition, and otherwise respect the global settings? I'm not sure I understand what you mean.

[PATCH] D80462: Fix floating point math function attributes definition.

2020-06-04 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 268667. michele.scandale added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80462/new/ https://reviews.llvm.org/D80462 Files: clang/lib/CodeGen/CGCall.cpp

[PATCH] D80462: Fix floating point math function attributes definition.

2020-06-02 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 267907. michele.scandale added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80462/new/ https://reviews.llvm.org/D80462 Files: clang/lib/CodeGen/CGCall.cpp

[PATCH] D80462: Fix floating point math function attributes definition.

2020-06-01 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 267783. michele.scandale added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80462/new/ https://reviews.llvm.org/D80462 Files: clang/lib/CodeGen/CGCall.cpp

[PATCH] D80315: Fix CC1 command line options mapping into fast-math flags.

2020-05-29 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. Thanks John. Would you be able to land this on my behalf? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80315/new/ https://reviews.llvm.org/D80315 ___ cfe-commits

[PATCH] D80315: Fix CC1 command line options mapping into fast-math flags.

2020-05-29 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 267401. michele.scandale added a comment. Revert last change about `-ffast-math` imply "fast" contraction mode by default in CC1. Rebase. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80315/new/

[PATCH] D80315: Fix CC1 command line options mapping into fast-math flags.

2020-05-29 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale requested review of this revision. michele.scandale added a comment. I've just realized it might be incorrect to have the CC1 option `-ffast-math` changing the default contraction mode. The clang driver generates `-ffast-math` based on conditions that do not involve the

[PATCH] D80315: Fix CC1 command line options mapping into fast-math flags.

2020-05-29 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 267124. michele.scandale added a comment. Herald added a reviewer: jdoerfert. Herald added a subscriber: sstefan1. Fixup more tests with now redundant `-ffp-contract=fast` option. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D80462: Fix floating point math function attributes definition.

2020-05-29 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 267125. michele.scandale added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80462/new/ https://reviews.llvm.org/D80462 Files: clang/lib/CodeGen/CGCall.cpp

[PATCH] D80462: Fix floating point math function attributes definition.

2020-05-28 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 267122. michele.scandale added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80462/new/ https://reviews.llvm.org/D80462 Files: clang/lib/CodeGen/CGCall.cpp

[PATCH] D80315: Fix CC1 command line options mapping into fast-math flags.

2020-05-28 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 267121. michele.scandale added a comment. Rebase + `-ffast-math` change the default contraction mode to fast. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80315/new/ https://reviews.llvm.org/D80315

[PATCH] D80315: Fix CC1 command line options mapping into fast-math flags.

2020-05-28 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. In D80315#2061164 , @rjmccall wrote: > In D80315#2059160 , > @michele.scandale wrote: > > > In D80315#2058914 , @rjmccall > > wrote: > >

[PATCH] D80315: Fix CC1 command line options mapping into fast-math flags.

2020-05-28 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. In D80315#2058914 , @rjmccall wrote: > In D80315#2058735 , > @michele.scandale wrote: > > > In D80315#2058549 , @rjmccall > > wrote: > >

[PATCH] D80315: Fix CC1 command line options mapping into fast-math flags.

2020-05-27 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. In D80315#2058549 , @rjmccall wrote: > The code cleanups all seems reasonable. The actual changes in > code-generation changes are because we were failing to set these reliably? Most of them yes. In the CUDA test we

[PATCH] D80462: Fix floating point math function attributes definition.

2020-05-22 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale created this revision. michele.scandale added reviewers: rjmccall, mibintc. Herald added a project: clang. Herald added a subscriber: cfe-commits. With the support for changing the state of floating point optimizations within a code block, we need to make sure that the function

[PATCH] D80315: Fix CC1 command line options mapping into fast-math flags.

2020-05-20 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 265405. michele.scandale added a comment. Fix formatting issues. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80315/new/ https://reviews.llvm.org/D80315 Files:

[PATCH] D80315: Fix CC1 command line options mapping into fast-math flags.

2020-05-20 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 265333. michele.scandale added a comment. Fix 'clang/test/CodeGenCUDA/library-builtin.cu' Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80315/new/ https://reviews.llvm.org/D80315 Files:

[PATCH] D80315: Fix CC1 command line options mapping into fast-math flags.

2020-05-20 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale marked an inline comment as done. michele.scandale added inline comments. Comment at: clang/test/CodeGenOpenCL/relaxed-fpmath.cl:14 // FINITE: fdiv nnan ninf float - // UNSAFE: fdiv nnan nsz float + // UNSAFE: fdiv reassoc nsz arcp afn float // MAD: fdiv

[PATCH] D80315: Fix CC1 command line options mapping into fast-math flags.

2020-05-20 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale marked 2 inline comments as done. michele.scandale added inline comments. Comment at: clang/test/CodeGen/libcalls.c:11-21 + // CHECK-FAST: call reassoc nsz arcp afn float @llvm.sqrt.f32(float float l0 = sqrtf(a0); // CHECK-YES: call double @sqrt //

[PATCH] D80315: Fix CC1 command line options mapping into fast-math flags.

2020-05-20 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale created this revision. michele.scandale added reviewers: rjmccall, mibintc, Anastasia. Herald added subscribers: cfe-commits, jvesely. Herald added a project: clang. michele.scandale marked an inline comment as done. michele.scandale added inline comments. michele.scandale marked

[PATCH] D79903: FastMathFlags.allowContract should be init from FPFeatures.allowFPContractAcrossStatement

2020-05-19 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. This looks good to me. @rjmccall do you have any more feedback? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D79903/new/ https://reviews.llvm.org/D79903 ___

[PATCH] D72841: Add support for pragma float_control, to control precision and exception behavior at the source level

2020-05-14 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added inline comments. Comment at: clang/lib/CodeGen/CGExprScalar.cpp:227 + FMF.setAllowContract(FPFeatures.allowFPContractAcrossStatement() || + FPFeatures.allowFPContractWithinStatement()); } mibintc wrote: > mibintc

[PATCH] D79903: FastMathFlags.allowContract should be init from FPFeatures.allowFPContractAcrossStatement

2020-05-14 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added inline comments. Comment at: clang/lib/Frontend/CompilerInvocation.cpp:2943 + if (Opts.FastRelaxedMath) +Opts.setDefaultFPContractMode(LangOptions::FPM_Fast); Opts.HexagonQdsp6Compat = Args.hasArg(OPT_mqdsp6_compat); mibintc wrote:

[PATCH] D72841: Add support for pragma float_control, to control precision and exception behavior at the source level

2020-05-12 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. In D72841#2030707 , @rjmccall wrote: > IIUC, the way within-statement contraction is supposed to work is that there > are supposed to be blocking intrinsics inserted at various places. I don't > remember the details,

[PATCH] D72841: Add support for pragma float_control, to control precision and exception behavior at the source level

2020-05-11 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added inline comments. Comment at: clang/include/clang/Basic/LangOptions.h:396-401 +allow_reassoc(LangOpts.FastMath || LangOpts.AllowFPReassoc), +no_nans(LangOpts.FastMath || LangOpts.NoHonorNaNs), +no_infs(LangOpts.FastMath ||

[PATCH] D72841: Add support for pragma float_control, to control precision and exception behavior at the source level

2020-05-11 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added inline comments. Comment at: clang/lib/CodeGen/CGExprScalar.cpp:227 + FMF.setAllowContract(FPFeatures.allowFPContractAcrossStatement() || + FPFeatures.allowFPContractWithinStatement()); } I'm not convinced it

[PATCH] D74643: [Parse] Consider attributes in `TryParsePtrOperatorSeq`.

2020-02-23 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 246139. michele.scandale added a comment. Herald added a subscriber: jfb. Tests for `__attribute__(())` syntax + attribute arguments + fix for `_Atomic` qualifier. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D74643: [Parse] Consider attributes in `TryParsePtrOperatorSeq`.

2020-02-22 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 246095. michele.scandale added a comment. Fixed comment wording + rebase. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74643/new/ https://reviews.llvm.org/D74643 Files:

[PATCH] D74643: [Parse] Consider attributes in `TryParsePtrOperatorSeq`.

2020-02-21 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. @rsmith: is this fine for you as well? If this is ready for landing, I would appreciate if somebody can land this on my behalf since I do not have commit rights. Thanks! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D74643: [Parse] Consider attributes in `TryParsePtrOperatorSeq`.

2020-02-17 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale marked an inline comment as done. michele.scandale added a comment. Assuming this is fine, I would need someone landing this change on my behalf since I do not have commit rights. Thanks! Comment at: clang/lib/Parse/ParseTentative.cpp:780 + if

[PATCH] D74643: [Parse] Consider attributes in `TryParsePtrOperatorSeq`.

2020-02-17 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 245073. michele.scandale added a comment. Add comment about ObjC message send being rejected + rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74643/new/ https://reviews.llvm.org/D74643 Files:

[PATCH] D74643: [Parse] Consider attributes in `TryParsePtrOperatorSeq`.

2020-02-17 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale marked an inline comment as done. michele.scandale added inline comments. Comment at: clang/lib/Parse/ParseTentative.cpp:798 +if (Tok.is(tok::l_square)) { + ConsumeBracket(); + if (!SkipUntil(tok::r_square)) rjmccall

[PATCH] D74643: [Parse] Consider attributes in `TryParsePtrOperatorSeq`.

2020-02-17 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 245068. michele.scandale added a comment. Check for double brackets for C++11 style attributes, and outline the loop to skip attributes in `TrySkipAttributes` to fix also the other use in `TryConsumeDeclarationSpecifier` Repository: rG LLVM

[PATCH] D74643: [Parse] Consider attributes in `TryParsePtrOperatorSeq`.

2020-02-14 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale created this revision. michele.scandale added reviewers: rjmccall, rsmith. Herald added a project: clang. Herald added a subscriber: cfe-commits. michele.scandale updated this revision to Diff 244756. michele.scandale added a comment. Missed GNU style attributes The syntax

[PATCH] D74643: [Parse] Consider attributes in `TryParsePtrOperatorSeq`.

2020-02-14 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale updated this revision to Diff 244756. michele.scandale added a comment. Missed GNU style attributes Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74643/new/ https://reviews.llvm.org/D74643 Files:

[PATCH] D62731: Add support for options -frounding-math, -ftrapping-math, -ffp-model=, and -ffp-exception-behavior=, : Specify floating point behavior

2019-12-10 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. In D62731#1775046 , @mibintc wrote: > In D62731#1773854 , > @michele.scandale wrote: > > > I've noticed you removed the change for `CompilerInvocation.cpp` about the > >

[PATCH] D62731: Add support for options -frounding-math, -ftrapping-math, -ffp-model=, and -ffp-exception-behavior=, : Specify floating point behavior

2019-12-06 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added a comment. I've noticed you removed the change for `CompilerInvocation.cpp` about the initialization of the codegen option `NoTrappingMath`. Was that an accident? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62731/new/

[PATCH] D62731: Add support for options -frounding-math, -ftrapping-math, -ffp-model=, and -ffp-exception-behavior=, : Specify floating point behavior

2019-12-02 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added inline comments. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:2345 +<< "-ffp-contract=fast"; +optID = options::OPT_ffp_contract; +FPModel = Val; mibintc wrote: > michele.scandale wrote: > > Here the state

[PATCH] D62731: Add support for options -frounding-math, -ftrapping-math, -ffp-model=, and -ffp-exception-behavior=, : Specify floating point behavior

2019-11-19 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added inline comments. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:2337 +<< "-ffp-contract=fast"; +optID = options::OPT_ffast_math; +FPModel = Val; Here it seems you are changing `optID` to `OPT_ffast_math` to

[PATCH] D62731: Add support for options -frounding-math, -ftrapping-math, -ffp-model=, and -ffp-exception-behavior=, : Specify floating point behavior

2019-11-19 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added inline comments. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:2576 +CmdArgs.push_back("-ftrapping-math"); + } else if (TrappingMathPresent) CmdArgs.push_back("-fno-trapping-math"); mibintc wrote: > michele.scandale wrote: >

[PATCH] D62731: Add support for options -frounding-math, -ftrapping-math, -ffp-model=, and -ffp-exception-behavior=, : Specify floating point behavior

2019-11-18 Thread Michele Scandale via Phabricator via cfe-commits
michele.scandale added inline comments. Comment at: clang/lib/Driver/ToolChains/Clang.cpp:2408 +case options::OPT_frounding_math: + // The default setting for frounding-math is True and ffast-math + // sets fno-rounding-math, but we only want to use constrained