[PATCH] D52811: [COFF, ARM64] Add _InterlockedAdd intrinsic

Eli Friedman via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Oct 2 17:23:40 PDT 2018


efriedma added inline comments.


================
Comment at: test/CodeGen/ms-intrinsics.c:379
+// CHECK:   [[RESULT:%[0-9]+]] = atomicrmw add i32* %value, i32 %mask seq_cst
+// CHECK:   ret i32 [[RESULT:%[0-9]+]]
+// CHECK: }
----------------
Missing "add" instruction.  _InterlockedAdd is supposed to return the sum, not the original value in memory.


Repository:
  rC Clang

https://reviews.llvm.org/D52811





More information about the cfe-commits mailing list