]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
fix memory order of `_Py_atomic_store_uint_release` (#141562)
authorSubbaraoGarlapati <53627478+SubbaraoGarlapati@users.noreply.github.com>
Mon, 17 Nov 2025 11:23:12 +0000 (06:23 -0500)
committerGitHub <noreply@github.com>
Mon, 17 Nov 2025 11:23:12 +0000 (16:53 +0530)
Include/cpython/pyatomic_std.h

index 69a8b9e615ea5ffc6285da638eb152c9a601807a..7176f667a4082cff50aa6226f1a099b62b48173f 100644 (file)
@@ -948,14 +948,6 @@ _Py_atomic_store_ushort_relaxed(unsigned short *obj, unsigned short value)
                           memory_order_relaxed);
 }
 
-static inline void
-_Py_atomic_store_uint_release(unsigned int *obj, unsigned int value)
-{
-    _Py_USING_STD;
-    atomic_store_explicit((_Atomic(unsigned int)*)obj, value,
-                          memory_order_relaxed);
-}
-
 static inline void
 _Py_atomic_store_long_relaxed(long *obj, long value)
 {
@@ -1031,6 +1023,14 @@ _Py_atomic_store_int_release(int *obj, int value)
                           memory_order_release);
 }
 
+static inline void
+_Py_atomic_store_uint_release(unsigned int *obj, unsigned int value)
+{
+    _Py_USING_STD;
+    atomic_store_explicit((_Atomic(unsigned int)*)obj, value,
+                          memory_order_release);
+}
+
 static inline void
 _Py_atomic_store_ssize_release(Py_ssize_t *obj, Py_ssize_t value)
 {