Skip to main content

AtomicRequest

Trait AtomicRequest 

Source
pub trait AtomicRequest: Debug {
    // Required methods
    fn op(&self) -> AtomicOp;
    fn width(&self) -> AtomicWidth;
    fn req_id(&self) -> u16;
    fn tag(&self) -> u8;
    fn address(&self) -> u64;
    fn operand0(&self) -> u64;
    fn operand1(&self) -> Option<u64>;
}
Expand description

Atomic Request trait: header fields and operand(s) for atomic op TLPs. Use new_atomic_req() to obtain a trait object from raw packet bytes.

Required Methods§

Source

fn op(&self) -> AtomicOp

Returns the atomic operation type.

Source

fn width(&self) -> AtomicWidth

Returns the operand width (32-bit or 64-bit).

Source

fn req_id(&self) -> u16

Returns the 16-bit Requester ID.

Source

fn tag(&self) -> u8

Returns the 8-bit Tag field.

Source

fn address(&self) -> u64

Returns the target address.

Source

fn operand0(&self) -> u64

Primary operand: addend (FetchAdd), new value (Swap), compare value (CAS)

Source

fn operand1(&self) -> Option<u64>

Second operand: swap value for CAS; None for FetchAdd and Swap

Implementors§