add input/output register comments
authorJacob Lifshay <programmerjake@gmail.com>
Fri, 8 Jul 2022 06:15:19 +0000 (23:15 -0700)
committerJacob Lifshay <programmerjake@gmail.com>
Fri, 8 Jul 2022 06:15:19 +0000 (23:15 -0700)
openpower/atomics.mdwn

index 79ee04f26542a9c0ccf105fe0fa3afde9f02892c..0ac92a5566d6df60e6f50553bfbcf825caf886a2 100644 (file)
@@ -57,11 +57,13 @@ not_eq:
 `atomic_load_acquire` is 4 instructions, including a branch and an unnecessarily-strong memory fence:
 
 ```
+# address in r3
     ld 3, 0(3)
     cmpw 0, 3, 3
     bne- skip
     isync
 skip:
+# output in r3
 ```
 
 Having single atomic operations is useful for implementations that want to send atomic operations to a shared cache since they can be more efficient to execute there, rather than having to move a whole cache block. Relying exclusively on