Article View: gnu.utils.bug
Article #376malloc and powers of 2
From: "Karl Berry."
Date: Thu, 24 Aug 1989 17:48
Date: Thu, 24 Aug 1989 17:48
18 lines
1051 bytes
1051 bytes
I was doing some large Fourier transforms; in particular, the array I was allocating was 4MB. I was using GNU malloc, and I noticed that right after the call, the amount of memory being used was 8MB more, not 4! That is very bad. After looking through the code, it appeared that the reason was simply that the overhead involved made it want to allocate one more unit, i.e., twice as much memory. Even if that's not the reason, better behavior is still needed -- 4MB+1K I could accept. By ``GNU malloc'' I mean the malloc.c distributed with emacs (18.54). I read in the latest bulletin that Mike Haertel was working on a new malloc... karl@umb.edu
Technical Details
Message-ID:
<8908241748.AA02588@mote.umb.edu>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!gatech!tut.cis.ohio-state.edu!mote.umb.edu!karlShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!gatech!tut.cis.ohio-state.edu!mote.umb.edu!karl
From: karl@mote.umb.edu ("Karl Berry.")
Newsgroups: gnu.utils.bug
Subject: malloc and powers of 2
Message-ID: <8908241748.AA02588@mote.umb.edu>
Date: 24 Aug 89 17:48:55 GMT
Sender: daemon@tut.cis.ohio-state.edu
Distribution: gnu
Organization: GNUs Not Usenet
Lines: 18