include/Zycore/Atomic.h(3)

πŸ“¦
version 1.5.2 Β· 2 versions
, in ubuntu resolute, ubuntu stonking

πŸ’– include/Zycore/Atomic.h(3) β€” Library Functions Manual πŸ’–

okay bestie, buckle up, we're diving into the atomic intrinsics header 🧚✨ this one lives in the Library Functions Manual, and it's genuinely giving "cross compiler chaos but make it safe" energy.


🌸 NAME 🌸

include/Zycore/Atomic.h β€” no cap, that's literally the whole name, she's self-titled and she knows it πŸ’…


✨ SYNOPSIS ✨

#include <Zycore/Defines.h>
#include <Zycore/Types.h>

πŸŽ€ Classes πŸŽ€

  • struct ZyanAtomic32_
  • struct ZyanAtomic64_
  • struct ZyanAtomicPointer_

πŸŽ€ Macros πŸŽ€

  • #define ZYAN_ATOMIC_COMPARE_EXCHANGE(destination, comparand, value)
  • #define ZYAN_ATOMIC_INCREMENT(destination)
  • #define ZYAN_ATOMIC_DECREMENT(destination)
  • #define ZYAN_ATOMIC_COMPARE_EXCHANGE32(destination, comparand, value)
  • #define ZYAN_ATOMIC_INCREMENT32(destination)
  • #define ZYAN_ATOMIC_DECREMENT32(destination)
  • #define ZYAN_ATOMIC_COMPARE_EXCHANGE64(destination, comparand, value)
  • #define ZYAN_ATOMIC_INCREMENT64(destination)
  • #define ZYAN_ATOMIC_DECREMENT64(destination)

πŸŽ€ Typedefs πŸŽ€

  • typedef struct ZyanAtomic32_ ZyanAtomic32
  • typedef struct ZyanAtomic64_ ZyanAtomic64
  • typedef struct ZyanAtomicPointer_ ZyanAtomicPointer

πŸ¦‹ Detailed Description πŸ¦‹

Cross compiler atomic intrinsics. that's it, that's the whole vibe β€” she makes atomics work across compilers so you don't have to cry about it πŸ™ˆ


πŸ”₯ Macro Definition Documentation πŸ”₯

#define ZYAN_ATOMIC_COMPARE_EXCHANGE( destination, comparand, value)

Value:

ZyanAtomicCompareExchange((ZyanAtomicPointer*)&(destination), (comparand), (value))

casts destination to a ZyanAtomicPointer* and hands the whole trio off to ZyanAtomicCompareExchange. pointer flavored, as a treat 🫢

#define ZYAN_ATOMIC_COMPARE_EXCHANGE32( destination, comparand, value)

Value:

ZyanAtomicCompareExchange32((ZyanAtomic32*)&(destination), (comparand), (value))

same energy but she's on her 32 arc β€” casts to ZyanAtomic32* and calls ZyanAtomicCompareExchange32.

#define ZYAN_ATOMIC_COMPARE_EXCHANGE64( destination, comparand, value)

Value:

ZyanAtomicCompareExchange64((ZyanAtomic64*)&(destination), (comparand), (value))

and the 64 version, casting to ZyanAtomic64* and calling ZyanAtomicCompareExchange64. big numbers, big feelings πŸ’œ

#define ZYAN_ATOMIC_DECREMENT( destination)

Value:

ZyanAtomicDecrement((ZyanAtomicPointer*)&(destination));

casts destination to ZyanAtomicPointer* and calls ZyanAtomicDecrement. (yes there's a semicolon chillin' at the end, that's just how she wrote it, iconic)

#define ZYAN_ATOMIC_DECREMENT32( destination)

Value:

ZyanAtomicDecrement32((ZyanAtomic32*)&(destination));

the 32-bit decrement, casting to ZyanAtomic32* β†’ ZyanAtomicDecrement32. semicolon included, no notes 😌

#define ZYAN_ATOMIC_DECREMENT64( destination)

Value:

ZyanAtomicDecrement64((ZyanAtomic64*)&(destination));

the 64-bit decrement, casting to ZyanAtomic64* β†’ ZyanAtomicDecrement64. still got that trailing semicolon, she's consistent like that ⭐

#define ZYAN_ATOMIC_INCREMENT( destination)

Value:

ZyanAtomicIncrement((ZyanAtomicPointer*)&(destination));

casts to ZyanAtomicPointer* and calls ZyanAtomicIncrement. go up, bestie πŸ“ˆ

#define ZYAN_ATOMIC_INCREMENT32( destination)

Value:

ZyanAtomicIncrement32((ZyanAtomic32*)&(destination));

cast to ZyanAtomic32*, call ZyanAtomicIncrement32, trailing semicolon and all πŸ“

#define ZYAN_ATOMIC_INCREMENT64( destination)

Value:

ZyanAtomicIncrement64((ZyanAtomic64*)&(destination));

cast to ZyanAtomic64*, call ZyanAtomicIncrement64. last one, and she ate πŸ’…πŸ”₯


πŸ‘‘ Author πŸ‘‘

Generated automatically by Doxygen for Zycore from the source code. so like… not a human, a robot did this, and honestly? she served πŸ€–βœ¨

aaaaand that's the whole page bestie, no crumbs left 🌈 the footer energy is: this is Zycore, Version 1.5.2.0, and the page is include/Zycore/Atomic.h(3) β€” that's it, that's the sign-off, mwah πŸ’–πŸŽ€πŸ¦‹

πŸ“¦ where this page comes from