Skip to content

Commit

Permalink
flambda-backend: Fix float32 to/of bits comments (#2860)
Browse files Browse the repository at this point in the history
comments
  • Loading branch information
TheNumbat authored Jul 29, 2024
1 parent 6095925 commit 864fde1
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
4 changes: 2 additions & 2 deletions otherlibs/stdlib_beta/amd64/float32.mli
Original file line number Diff line number Diff line change
Expand Up @@ -199,14 +199,14 @@ external to_int64 : (t[@local_opt]) -> int64
external of_bits : (int32[@local_opt]) -> t
= "caml_float32_of_bits_bytecode" "caml_float32_of_bits"
[@@unboxed] [@@noalloc] [@@builtin]
(** Convert a 32-bit float to a 32-bit integer, preserving the value's
(** Convert a 32-bit integer to a 32-bit float, preserving the value's
bit pattern.
The amd64 flambda-backend compiler translates this call to MOVD. *)

external to_bits : (t[@local_opt]) -> int32
= "caml_float32_to_bits_bytecode" "caml_float32_to_bits"
[@@unboxed] [@@noalloc] [@@builtin]
(** Convert a 32-bit integer to a 32-bit float, preserving the value's
(** Convert a 32-bit float to a 32-bit integer, preserving the value's
bit pattern.
The amd64 flambda-backend compiler translates this call to MOVD. *)

Expand Down
10 changes: 6 additions & 4 deletions otherlibs/stdlib_beta/amd64/float32_u.mli
Original file line number Diff line number Diff line change
Expand Up @@ -151,12 +151,14 @@ val to_float : t -> float#
(** Convert a 32-bit float to a 64-bit float. *)

val of_bits : int32# -> t
(** Convert a 32-bit float to a 32-bit integer, preserving the value's
bit pattern. *)
(** Convert a 32-bit integer to a 32-bit float, preserving the value's
bit pattern.
The amd64 flambda-backend compiler translates this call to MOVD. *)

val to_bits : t -> int32#
(** Convert a 32-bit integer to a 32-bit float, preserving the value's
bit pattern. *)
(** Convert a 32-bit float to a 32-bit integer, preserving the value's
bit pattern.
The amd64 flambda-backend compiler translates this call to MOVD. *)

val of_string : string -> t
(** Convert the given string to a float. The string is read in decimal
Expand Down

0 comments on commit 864fde1

Please sign in to comment.