[Webkit-unassigned] [Bug 20422] Patch to allow custom memory allocation control

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sun Sep 21 22:54:45 PDT 2008


https://bugs.webkit.org/show_bug.cgi?id=20422





------- Comment #14 from ppedriana at gmail.com  2008-09-21 22:54 PDT -------
Thanks. That is very good feedback. I will work towards addressing the items
over the next week or so.

The uint64_t is to cause it to act like malloc as per the C99 standard section
7.20.3 p1 ("suitably aligned"). But as you say, uint64_t isn't the best way. I
wonder if the best way is to create a union of long long and long double and
use the size of that. I'm unaware of any compiler that would support uint64_t
but have it be larger than long long. I have however seen compilers that
implement long long as a 128 bit vector-friendly type, and then there is
PowerPC's 16 bit vector types themselves. FWIW, FastMalloc.cpp states that it
returns 8 byte aligned memory.

I have no idea where the "We don't need to check for a null pointer; the
compiler does this." statement came from. It's not a true statement in that
context. I think it might have come in from a paste of some other code where it
made sense. 


-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list