diff options
author | Rich Felker <dalias@aerifal.cx> | 2011-06-12 10:53:42 -0400 |
---|---|---|
committer | Rich Felker <dalias@aerifal.cx> | 2011-06-12 10:53:42 -0400 |
commit | 2afebbbcd16e8bfc5e008a40b2faf3bd8cf14e88 (patch) | |
tree | 5a46fc61e2e4d8138ae41ead4b5377370eca9872 /include/sys/swap.h | |
parent | 382584724308442f03f3d29f7fc6de9e9d140982 (diff) | |
download | musl-2afebbbcd16e8bfc5e008a40b2faf3bd8cf14e88.tar.gz musl-2afebbbcd16e8bfc5e008a40b2faf3bd8cf14e88.tar.xz musl-2afebbbcd16e8bfc5e008a40b2faf3bd8cf14e88.zip |
malloc: cast size down to int in bin_index functions
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.
Diffstat (limited to 'include/sys/swap.h')
0 files changed, 0 insertions, 0 deletions