[PATCH] D49865: Inform the AST of #pragma FENV_ACCESS use

2018-08-14 Thread Kevin P. Neal via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL339693 (authored by kpn, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm.org/D49865?vs=158351&id=160626#toc Repository: rL LLVM https://reviews.

[PATCH] D51372: FENV_ACCESS support for libm-style constrained intrinsics

2018-08-28 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn created this revision. kpn added a reviewer: rsmith. Herald added a reviewer: javed.absar. Herald added a subscriber: cfe-commits. This builds on https://reviews.llvm.org/D49865 to get #pragma STDC FENV_ACCESS ON to and used by AST handling of function calls to math intrinsics. This now emit

[PATCH] D49865: Inform the AST of #pragma FENV_ACCESS use

2018-07-26 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn created this revision. kpn added reviewers: rsmith, craig.topper, hfinkel. Herald added a subscriber: cfe-commits. We have in place support for parsing #pragma FENV_ACCESS, but that information is then discarded with a warning to the user that we don't support it. This patch gets us one step

[PATCH] D49865: Inform the AST of #pragma FENV_ACCESS use

2018-07-30 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 158036. kpn added a comment. Updated based on review. https://reviews.llvm.org/D49865 Files: include/clang/AST/Expr.h include/clang/Basic/LangOptions.h include/clang/Basic/TokenKinds.def include/clang/Parse/Parser.h include/clang/Sema/Sema.h lib/Par

[PATCH] D49865: Inform the AST of #pragma FENV_ACCESS use

2018-07-30 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn marked 3 inline comments as done. kpn added inline comments. Comment at: include/clang/Basic/LangOptions.h:273-280 FPOptions() : fp_contract(LangOptions::FPC_Off) {} // Used for serializing. explicit FPOptions(unsigned I) : fp_contract(static_cast(I)) {}

[PATCH] D49865: Inform the AST of #pragma FENV_ACCESS use

2018-07-31 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 158229. kpn added a comment. Thanks for the fast turnaround! I don't have commit access, can I get you to commit it for me? And can I get you to put my email address in the commit message? I'll start looking at Sema like you said. https://reviews.llvm.org/D4

[PATCH] D49865: Inform the AST of #pragma FENV_ACCESS use

2018-07-31 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 158307. kpn added a comment. Replace accidentally lost comment. https://reviews.llvm.org/D49865 Files: include/clang/AST/Expr.h include/clang/Basic/LangOptions.h include/clang/Basic/TokenKinds.def include/clang/Parse/Parser.h include/clang/Sema/Sema.h

[PATCH] D49865: Inform the AST of #pragma FENV_ACCESS use

2018-07-31 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 158351. kpn added a comment. This includes the change to pass the annotation token when FENV_ACCESS is turned off. https://reviews.llvm.org/D49865 Files: include/clang/AST/Expr.h include/clang/Basic/LangOptions.h include/clang/Basic/TokenKinds.def incl

[PATCH] D51372: FENV_ACCESS support for libm-style constrained intrinsics

2018-10-09 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 168814. kpn added a comment. Update based on feedback to https://reviews.llvm.org/D52839: add missing AST (de)serialization support. Ping. https://reviews.llvm.org/D51372 Files: include/clang/AST/Expr.h include/clang/AST/ExprCXX.h lib/AST/ASTImporter.cp

[PATCH] D52839: Inform AST's UnaryOperator of FENV_ACCESS

2018-10-11 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 169266. kpn added a comment. Address review comments. Add a test case. The test depends on https://reviews.llvm.org/D53157, but it reads easily enough. Richard, does this work for you? https://reviews.llvm.org/D52839 Files: include/clang/AST/Expr.h lib/AS

[PATCH] D52839: Inform AST's UnaryOperator of FENV_ACCESS

2018-10-11 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. I forgot to address the template question. I've spend the past 18 years doing SystemZ backend work on multiple {,JIT} compilers. I'm not really in a position to answer your question about how to handle getting these FP bits down into C++ templates. I hope that won't hold up

[PATCH] D52839: Inform AST's UnaryOperator of FENV_ACCESS

2018-10-12 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 169463. kpn added a comment. Address review comments. https://reviews.llvm.org/D52839 Files: include/llvm/IR/IRBuilder.h Index: include/llvm/IR/IRBuilder.h === --- include/llvm/IR/IRBuilder.h ++

[PATCH] D52839: Inform AST's UnaryOperator of FENV_ACCESS

2018-10-12 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 169464. kpn added a comment. Upload the correct diff this time. Sorry about the confusion! https://reviews.llvm.org/D52839 Files: include/clang/AST/Expr.h lib/AST/ASTImporter.cpp lib/Analysis/BodyFarm.cpp lib/CodeGen/CGExprScalar.cpp lib/CodeGen/CGObj

[PATCH] D52839: Inform AST's UnaryOperator of FENV_ACCESS

2019-01-25 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. In D52839#1263794 , @rsmith wrote: > > 2. Track the FP environment somewhere more transient, probably on the `Scope` > object. When parsing an operator, store the environment on the expression, > and when performing a `TreeTransf

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2018-11-08 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. In https://reviews.llvm.org/D53157#1290364, @andrew.w.kaylor wrote: > Rather than having separate methods to create the constrained versions of the > intrinsics, why not have a way to set the constrained state in the IR builder > and have the regular CreateFAdd et. al. func

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2018-11-08 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. In https://reviews.llvm.org/D53157#1291978, @cameron.mcinally wrote: > In https://reviews.llvm.org/D53157#1291964, @kpn wrote: > > > I don't expect anyone would need to switch between constrained and regular > > floating point at an instruction level of granularity. > > > Th

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2018-11-20 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. In https://reviews.llvm.org/D53157#1303398, @cameron.mcinally wrote: > If we all agree upon that, then we simply have to treat the functions that > modify the FPEnv, e.g. fesetexcept(...), as barriers. That way it does not > matter if a FENV_ACCESS=OFF function is translate

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2018-11-21 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. In https://reviews.llvm.org/D53157#1304347, @uweigand wrote: > But given that there is still infrastructure missing in the IR optimizers, I > also think that at least in the first implementation, we probably should go > with the original approach and just use constrained in

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2018-12-03 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 176432. kpn added a comment. I've changed the patch so that calls to CreateFAdd() et al will give you constrained intrinsics if they are enabled. This required adding functions to enable/disable constrained-as-default plus calls to deal with the rounding mode a

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2018-12-03 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 176464. kpn added a comment. Address review comment: Shrink the diff by eliminating unneeded use of else. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D53157/new/ https://reviews.llvm.org/D53157 Files: include/llvm/IR/IRBuilder.h unittests/IR/IRBui

[PATCH] D51372: FENV_ACCESS support for libm-style constrained intrinsics

2018-09-18 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 165995. kpn added a comment. Rebase. Correct obvious error with powi. Fix test and test both C and (partial) C++. Ping. https://reviews.llvm.org/D51372 Files: include/clang/AST/Expr.h include/clang/AST/ExprCXX.h lib/AST/ASTImporter.cpp lib/AST/Expr.cp

[PATCH] D52839: Inform AST's UnaryOperator of FENV_ACCESS

2018-10-03 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn created this revision. kpn added a reviewer: rsmith. Herald added a reviewer: javed.absar. Herald added a subscriber: cfe-commits. The UnaryOperator needs to know about #pragma FENV_ACCESS to eventually properly emit the constrained math intrinsics. This diff just gets the information about

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-02-05 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. I emailed llvm-dev and cfe-dev on January 16th. The only responses I got back were of the don't care variety. For now it seems the constrained intrinsics will only be used by clang. @rsmith, does the direction of this patch seem reasonable for clang? Once Richard comments

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-05-31 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 202436. kpn marked 4 inline comments as done. kpn added a comment. Address review comments. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D53157/new/ https://reviews.llvm.org/D53157 Files: include/llvm/IR/IRBuilder.h unittests/IR/IRBuilderTest.cpp

[PATCH] D62730: [RFC] Alternate implementation of D53157 IRBuilder for Constrained FP using enumeration vs MDNode and add support for fp-model and fp-speculation language options

2019-05-31 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. Incorporating feedback from D53157 is probably a good idea. Looks like that hasn't been done yet here completely. Repository: rL LLVM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62730/new/ https://reviews.llvm.org/D62730 __

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-05-31 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. I wanted to get the API straight before working on documentation. Comment at: include/llvm/IR/IRBuilder.h:228 + /// Enable/Disable use of constrained floating point math + void setIsConstrainedFP(bool IsCon) { IsFPConstrained = IsCon; } +

[PATCH] D62730: [RFC] Alternate implementation of D53157 IRBuilder for Constrained FP using enumeration vs MDNode and add support for fp-model and fp-speculation language options

2019-05-31 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added inline comments. Comment at: include/llvm/IR/FPState.h:9-31 + enum FPModelKind { +FPM_Off, +FPM_Precise, +FPM_Strict, +FPM_Fast + }; + lebedev.ri wrote: > All this needs comments, and possibly better names. > `FPM_Off`,etc is very non-

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-05-31 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. Oh, this ticket is not going to die from neglect. It is true that D43515 is a higher priority, but I need this IRBuilder work done as well. My department head wanted it done by the end of _last_ year. It's not going to die. How about I mer

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-06-04 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 202987. kpn added a comment. Address the rest of the review comments, hopefully. I've lifted from mibintc's D62730 the enums for the exception behavior and rounding modes. The rest of that set of changes is better left to a sep

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-06-17 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. Ping. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D53157/new/ https://reviews.llvm.org/D53157 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-06-17 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn marked an inline comment as done. kpn added inline comments. Comment at: include/llvm/IR/IRBuilder.h:113 +CR_ToZero ///< This corresponds to "fpround.tozero". + }; + rjmccall wrote: > Should these have "FP" in the name somewhere? And are they real

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-06-17 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 205151. kpn marked 3 inline comments as done. kpn added a comment. Address review comments. Run the changes through clang-format. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D53157/new/ https://reviews.llvm.org/D53157 Files: include/llvm/IR/IRBuild

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-06-17 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added inline comments. Comment at: include/llvm/IR/IRBuilder.h:1138 + +return MetadataAsValue::get(Context, RoundingMDS); + } rjmccall wrote: > Huh? You build an `MDNode` that wraps an `MDString` and then immediately > extract the `MDString` from it an

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-06-17 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn marked an inline comment as done. kpn added inline comments. Comment at: include/llvm/IR/IRBuilder.h:1138 + +return MetadataAsValue::get(Context, RoundingMDS); + } rjmccall wrote: > kpn wrote: > > rjmccall wrote: > > > Huh? You build an `MDNode` that wr

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-06-18 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 205371. kpn added a comment. Add static methods to convert between a StringRef and the enums for RoundingMode or ExceptionBehavior. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D53157/new/ https://reviews.llvm.org/D53157 Files: include/llvm/IR/IRBui

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-06-18 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn marked an inline comment as done. kpn added inline comments. Comment at: include/llvm/IR/IntrinsicInst.h:235 + ebStrict ///< This corresponds to "fpexcept.strict". }; rjmccall wrote: > Is it okay that `ebUnspecified` and `ebInvalid` over

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-06-18 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. Andy, can I get you to chime in? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D53157/new/ https://reviews.llvm.org/D53157 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/li

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-06-20 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. I found out that some compilers, including SAS/C, will warn about enum overlaps like the one here under discussion. So I now believe John is correct and that eliminating that overlap is the right thing to do. Over the weekend I'll be thinking about whether or not to try and

[PATCH] D62731: [RFC] Add support for options -fp-model= and -fp-speculation= : specify floating point behavior

2019-07-25 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. In D62731#1601310 , @mibintc wrote: > I think it would be convenient to have an "unset" setting for the different > constrained modes, otherwise you need a boolean that says "no value was > provided for this option". But i'm a front

[PATCH] D62731: [RFC] Add support for options -fp-model= and -fp-speculation= : specify floating point behavior

2019-07-26 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. I actually don't have much of an opinion on what the command line argument form should be. It may be helpful for it to be the same as one of the commonly deployed compilers. The worst I think would be pretty close but with subtle differences. So if it can be made to work li

[PATCH] D65997: Add options rounding and exceptions to pragma fp

2019-08-09 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added inline comments. Comment at: clang/docs/LanguageExtensions.rst:3151 +value ``dynamic`` informs the compiler that it must not assume particular +rounding mode. This option is experimental, compiler does not guarantee to +process it in all cases. aaron.ba

[PATCH] D65994: Extended FPOptions with new attributes

2019-08-09 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. In D65994#1622840 , @aaron.ballman wrote: > In general, this seems reasonable, but is missing test code. The IRBuilder does have a strict FP mode setting now. When strict mode is enabled the (implemented) constrained intrinsics aut

[PATCH] D66092: [CodeGen] Generate constrained fp intrinsics depending on FPOptions

2019-08-12 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. Does this work for anything that uses TreeTransform, like C++ templates? Also, if any constrained intrinsics are used in a function then the entire function needs to be constrained. Is this handled anywhere? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D62731: [RFC] Add support for options -fp-model= and -fp-speculation= : specify floating point behavior

2019-08-15 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added inline comments. Comment at: clang/docs/UsersManual.rst:1307 + + ``precise `` Disables optimizations that are not value-safe on + floating-point data, although FP contraction (FMA) is enabled. Extra spaces? Comment at: clang/li

[PATCH] D62731: [RFC] Add support for options -fp-model= and -fp-speculation= : specify floating point behavior

2019-08-19 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. I don't believe I have any further comments. What do the front-end guys say? Comment at: clang/lib/CodeGen/CodeGenFunction.cpp:126 + case LangOptions::FPM_Precise: + case LangOptions::FPM_Fast: +break; andrew.w.kaylor wrote: > mibintc

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-06-26 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added inline comments. Comment at: include/llvm/IR/IntrinsicInst.h:235 + ebStrict ///< This corresponds to "fpexcept.strict". }; rjmccall wrote: > kpn wrote: > > rjmccall wrote: > > > Is it okay that `ebUnspecified` and `ebInvalid` overl

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-07-01 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 207378. kpn added a comment. Address review comments. Eliminate ConstrainedFPIntrinsic's ebInvalid and rmInvalid enumeration values and replace them with use of the Optional<> class. Adjust the rest of the patch to take that into account. ConstrainedFPIntrinsic

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-07-01 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn marked 3 inline comments as done. kpn added inline comments. Comment at: include/llvm/IR/IRBuilder.h:259 +return DefaultConstrainedRounding.getValue(); + } + rjmccall wrote: > Okay, so what are the invariants here now? It looks like, in order to enable

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-07-03 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn marked 2 inline comments as done. kpn added inline comments. Comment at: include/llvm/IR/IRBuilder.h:1324 + return CreateConstrainedFPBinOp(Intrinsic::experimental_constrained_fadd, + L, R, nullptr, Name); + rjmccall

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-07-03 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 207829. kpn added a comment. I was convinced in email that having the constrained intrinsics take fast math flags could be useful in some circumstances. The example that was given was that perhaps FMA contraction could be requested. So, when generating constrai

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-07-08 Thread Kevin P. Neal via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rL365339: Teach the IRBuilder about fadd and friends. (authored by kpn, committed by ). Herald added a project: LLVM. Chang

[PATCH] D53157: Teach the IRBuilder about constrained fadd and friends

2019-05-15 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn marked an inline comment as done. kpn added a comment. I'm waiting for a signoff from at least one front-end guy. I hope the mode setting that allows us to keep front ends from having to touch every use of the IRBuilder is something that works for clang. But I haven't heard anything from @r

[PATCH] D51372: FENV_ACCESS support for libm-style constrained intrinsics

2019-09-20 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn abandoned this revision. kpn added a comment. I believe Serge Pavlov has demonstrated a better way to do this. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D51372/new/ https://reviews.llvm.org/D51372 ___ cfe-commits mailing list cfe-com

[PATCH] D52839: Inform AST's UnaryOperator of FENV_ACCESS

2019-09-20 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn abandoned this revision. kpn added a comment. I believe Serge Pavlov has demonstrated a better way to do this. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D52839/new/ https://reviews.llvm.org/D52839 ___ cfe-commits mailing list cfe-com

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

2019-10-21 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. Does this work for C++? C++ templates? I only see C tests. Is there a way forward to support having the #pragma at the start of any block inside a function? The effect won't be restricted to that block, true, but the standard does say the #pragma is allowed. Repository:

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

2019-10-22 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. Baking into the front end the fact that the backend implementation is not yet complete doesn't strike me as a good idea. And the metadata arguments to the constrained intrinsics are designed to allow for correctly marked constrained intrinsics to be eventually treated prett

[PATCH] D80952: [FPEnv][Clang][Driver][WIP] Disable constrained floating point on targets lacking support.

2020-06-01 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. This currently triggers a failure in test "Clang :: Misc/warning-flags.c". Suggestions on how to fix that correctly are welcome. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80952/new/ https://reviews.llvm.org/D80952 _

[PATCH] D80952: [FPEnv][Clang][Driver][WIP] Disable constrained floating point on targets lacking support.

2020-06-01 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn created this revision. kpn added reviewers: cameron.mcinally, craig.topper, andrew.w.kaylor, spatel, wristow, nemanjai. Herald added subscribers: cfe-commits, arphaman. Herald added a project: clang. kpn added a comment. This currently triggers a failure in test "Clang :: Misc/warning-flags.c

[PATCH] D80952: [FPEnv][Clang][Driver][WIP] Disable constrained floating point on targets lacking support.

2020-06-02 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. In D80952#2067643 , @arsenm wrote: > In D80952#2067563 , @efriedma wrote: > > > The problem for the command-line arguments in particular is that they > > aren't really new; clang has been eatin

[PATCH] D76949: Replace subtract-from-zero float in version with fneg in PowerPC special fma compiler builtins

2020-04-03 Thread Kevin P. Neal via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGba87430cadb2: [PowerPC] Replace subtract-from-zero float in version with fneg in PowerPC… (authored by ajwock, committed by kpn). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https:/

[PATCH] D81178: [FPEnv] Initialization of C++ globals not strictfp aware

2020-06-04 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn created this revision. kpn added reviewers: rjmccall, pcc, mibintc. Herald added a project: clang. Herald added a subscriber: cfe-commits. The rules of the strictfp attribute say that if it is used inside a function then it must also be in the function definition. Initialization of C++ global

[PATCH] D81178: [FPEnv] Initialization of C++ globals not strictfp aware

2020-06-08 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn marked an inline comment as done. kpn added inline comments. Comment at: clang/lib/CodeGen/CodeGenFunction.h:4348 + /// Query for the use of constrained floating point math + bool isStrictFP() { return Builder.getIsFPConstrained(); } + rjmccall wrote: > How

[PATCH] D80952: [FPEnv][Clang][Driver] Disable constrained floating point on targets lacking support.

2020-06-11 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 270219. kpn retitled this revision from "[FPEnv][Clang][Driver][WIP] Disable constrained floating point on targets lacking support." to "[FPEnv][Clang][Driver] Disable constrained floating point on targets lacking support.". kpn added a comment. Herald added a s

[PATCH] D80952: [FPEnv][Clang][Driver] Disable constrained floating point on targets lacking support.

2020-07-06 Thread Kevin P. Neal via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rG39d2ae0afb23: [FPEnv][Clang][Driver] Disable constrained floating point on targets lacking… (authored by kpn). Changed pr

[PATCH] D80952: [FPEnv][Clang][Driver] Disable constrained floating point on targets lacking support.

2020-07-06 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. Already on it. I hope I got it now. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80952/new/ https://reviews.llvm.org/D80952 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D80952: [FPEnv][Clang][Driver] Disable constrained floating point on targets lacking support.

2020-07-07 Thread Kevin P. Neal via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rG39d2ae0afb23: [FPEnv][Clang][Driver] Disable constrained floating point on targets lacking… (authored by kpn). Changed pr

[PATCH] D80952: [FPEnv][Clang][Driver] Disable constrained floating point on targets lacking support.

2020-07-07 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 276166. kpn added a comment. Add the -fexperimental-strict-floating-point flag to enable on hosts that are not marked as supporting strict FP yet. Add test and documentation. Update tests to use the new flag. This eliminates the XFAIL lines and should keep the

[PATCH] D80952: [FPEnv][Clang][Driver] Disable constrained floating point on targets lacking support.

2020-07-09 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn marked 3 inline comments as done. kpn added a comment. Thanks for the reviews and the fast turnaround! I do appreciate it! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80952/new/ https://reviews.llvm.org/D80952 ___ cfe-commits mailing

[PATCH] D80952: [FPEnv][Clang][Driver] Disable constrained floating point on targets lacking support.

2020-07-10 Thread Kevin P. Neal via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGd4ce862f2aa8: Reland "[FPEnv][Clang][Driver] Disable constrained floating point on targets… (authored by kpn). Herald added a reviewer: dang. Changed prior to commit: https://reviews.llvm.org/D80952?vs=

[PATCH] D80952: [FPEnv][Clang][Driver] Disable constrained floating point on targets lacking support.

2020-07-10 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn marked an inline comment as done. kpn added inline comments. Comment at: clang/include/clang/Driver/Options.td:1246 HelpText<"Enables an experimental new pass manager in LLVM.">; +def fexperimental_strict_floating_point : Flag<["-"], "fexperimental-strict-floating-point">

[PATCH] D80952: [FPEnv][Clang][Driver] Disable constrained floating point on targets lacking support.

2020-06-22 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. Herald added a subscriber: wuzish. Ping? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80952/new/ https://reviews.llvm.org/D80952 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/ma

[PATCH] D80952: [FPEnv][Clang][Driver] Disable constrained floating point on targets lacking support.

2020-06-22 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 272530. kpn added a comment. Remove debugging command left in accidentally. Rebase. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80952/new/ https://reviews.llvm.org/D80952 Files: clang/include/clang/Basic/DiagnosticFrontendKinds.td clang/include/c

[PATCH] D82020: PowerPC-specific builtin constrained FP enablement

2020-06-25 Thread Kevin P. Neal via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG15edd7aaa714: [FPEnv] PowerPC-specific builtin constrained FP enablement (authored by ajwock, committed by kpn). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org

[PATCH] D80952: [FPEnv][Clang][Driver] Disable constrained floating point on targets lacking support.

2020-06-30 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. Ping. I'm really hoping to get this into 11. Otherwise we're going multiple releases with options that people already use causing crashes on most architectures. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D80952/new/ https://reviews.llvm.org/D80952 ___

[PATCH] D85920: [FPEnv][AST] WIP!!! For casts, keep FP options in trailing storage of CastExpr

2020-08-13 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn created this revision. kpn added reviewers: rjmccall, mibintc, shafik, sepavloff. kpn added a project: clang. Herald added subscribers: cfe-commits, jfb, martong. kpn requested review of this revision. This change allows FP options to be in the trailing storage of CastExpr. Needed for proper

[PATCH] D85960: [AST][FPEnv] Keep FP options in trailing storage of CastExpr

2020-08-14 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. You mentioned in D85920 a need to merge this review with that review. I don't think that's needed. This code here is farther along. It does everything that D85920 does and has necessary pieces implemented a

[PATCH] D85920: [FPEnv][AST] WIP!!! For casts, keep FP options in trailing storage of CastExpr

2020-08-17 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn planned changes to this revision. kpn added a comment. It would be better to go with D85960 . I'll hedge and keep this open until that one gets pushed. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85920/new/ h

[PATCH] D118259: [AArch64] Adjust aarch64-neon-intrinsics-constrained test and un-XFAIL

2022-03-17 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. It's been a while, but I think the aarch64-neon-intrinsics-constrained.c test is trimmed down from the aarch64-neon-intrinsics.c test. Shouldn't the constrained and non-constrained end-to-end tests be treated the same? Repository: rG LLVM Github Monorepo CHANGES SINCE L

[PATCH] D118259: [AArch64] Adjust aarch64-neon-intrinsics-constrained test and un-XFAIL

2022-03-17 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. In D118259#3389246 , @fhahn wrote: > In D118259#3389235 , @kpn wrote: > >> It's been a while, but I think the aarch64-neon-intrinsics-constrained.c >> test is trimmed down from the aarch64-ne

[PATCH] D118259: [AArch64] Adjust aarch64 constrained intrinsics tests and un-XFAIL

2022-04-12 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn accepted this revision. kpn added a comment. This revision is now accepted and ready to land. I trust you on the instruction set changes. LGTM. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D118259/new/ https://reviews.llvm.org/D118259 ___

[PATCH] D71854: [SystemZ] Use FNeg in s390x clang builtins

2020-01-02 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 235880. kpn added a comment. Update now-failing tests. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D71854/new/ https://reviews.llvm.org/D71854 Files: clang/lib/CodeGen/CGBuiltin.cpp clang/test/CodeGen/builtins-systemz-vector.c clang/test/CodeGen

[PATCH] D71854: [SystemZ] Use FNeg in s390x clang builtins

2020-01-02 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn closed this revision. kpn added a comment. My pleasure! Closed with commit 89d6c288ba5adb20d92142e9425f7ab79b8f159e . CHANGES SINCE LAST ACTION https://reviews.llvm.org/D71854/new/ https://reviews.llvm.org/D71854 __

[PATCH] D72722: [FPEnv] [SystemZ] Platform-specific builtin constrained FP enablement

2020-01-14 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn created this revision. kpn added a reviewer: uweigand. Herald added a project: clang. Herald added a subscriber: cfe-commits. When constrained floating point is enabled the SystemZ-specific builtins don't use constrained intrinsics in some cases. Fix that. Repository: rG LLVM Github Monor

[PATCH] D69272: Enable '#pragma STDC FENV_ACCESS' in frontend

2020-09-11 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. Say, in D80952 I added support for disabling strictfp support when a target doesn't support it. But it only applies to command line arguments. Is there any chance at all that relevant pragmas can also be disabled with the warning in the sa

[PATCH] D85920: [FPEnv][AST] WIP!!! For casts, keep FP options in trailing storage of CastExpr

2020-09-22 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn abandoned this revision. kpn added a comment. Unneeded since D85960 landed. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85920/new/ https://reviews.llvm.org/D85920

[PATCH] D92596: [FPEnv] Correct constrained metadata in fp16-ops-strict.c

2020-12-08 Thread Kevin P. Neal via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGacd4950d4f1e: [FPEnv] Correct constrained metadata in fp16-ops-strict.c (authored by kpn). Changed prior to commit: https://reviews.llvm.org/D9259

[PATCH] D93134: [FPEnv] Teach the IRBuilder about invoke's correct use of the strictfp attribute.

2020-12-11 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn created this revision. kpn added reviewers: spatel, rjmccall, andrew.w.kaylor, mibintc, sepavloff. kpn requested review of this revision. Herald added projects: clang, LLVM. Herald added subscribers: llvm-commits, cfe-commits. Similar to D69312 , and documented

[PATCH] D93134: [FPEnv] Teach the IRBuilder about invoke's correct use of the strictfp attribute.

2020-12-15 Thread Kevin P. Neal via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG67a1ffd88ac0: [FPEnv] Teach the IRBuilder about invoke's correct use of the strictfp… (authored by kpn). Repository: rG LLVM Github Monorepo CHAN

[PATCH] D88913: [FPEnv] Use strictfp metadata in casting nodes

2020-11-04 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. Update for review comments. Comment at: clang/test/CodeGen/builtin_float_strictfp.c:1 +// RUN: %clang_cc1 -emit-llvm -triple x86_64-windows-pc -ffp-exception-behavior=maytrap -o - %s | FileCheck %s --check-prefixes=CHECK,FP16 +// RUN: %clang_cc1 -emit-llv

[PATCH] D90921: [Clang][AArch64] Remove unused prefix in constrained rounding test

2020-11-06 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn accepted this revision. kpn added a comment. This revision is now accepted and ready to land. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D90921/new/ https://reviews.llvm.org/D90921 ___ cfe-com

[PATCH] D88987: [FPEnv][Clang][Driver] Use MarshallingInfoFlag for -fexperimental-strict-floating-point

2020-11-11 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. No worries! The option does already have tests that verify correct operation. Comment at: clang/include/clang/Driver/Options.td:1286 + HelpText<"Enables experimental strict floating point in LLVM.">, + MarshallingInfoFlag<"LangOpts->ExpStrictFP", "false"

[PATCH] D88987: [FPEnv][Clang][Driver] Use MarshallingInfoFlag for -fexperimental-strict-floating-point

2020-11-11 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn updated this revision to Diff 304557. kpn added a comment. Update for review comments. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D88987/new/ https://reviews.llvm.org/D88987 Files: clang/include/clang/Driver/Options.td clang/lib/Frontend/CompilerInvocation.cpp Index: clang/

[PATCH] D88987: [FPEnv][Clang][Driver] Use MarshallingInfoFlag for -fexperimental-strict-floating-point

2020-11-12 Thread Kevin P. Neal via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGac523d2de51c: [FPEnv][Clang][Driver] Use MarshallingInfoFlag for -fexperimental-strict… (authored by kpn). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D8898

[PATCH] D88987: [FPEnv][Clang][Driver] Use MarshallingInfoFlag for -fexperimental-strict-floating-point

2020-10-07 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn created this revision. kpn added a reviewer: dang. kpn added a project: clang. Herald added subscribers: cfe-commits, dexonsmith. kpn requested review of this revision. As of D80952 we are disabling strict floating point on all hosts except those that are exp

[PATCH] D88913: [FPEnv] Use strictfp metadata in casting nodes

2020-10-08 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added inline comments. Comment at: clang/lib/CodeGen/CodeGenFunction.cpp:139 + + switch (E->getStmtClass()) { + case Stmt::UnaryOperatorClass: { sepavloff wrote: > Actually this is not correct, because subclass relations are not preserved in > this case. F

[PATCH] D88913: [FPEnv] Use strictfp metadata in casting nodes

2020-10-13 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added inline comments. Comment at: clang/lib/CodeGen/CodeGenFunction.h:618-619 FPOptions OldFPFeatures; +llvm::fp::ExceptionBehavior OldExcept; +llvm::RoundingMode OldRounding; Optional FMFGuard; sepavloff wrote: > Is it possible to merge th

[PATCH] D92122: [FPEnv] clang should get from the AST the metadata for constrained FP builtins

2020-11-25 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn created this revision. kpn added reviewers: sepavloff, mibintc, rjmccall. kpn added a project: clang. Herald added a subscriber: cfe-commits. kpn requested review of this revision. Currently clang is not correctly retrieving from the AST the metadata for constrained FP builtins. This patch fi

[PATCH] D92122: [FPEnv] clang should get from the AST the metadata for constrained FP builtins

2020-11-30 Thread Kevin P. Neal via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGabfbc5579bd4: [FPEnv] clang should get from the AST the metadata for constrained FP builtins (authored by kpn). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/

[PATCH] D92122: [FPEnv] clang should get from the AST the metadata for constrained FP builtins

2020-11-30 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn added a comment. Thanks for the quick turnaround! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D92122/new/ https://reviews.llvm.org/D92122 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http

[PATCH] D92596: [FPEnv] Correct constrained metadata in fp16-ops-strict.c

2020-12-03 Thread Kevin P. Neal via Phabricator via cfe-commits
kpn created this revision. kpn added reviewers: sepavloff, mibintc. kpn added a project: clang. kpn requested review of this revision. Herald added a subscriber: cfe-commits. This test shows we're in some cases not getting strictfp information from the AST. Correct that. Repository: rG LLVM G

  1   2   >