[llvm] r225984 - Override the TLI callback enableAggressiveFMAFusion and return true. Indeed, fmul, fmadd and fadd nodes cost the same number of cycles, so we can enable more combining heuristics to produce more fmadd nodes.

Olivier Sallenave ol.sall at gmail.com
Wed Jan 14 07:42:07 PST 2015


Hal,

http://llvm.org/viewvc/llvm-project?rev=225987&view=rev

Thanks,
Olivier

2015-01-14 10:02 GMT-05:00 Hal Finkel <hfinkel at anl.gov>:

> Hi Olivier,
>
> Please also commit a regression test (adapting them from the PPC tests is
> obviously fine).
>
>  -Hal
>
> ----- Original Message -----
> > From: "Olivier Sallenave" <ohsallen at us.ibm.com>
> > To: llvm-commits at cs.uiuc.edu
> > Sent: Wednesday, January 14, 2015 8:47:24 AM
> > Subject: [llvm] r225984 - Override the TLI callback
> enableAggressiveFMAFusion and return true. Indeed, fmul,  fmadd
> > and fadd nodes cost the same number of cycles,        so we can enable
> more combining heuristics to produce more fmadd
> > nodes.
> >
> > Author: ohsallen
> > Date: Wed Jan 14 08:47:24 2015
> > New Revision: 225984
> >
> > URL: http://llvm.org/viewvc/llvm-project?rev=225984&view=rev
> > Log:
> > Override the TLI callback enableAggressiveFMAFusion and return true.
> > Indeed, fmul, fmadd and fadd nodes cost the same number of cycles,
> > so we can enable more combining heuristics to produce more fmadd
> > nodes.
> >
> > Modified:
> >     llvm/trunk/lib/Target/NVPTX/NVPTXISelLowering.h
> >
> > Modified: llvm/trunk/lib/Target/NVPTX/NVPTXISelLowering.h
> > URL:
> >
> http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/NVPTX/NVPTXISelLowering.h?rev=225984&r1=225983&r2=225984&view=diff
> >
> ==============================================================================
> > --- llvm/trunk/lib/Target/NVPTX/NVPTXISelLowering.h (original)
> > +++ llvm/trunk/lib/Target/NVPTX/NVPTXISelLowering.h Wed Jan 14
> > 08:47:24 2015
> > @@ -507,6 +507,8 @@ public:
> >
> >    bool isFMAFasterThanFMulAndFAdd(EVT) const override { return true;
> >    }
> >
> > +  bool enableAggressiveFMAFusion(EVT VT) const override { return
> > true; }
> > +
> >  private:
> >    const NVPTXSubtarget &nvptxSubtarget; // cache the subtarget here
> >
> >
> >
> > _______________________________________________
> > llvm-commits mailing list
> > llvm-commits at cs.uiuc.edu
> > http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
> >
>
> --
> Hal Finkel
> Assistant Computational Scientist
> Leadership Computing Facility
> Argonne National Laboratory
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150114/e35d3cec/attachment.html>


More information about the llvm-commits mailing list