(** Conversions from ints to floats can be defined as bitwise manipulations over the in-memory representation.  This is what the PowerPC port does. The trick is that [from_words 0x4330_0000 x] is the float [2^52 + of_intu x]. *)
Definition ox4330_0000 := Int.repr 1127219200.        (**r [0x4330_0000] *)

(* Specifications: *)
Lemma split_bits_or:
forall x,
split_bits 52 11 (Int64.unsigned (Int64.ofwords ox4330_0000 x)) = (false, Int.unsigned x, 1075).
Lemma from_words_value:
forall x,
B2R _ _ (from_words ox4330_0000 x) = (bpow radix2 52 + Z2R (Int.unsigned x))%R
/\ is_finite _ _ (from_words ox4330_0000 x) = true
/\ Bsign _ _ (from_words ox4330_0000 x) = false.
Lemma from_words_eq:
forall x, from_words ox4330_0000 x = BofZ 53 1024 __ __ (2^52 + Int.unsigned x).
Theorem of_intu_from_words:
forall x,
of_intu x = sub (from_words ox4330_0000 x) (from_words ox4330_0000 Int.zero).
Lemma ox8000_0000_signed_unsigned:
forall x,
Int.unsigned (Int.add x ox8000_0000) = Int.signed x + Int.half_modulus.
Theorem of_int_from_words:
forall x,
of_int x = sub (from_words ox4330_0000 (Int.add x ox8000_0000))
(from_words ox4330_0000 ox8000_0000).
Lemma split_bits_or:
forall x,
split_bits 52 11 (Int64.unsigned (Int64.ofwords ox4330_0000 x)) = (false, Int.unsigned x, 1075).
Lemma from_words_value:
forall x,
B2R _ _ (from_words ox4330_0000 x) = (bpow radix2 52 + Z2R (Int.unsigned x))%R
/\ is_finite _ _ (from_words ox4330_0000 x) = true
/\ Bsign _ _ (from_words ox4330_0000 x) = false.
Lemma from_words_eq:
forall x, from_words ox4330_0000 x = BofZ 53 1024 __ __ (2^52 + Int.unsigned x).
Theorem of_intu_from_words:
forall x,
of_intu x = sub (from_words ox4330_0000 x) (from_words ox4330_0000 Int.zero).
Lemma ox8000_0000_signed_unsigned:
forall x,
Int.unsigned (Int.add x ox8000_0000) = Int.signed x + Int.half_modulus.
Theorem of_int_from_words:
forall x,
of_int x = sub (from_words ox4330_0000 (Int.add x ox8000_0000))
(from_words ox4330_0000 ox8000_0000).