Bug 7029 - CPU_ALLOC_SIZE() returns wrong value
: CPU_ALLOC_SIZE() returns wrong value
Status: RESOLVED FIXED
Product: glibc
Classification: Unclassified
Component: libc
: 2.8
: P2 normal
: ---
Assigned To: Ulrich Drepper
:
:
:
:
  Show dependency treegraph
 
Reported: 2008-11-13 03:05 UTC by Michael Kerrisk
Modified: 2008-11-13 19:57 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments
test program (652 bytes, text/plain)
2008-11-13 03:07 UTC, Michael Kerrisk
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Kerrisk 2008-11-13 03:05:17 UTC
On x86-32 at least, CPU_ALLOC_SIZE() returns twice the value that its should. 
For example, CPU_ALLOC_SIZE(8192) returns 2048.  This also causes CPU_ALLOC() to
allocate double the required memory.
Comment 1 Michael Kerrisk 2008-11-13 03:07:24 UTC
Created attachment 3059 [details]
test program

An example run of the attached program demonstrates the problem:

$ ./a.out 8192
CPU_ALLOC_SIZE()=2048
Comment 2 Ulrich Drepper 2008-11-13 19:57:21 UTC
Changed in cvs.