1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-24 03:33:20 +01:00

On Darwin targets, only use vfma etc. if the source use fma() intrinsic explicitly.

llvm-svn: 154689
This commit is contained in:
Evan Cheng 2012-04-13 18:59:28 +00:00
parent 0387e6b701
commit 3499593c7e
2 changed files with 6 additions and 3 deletions

View File

@ -219,8 +219,11 @@ def UseFPVMLx : Predicate<"Subtarget->useFPVMLx()">;
// Prefer fused MAC for fp mul + add over fp VMLA / VMLS if they are available.
// But only select them if more precision in FP computation is allowed.
def UseFusedMAC : Predicate<"!TM.Options.NoExcessFPPrecision">;
def DontUseFusedMAC : Predicate<"!Subtarget->hasVFP4()">;
// Do not use them for Darwin platforms.
def UseFusedMAC : Predicate<"!TM.Options.NoExcessFPPrecision && "
"!Subtarget->isTargetDarwin()">;
def DontUseFusedMAC : Predicate<"!Subtarget->hasVFP4() || "
"Subtarget->isTargetDarwin()">;
//===----------------------------------------------------------------------===//
// ARM Flag Definitions.

View File

@ -1,4 +1,4 @@
; RUN: llc < %s -march=arm -mattr=+neon,+vfp4 | FileCheck %s
; RUN: llc < %s -mtriple=armv7-eabi -mattr=+neon,+vfp4 | FileCheck %s
; Check generated fused MAC and MLS.
define double @fusedMACTest1(double %d1, double %d2, double %d3) {