Lines Matching refs:Orig
30 LoadInst *Orig = Builder.CreateLoad(Ptr); in LowerAtomicCmpXchgInst() local
31 Value *Equal = Builder.CreateICmpEQ(Orig, Cmp); in LowerAtomicCmpXchgInst()
32 Value *Res = Builder.CreateSelect(Equal, Val, Orig); in LowerAtomicCmpXchgInst()
35 Res = Builder.CreateInsertValue(UndefValue::get(CXI->getType()), Orig, 0); in LowerAtomicCmpXchgInst()
48 LoadInst *Orig = Builder.CreateLoad(Ptr); in LowerAtomicRMWInst() local
57 Res = Builder.CreateAdd(Orig, Val); in LowerAtomicRMWInst()
60 Res = Builder.CreateSub(Orig, Val); in LowerAtomicRMWInst()
63 Res = Builder.CreateAnd(Orig, Val); in LowerAtomicRMWInst()
66 Res = Builder.CreateNot(Builder.CreateAnd(Orig, Val)); in LowerAtomicRMWInst()
69 Res = Builder.CreateOr(Orig, Val); in LowerAtomicRMWInst()
72 Res = Builder.CreateXor(Orig, Val); in LowerAtomicRMWInst()
75 Res = Builder.CreateSelect(Builder.CreateICmpSLT(Orig, Val), in LowerAtomicRMWInst()
76 Val, Orig); in LowerAtomicRMWInst()
79 Res = Builder.CreateSelect(Builder.CreateICmpSLT(Orig, Val), in LowerAtomicRMWInst()
80 Orig, Val); in LowerAtomicRMWInst()
83 Res = Builder.CreateSelect(Builder.CreateICmpULT(Orig, Val), in LowerAtomicRMWInst()
84 Val, Orig); in LowerAtomicRMWInst()
87 Res = Builder.CreateSelect(Builder.CreateICmpULT(Orig, Val), in LowerAtomicRMWInst()
88 Orig, Val); in LowerAtomicRMWInst()
92 RMWI->replaceAllUsesWith(Orig); in LowerAtomicRMWInst()