contrib/gcc-4.7/gcc/cp/mangle.c
/* Write out a floating-point literal.

    "Floating-point literals are encoded using the bit pattern of the
    target processor's internal representation of that number, as a
    fixed-length lowercase hexadecimal string, high-order bytes first
    (even if the target processor would store low-order bytes first).
    The "n" prefix is not used for floating-point literals; the sign
    bit is encoded with the rest of the number.

    Here are some examples, assuming the IEEE standard representation
    for floating point numbers.  (Spaces are for readability, not
    part of the encoding.)

	1.0f			Lf 3f80 0000 E
       -1.0f			Lf bf80 0000 E
	1.17549435e-38f		Lf 0080 0000 E
	1.40129846e-45f		Lf 0000 0001 E
	0.0f			Lf 0000 0000 E"

   Caller is responsible for the Lx and the E.  */
Write out a floating-point literal.
"Floating-point literals are encoded using the bit pattern of the
target processor's internal representation of that number, as a
fixed-length lowercase hexadecimal string, high-order bytes first
(even if the target processor would store low-order bytes first).
The "n" prefix is not used for floating-point literals; the sign
bit is encoded with the rest of the number.

Here are some examples, assuming the IEEE standard representation
for floating point numbers.  (Spaces are for readability, not
part of the encoding.)



Caller is responsible for the Lx and the E.
Write out a floating - point literal . " Floating - point literals are encoded using the bit pattern of the target processor ' s internal representation of that number as a fixed - length lowercase hexadecimal string high - order bytes first ( even if the target processor would store low - order bytes first ) . The " n " prefix is not used for floating - point literals ; the sign bit is encoded with the rest of the number . Here are some examples assuming the IEEE standard representation for floating point numbers . ( Spaces are for readability not part of the encoding . ) Caller is responsible for the Lx and the E .
static void
write_real_cst (const tree value)
{
  if (abi_version_at_least (2))
    {
      long target_real[4];  
      char buffer[9];       
      int i, limit, dir;
      tree type = TREE_TYPE (value);
      int words = GET_MODE_BITSIZE (TYPE_MODE (type)) / 32;
      real_to_target (target_real, &TREE_REAL_CST (value),
		      TYPE_MODE (type));
      if (FLOAT_WORDS_BIG_ENDIAN)
	i = 0, limit = words, dir = 1;
      else
	i = words - 1, limit = -1, dir = -1;
      for (; i != limit; i += dir)
	{
	  sprintf (buffer, "%08lx", (unsigned long) target_real[i]);
	  write_chars (buffer, 8);
	}
    }
  else
    {
      size_t i;
      for (i = 0; i < sizeof (TREE_REAL_CST (value)); ++i)
	write_number (((unsigned char *) &TREE_REAL_CST (value))[i],
		       1,
		       16);
      G.need_abi_warning = 1;
    }
}
static void write_real_cst ( const tree value ) { if ( abi_version_at_least ( 2 ) ) { long target_real [ 4 ] ; char buffer [ 9 ] ; int i , limit , dir ; tree type = TREE_TYPE ( value ) ; int words = GET_MODE_BITSIZE ( TYPE_MODE ( type ) ) / 32 ; real_to_target ( target_real , & TREE_REAL_CST ( value ) , TYPE_MODE ( type ) ) ; if ( FLOAT_WORDS_BIG_ENDIAN ) i = 0 , limit = words , dir = 1 ; else i = words - 1 , limit = -1 , dir = -1 ; for ( ; i != limit ; i += dir ) { sprintf ( buffer , " " , ( unsigned long ) target_real [ i ] ) ; write_chars ( buffer , 8 ) ; } } else { size_t i ; for ( i = 0 ; i < sizeof ( TREE_REAL_CST ( value ) ) ; ++ i ) write_number ( ( ( unsigned char * ) & TREE_REAL_CST ( value ) ) [ i ] , 1 , 16 ) ; G . need_abi_warning = 1 ; } }
Write out a floating-point literal.
Write out a floating - point literal .
/* largest supported float */ /* eight hex digits in a 32-bit number */ /* The value in target_real is in the target word order,
	 so we must write it out backward if that happens to be
	 little-endian.  write_number cannot be used, it will
	 produce uppercase.  */ /* In G++ 3.3 and before the REAL_VALUE_TYPE was written out
	 literally.  Note that compatibility with 3.2 is impossible,
	 because the old floating-point emulator used a different
	 format for REAL_VALUE_TYPE.  */ /*unsigned_p*/ /*base*/