Struct CrossGpuBarrierResult
- Namespace
- DotCompute.Abstractions.Barriers
- Assembly
- DotCompute.Abstractions.dll
Result of barrier synchronization operation.
public readonly struct CrossGpuBarrierResult : IEquatable<CrossGpuBarrierResult>
- Implements
- Inherited Members
Properties
ArrivalTimestamps
HLC timestamps of each participant's arrival. Indexed by GPU ID (0-based).
[SuppressMessage("Performance", "CA1819:Properties should not return arrays", Justification = "Array provides optimal performance for GPU memory transfers")]
public required HlcTimestamp[] ArrivalTimestamps { get; init; }
Property Value
ErrorMessage
Error message if barrier failed (null if successful).
public string? ErrorMessage { get; init; }
Property Value
ReleaseTimestamp
Release timestamp (max HLC of all participant arrivals). Provides total ordering for post-barrier operations.
public HlcTimestamp ReleaseTimestamp { get; init; }
Property Value
Success
Indicates whether the barrier completed successfully.
public bool Success { get; init; }
Property Value
WaitTime
Total time spent waiting at the barrier.
public TimeSpan WaitTime { get; init; }
Property Value
Methods
Equals(CrossGpuBarrierResult)
Indicates whether the current object is equal to another object of the same type.
public bool Equals(CrossGpuBarrierResult other)
Parameters
otherCrossGpuBarrierResultAn object to compare with this object.
Returns
Equals(object?)
Indicates whether this instance and a specified object are equal.
public override bool Equals(object? obj)
Parameters
objobjectThe object to compare with the current instance.
Returns
- bool
true if
objand this instance are the same type and represent the same value; otherwise, false.
GetHashCode()
Returns the hash code for this instance.
public override int GetHashCode()
Returns
- int
A 32-bit signed integer that is the hash code for this instance.
Operators
operator ==(CrossGpuBarrierResult, CrossGpuBarrierResult)
Determines whether two CrossGpuBarrierResult instances are equal.
public static bool operator ==(CrossGpuBarrierResult left, CrossGpuBarrierResult right)
Parameters
leftCrossGpuBarrierResultrightCrossGpuBarrierResult
Returns
operator !=(CrossGpuBarrierResult, CrossGpuBarrierResult)
Determines whether two CrossGpuBarrierResult instances are not equal.
public static bool operator !=(CrossGpuBarrierResult left, CrossGpuBarrierResult right)
Parameters
leftCrossGpuBarrierResultrightCrossGpuBarrierResult