[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

[MacPerl] Out of memory




Dear MacPerl group,

I am a new MacPerl user who lacks previous PERL/UNIX exerience. So I'm
going to throw some dumb questions your way from time to time (where do I
start?).

I've been working on and off on Perl script to replace a Frontier script I
have that interprets formatted bulk text files from a legacy system at my
office. It bashes these with a complex series (around 150) of
search/replaces to interpret the formatting into an inter-markup file that
is easily edited before converting to html docs.

The file sizes range from around 150K to 300K. But after around 200K I get
out of memory messages and processing stops. Breaking the files into
individual stories and processing them individually helps somewhat, though
does not reliably address the problem. Version 5.1.Or2 is what I've been
using, with memory partition cranked to around 7200K.

So some questions:

	1. Should I be able to process 300K files simply by loading them
into memory and attacking them? Assume that many of the search patterns are
going to produce "a lot" (>100) of matches.

	2. Can can goofs in my search/replace patterns (almost a certainty)
somehow cause or contribute to OOM messages? (I get the feeling this is
happening)

	3. If I load and process individual stories, is there a way to
_append_ these to the _bottom_ of an out-file?

Answering these would be a great help. Thanks in advance, and thanks to you
Matthias for providing this cool tool.

Appreciatively,
John MacDonald

==========================================================
 John MacDonald <jmac@samart.inet.co.th>  or <jmac@ksc.net.th>
Webmaster for the Bangkok Post <http://www.bangkokpost.net/>
----------------------------------------------------------