diff options
author | Simon Pilgrim <llvm-dev@redking.me.uk> | 2019-08-30 15:17:37 +0000 |
---|---|---|
committer | Simon Pilgrim <llvm-dev@redking.me.uk> | 2019-08-30 15:17:37 +0000 |
commit | c2fed1dc8ab96c669bea32ab63d262220a9ebb07 (patch) | |
tree | 5763b646febd70077516e82714d247f39d5ca77b /llvm/lib/CodeGen/SelectionDAG | |
parent | a5590950549719d0d9ea69ed164b0c8c0f4e02e6 (diff) | |
download | bcm5719-llvm-c2fed1dc8ab96c669bea32ab63d262220a9ebb07.tar.gz bcm5719-llvm-c2fed1dc8ab96c669bea32ab63d262220a9ebb07.zip |
[DAGCombine] visitVSELECT - remove duplicate getOperand calls. NFCI.
llvm-svn: 370478
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG')
-rw-r--r-- | llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp b/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp index d06fc7a3d66..bf87de9f748 100644 --- a/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp @@ -8730,10 +8730,9 @@ SDValue DAGCombiner::visitVSELECT(SDNode *N) { // This is OK if we don't care about what happens if either operand is a // NaN. // - if (N0.hasOneUse() && isLegalToCombineMinNumMaxNum(DAG, N0.getOperand(0), - N0.getOperand(1), TLI)) { - if (SDValue FMinMax = combineMinNumMaxNum( - DL, VT, N0.getOperand(0), N0.getOperand(1), N1, N2, CC, TLI, DAG)) + if (N0.hasOneUse() && isLegalToCombineMinNumMaxNum(DAG, LHS, RHS, TLI)) { + if (SDValue FMinMax = + combineMinNumMaxNum(DL, VT, LHS, RHS, N1, N2, CC, TLI, DAG)) return FMinMax; } |