malloc: cast size down to int in bin_index functions
authorRich Felker <dalias@aerifal.cx>
Sun, 12 Jun 2011 14:53:42 +0000 (10:53 -0400)
committerRich Felker <dalias@aerifal.cx>
Sun, 12 Jun 2011 14:53:42 +0000 (10:53 -0400)
even if size_t was 32-bit already, the fact that the value was
unsigned and that gcc is too stupid to figure out it would be positive
as a signed quantity (due to the immediately-prior arithmetic and
conditionals) results in gcc compiling the integer-to-float conversion
as zero extension to 64 bits followed by an "fildll" (64 bit)
instruction rather than a simple "fildl" (32 bit) instruction on x86.
reportedly fildll is very slow on certain p4-class machines; even if
not, the new code is slightly smaller.


No differences found