Hi, clang deals with #pragma STDC FP_CONTRACT and updates the setting of FPOptions::fp_contract, but how is this made use of in the back end? Is there some way to find out, for any given pair of floating-point operations, whether they can be contracted into one (according to their local pragma settings), or is this not yet implemented? Al -- IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.
On Jun 12, 2011, at 1:51 PM, Alasdair Grant wrote:> Hi, > > clang deals with #pragma STDC FP_CONTRACT and updates the setting of > FPOptions::fp_contract, but how is this made use of in the back end? > Is there some way to find out, for any given pair of floating-point > operations, whether they can be contracted into one (according to > their local pragma settings), or is this not yet implemented?Not yet implemented. Propagating this through the optimizer is a large amount of work. We do have various global variables in include/llvm/Target/TargetOptions.h that get set for -ffast-math and other global settings, but these are huge hacks. -Chris
Maybe Matching Threads
- defaults for FP contraction [e.g. fused multiply-add]: suggestion and patch to be slightly more aggressive and to make Clang`s optimization settings closer to having the same meaning as when they are given to GCC [at least for "-O3"]
- [cfe-dev] [RFC] FP Contract = fast?
- [cfe-dev] [RFC] FP Contract = fast?
- [cfe-dev] [RFC] FP Contract = fast?
- [RFC] FP Contract = fast?