[Git][ghc/ghc][wip/T22010] Fix atomic_inc64 declaration
Jaro Reinders (@Noughtmare)
gitlab at gitlab.haskell.org
Wed Jun 14 12:49:20 UTC 2023
Jaro Reinders pushed to branch wip/T22010 at Glasgow Haskell Compiler / GHC
Commits:
be12acc6 by Jaro Reinders at 2023-06-14T14:49:15+02:00
Fix atomic_inc64 declaration
- - - - -
1 changed file:
- rts/include/stg/SMP.h
Changes:
=====================================
rts/include/stg/SMP.h
=====================================
@@ -94,7 +94,7 @@ EXTERN_INLINE StgWord atomic_inc(StgVolatilePtr p, StgWord n);
* return ((*p) += n);
* }
*/
-EXTERN_INLINE StgWord64 atomic_inc64(StgVolatilePtr p, StgWord64 n);
+EXTERN_INLINE StgWord64 atomic_inc64(StgWord64 volatile* p, StgWord64 n);
/*
* Atomic decrement
@@ -440,7 +440,7 @@ atomic_inc(StgVolatilePtr p, StgWord incr)
}
EXTERN_INLINE StgWord64
-atomic_inc64(StgVolatilePtr p, StgWord64 incr)
+atomic_inc64(StgWord64 volatile* p, StgWord64 incr)
{
#if defined(HAVE_C11_ATOMICS)
return __atomic_add_fetch(p, incr, __ATOMIC_SEQ_CST);
@@ -678,9 +678,9 @@ atomic_inc(StgVolatilePtr p, StgWord incr)
}
-EXTERN_INLINE StgWord64 atomic_inc64(StgVolatilePtr p, StgWord64 incr);
+EXTERN_INLINE StgWord64 atomic_inc64(StgWord64 volatile* p, StgWord64 incr);
EXTERN_INLINE StgWord64
-atomic_inc64(StgVolatilePtr p, StgWord64 incr)
+atomic_inc64(StgWord64 volatile* p, StgWord64 incr)
{
return ((*p) += incr);
}
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/be12acc6f7c3812ed4641d59505dae8fd6079540
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/be12acc6f7c3812ed4641d59505dae8fd6079540
You're receiving this email because of your account on gitlab.haskell.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20230614/a7d2f2d7/attachment-0001.html>
More information about the ghc-commits
mailing list