Skip to content

Commit f8ac1a7

Browse files
NoSanityHereFirestar99
authored andcommitted
Float atomic operations doc fix
The docs for float atomics previously said they were doing integer operations.
1 parent 7584a01 commit f8ac1a7

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

crates/spirv-std/src/arch/atomics.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -536,7 +536,7 @@ pub unsafe fn atomic_xor<I: Integer, const SCOPE: u32, const SEMANTICS: u32>(
536536
/// accesses within Scope to the same location:
537537
///
538538
/// 1. Load through `ptr` to get an original value,
539-
/// 2. Get a new value by finding the smallest signed integer of original value
539+
/// 2. Get a new value by finding the smallest float of original value
540540
/// and `value`, and
541541
/// 3. Store the new value back through `ptr`.
542542
///
@@ -573,7 +573,7 @@ pub unsafe fn atomic_f_min<F: Float, const SCOPE: u32, const SEMANTICS: u32>(
573573
/// accesses within Scope to the same location:
574574
///
575575
/// 1. Load through `ptr` to get an original value,
576-
/// 2. Get a new value by finding the largest signed integer of original value
576+
/// 2. Get a new value by finding the largest float of original value
577577
/// and `value`, and
578578
/// 3. Store the new value back through `ptr`.
579579
///
@@ -610,7 +610,7 @@ pub unsafe fn atomic_f_max<F: Float, const SCOPE: u32, const SEMANTICS: u32>(
610610
/// accesses within `SCOPE` to the same location:
611611
///
612612
/// 1) load through `ptr` to get an original value,
613-
/// 2) get a new value by integer addition of original value and `value`, and
613+
/// 2) get a new value by float addition of original value and `value`, and
614614
/// 3) store the new value back through `ptr`.
615615
///
616616
/// The result is the Original Value.

0 commit comments

Comments
 (0)