zsh-workers
 help / color / mirror / code / Atom feed
From: "Bart Schaefer" <schaefer@candle.brasslantern.com>
To: zsh-workers@sunsite.auc.dk
Subject: Re: zsh and memory
Date: Fri, 17 Dec 1999 07:16:10 +0000	[thread overview]
Message-ID: <991217071610.ZM17352@candle.brasslantern.com> (raw)
In-Reply-To: <199912160956.KAA13359@beta.informatik.hu-berlin.de>

On Dec 16, 10:56am, Sven Wischnowsky wrote:
} Subject: Re: zsh and memory
}
} [...] I looked who was using lots of heap memory and found the
} tokstr handling in lex.c. There we always allocate at least 256 bytes
} and if the buffer needs expanding (in add()) in gets resized to
} inbufct (or larger). Some more investigation showed that we almost
} never need a tokstr with more than 32 bytes, so I changed that.  I also 
} changed add() to be more careful when expanding the buffer -- I left
} the old code conditioned out because I don't kno if there was a reason 
} to resize it to inbufct bytes; I at least don't see a reason for that.

Probably the idea was to eliminate lots of small allocations in the
event that the "token" is a long quoted string or the like, for speed.
We should watch out for performance problems if those changes are kept.

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com


  reply	other threads:[~1999-12-17  7:16 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-12-16  9:56 Sven Wischnowsky
1999-12-17  7:16 ` Bart Schaefer [this message]
1999-12-16 10:39 Sven Wischnowsky
1999-12-16 11:16 ` Mike Fletcher
1999-12-16 18:01 ` Timothy Writer
1999-12-17 10:40 Sven Wischnowsky
1999-12-17 11:49 Sven Wischnowsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=991217071610.ZM17352@candle.brasslantern.com \
    --to=schaefer@candle.brasslantern.com \
    --cc=zsh-workers@sunsite.auc.dk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).