diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2025-02-28 10:32:22 +0000 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2025-03-07 10:39:29 +0000 |
commit | 84e5ce68c0c2d52d97a66ff2f53697f9ced190a8 (patch) | |
tree | a914c5afe2f80ab6d10dff2897621ad021ce6d86 /include | |
parent | 02ae315467cee589d02dfb89e13a2a6a8de09fc5 (diff) | |
download | qemu-84e5ce68c0c2d52d97a66ff2f53697f9ced190a8.zip qemu-84e5ce68c0c2d52d97a66ff2f53697f9ced190a8.tar.gz qemu-84e5ce68c0c2d52d97a66ff2f53697f9ced190a8.tar.bz2 |
include/exec/memop.h: Expand comment for MO_ATOM_SUBALIGN
Expand the example in the comment documenting MO_ATOM_SUBALIGN,
to be clearer about the atomicity guarantees it represents.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-id: 20250228103222.1838913-1-peter.maydell@linaro.org
Diffstat (limited to 'include')
-rw-r--r-- | include/exec/memop.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/include/exec/memop.h b/include/exec/memop.h index acdb40a..407a47d 100644 --- a/include/exec/memop.h +++ b/include/exec/memop.h @@ -91,8 +91,12 @@ typedef enum MemOp { * Depending on alignment, one or both will be single-copy atomic. * This is the atomicity e.g. of Arm FEAT_LSE2 LDP. * MO_ATOM_SUBALIGN: the operation is single-copy atomic by parts - * by the alignment. E.g. if the address is 0 mod 4, then each - * 4-byte subobject is single-copy atomic. + * by the alignment. E.g. if an 8-byte value is accessed at an + * address which is 0 mod 8, then the whole 8-byte access is + * single-copy atomic; otherwise, if it is accessed at 0 mod 4 + * then each 4-byte subobject is single-copy atomic; otherwise + * if it is accessed at 0 mod 2 then the four 2-byte subobjects + * are single-copy atomic. * This is the atomicity e.g. of IBM Power. * MO_ATOM_NONE: the operation has no atomicity requirements. * |