ftp.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2002/05/17/11:30:38

X-Authentication-Warning: delorie.com: mailnull set sender to djgpp-workers-bounces using -f
From: sandmann AT clio DOT rice DOT edu (Charles Sandmann)
Message-Id: <10205171531.AA19063@clio.rice.edu>
Subject: Re: Malloc/free DJGPP code
To: djgpp-workers AT delorie DOT com
Date: Fri, 17 May 2002 10:31:51 -0500 (CDT)
In-Reply-To: <1225-Fri17May2002175128+0300-eliz@is.elta.co.il> from "Eli Zaretskii" at May 17, 2002 05:51:29 PM
X-Mailer: ELM [version 2.5 PL2]
Mime-Version: 1.0
Reply-To: djgpp-workers AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp-workers AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

> program's data segment.  So supporting negative sbrk's will indeed
> help there.  It is not uncommon for an Emacs session to need to create
> a buffer for a multimegabyte file, then kill that buffer and never
> need anything that big for quite a while.  The current behavior
> whereby those megabytes stay reserved by the Emacs session is not
> optimal.

I agree this might be a desirable performance enhancement, but given
the ugly state of sbrk() implementation in assembler in crt0.s it's
unlikely to happen.  

There are two separate algorithms (resize and multiple blocks).
Each would need to be changed. The unixy/resize algorithm would be
easier to do (same calls, just extra logic).  The multiple block
algorithm would require new API calls and logic.

- Raw text -

  webmaster     delorie software   privacy  
  Copyright 2019   by DJ Delorie     Updated Jul 2019