mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-04-06 09:44:39 +00:00
X86: Fix accidentally swapped operands.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165871 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
07525a6be6
commit
f8b65aaf39
@ -9158,7 +9158,7 @@ SDValue X86TargetLowering::LowerSELECT(SDValue Op, SelectionDAG &DAG) const {
|
||||
// Blacklist CopyFromReg to avoid partial register stalls.
|
||||
T1.getOpcode() != ISD::CopyFromReg && T2.getOpcode()!=ISD::CopyFromReg){
|
||||
SDVTList VTs = DAG.getVTList(T1.getValueType(), MVT::Glue);
|
||||
SDValue Cmov = DAG.getNode(X86ISD::CMOV, DL, VTs, T1, T2, CC, Cond);
|
||||
SDValue Cmov = DAG.getNode(X86ISD::CMOV, DL, VTs, T2, T1, CC, Cond);
|
||||
return DAG.getNode(ISD::TRUNCATE, DL, Op.getValueType(), Cmov);
|
||||
}
|
||||
}
|
||||
|
@ -350,10 +350,10 @@ define i8 @test18(i32 %x, i8 zeroext %a, i8 zeroext %b) nounwind {
|
||||
%sel = select i1 %cmp, i8 %a, i8 %b
|
||||
ret i8 %sel
|
||||
; CHECK: test18:
|
||||
; CHECK: cmpl $15
|
||||
; CHECK: cmovll
|
||||
; CHECK: cmpl $15, %edi
|
||||
; CHECK: cmovgel %edx
|
||||
|
||||
; ATOM: test18:
|
||||
; ATOM: cmpl $15
|
||||
; ATOM: cmovll
|
||||
; ATOM: cmpl $15, %edi
|
||||
; ATOM: cmovgel %edx
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user