rnk added inline comments.
================ Comment at: lib/CodeGen/CGBuiltin.cpp:2730 + llvm::AtomicOrdering::SequentiallyConsistent); + return Builder.CreateSub(RMWI, ConstantInt::get(IntTy, 1)); } ---------------- Can you make a helper similar to MakeBinaryAtomicValue for inc/dec and share this code with the 16 and 32-bit atomic increment implementations? You can do something like `Builder.CreateBinOp(Inc ? Instruction::Add : Instruction::Sub, ...)` https://reviews.llvm.org/D25576 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits