|
RE: PATCH: add malloc function attribute to rts malloc functions: msg#00049lang.haskell.glasgow.bugs
> http://gcc.gnu.org/onlinedocs/gcc-3.3.3/gcc/Function-Attributes.html > The gcc manual says: > > malloc > The malloc attribute is used to tell the compiler that a > function may be treated as if it were the malloc function. The > compiler assumes that calls to malloc result in pointers that > cannot alias anything. This will often improve optimization. > > Note the malloc attribute has only been around since gcc > 3.xx, hence the > extra GNUC3_ATTRIBUTE that tests for gcc version >= 3. > > So I guess it can't hurt and might even help. It even compiles! (as is > running make in the rts directory does not fail - I've not done a full > build.) Committed; thanks! Simon
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | PATCH: add malloc function attribute to rts malloc functions, Duncan Coutts |
|---|---|
| Next by Date: | Re: Bug in the proof of Data.FiniteMap and DData.Map, Daan Leijen |
| Previous by Thread: | PATCH: add malloc function attribute to rts malloc functions, Duncan Coutts |
| Next by Thread: | Bug report., MR K P SCHUPKE |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |