class · System.Threading

AtomicI32

public class System.Threading.AtomicI32 : System.Any

An i32 that threads change together (each operation is atomic). Add, Increment and Decrement give the new value, Exchange and CompareExchange the old one.

Kind
class
Namespace
System.Threading
Assembly
System.Core
Access
public, final
Source file
Threading.ant

Inheritance

Base classes
Any AtomicI32

Constructors

constructor AtomicI32()
#
constructor AtomicI32(value: i32)
#

Properties

property Value: i32
#

Methods

method Load() -> i32
#
method Store(v: i32) -> void
#
method Add(delta: i32) -> i32
#
method Increment() -> i32
#
method Decrement() -> i32
#
method Exchange(v: i32) -> i32
#
method CompareExchange(v: i32, comparand: i32) -> i32
#

Sets v if the value is comparand: the value before.

Private and internal members (6)

field value: i32
#

private

static method LoadAt(at: i32*) -> i32
#

private static

static method StoreAt(at: i32*, value: i32) -> void
#

private static

static method AddAt(at: i32*, value: i32) -> i32
#

private static

static method ExchangeAt(at: i32*, value: i32) -> i32
#

private static

static method CompareAt(at: i32*, expected: i32, value: i32) -> i32
#

private static

Inherited members (5)

Source

AtomicI32 as Larva HIR, decompiled from its Larva HIR.

System.Threading.AtomicI32.hir
// An i32 that threads change together (each operation is atomic). Add, Increment and Decrement give the new value,
// Exchange and CompareExchange the old one.
public class System.Threading.AtomicI32 : System.Any
{
    field value: i32
    static method LoadAt(at: i32*) -> i32
    static method StoreAt(at: i32*, value: i32) -> void
    static method AddAt(at: i32*, value: i32) -> i32
    static method ExchangeAt(at: i32*, value: i32) -> i32
    static method CompareAt(at: i32*, expected: i32, value: i32) -> i32
    constructor AtomicI32()
    constructor AtomicI32(value: i32)
    method Load() -> i32
    method Store(v: i32) -> void
    method Add(delta: i32) -> i32
    method Increment() -> i32
    method Decrement() -> i32
    method Exchange(v: i32) -> i32
    // Sets `v` if the value is `comparand`: the value before.
    method CompareExchange(v: i32, comparand: i32) -> i32
    property Value: i32
}
Esc