Re: Memory Management
- From: Shiraz <shirazk@xxxxxxxxx>
- Date: 27 Apr 2007 15:36:42 -0700
On Apr 27, 5:22 pm, Michael Carman <mjcar...@xxxxxxxxx> wrote:
On 4/27/2007 1:26 PM, Shiraz wrote:
I am trying to set aside some memory for my cache (hash/array etc) in my
script. I use the ulimit and then monitor used mem with Devel::Size and
destroy when i am close to my limit. Any ideas on how to do this better?
You don't really do memory management in Perl. Proper programming can reduce the
amount of memory that you use, though. Have you read "perldoc -q memory?"
-mjc
Maybe I worded my question wrong and it should be Memory Allocation
and monitor.
I know I can allocate memory space by using ` $#arr = 999 ` but i am
not sure how much memory it consumes. Basically my goal is to figure
out how to set the max memory a variable can use and how to monitor
when the max has been reached.
I did read the perldoc but that didnt tell me anything about reserving
memory, just to be carefull with it.
.
- Follow-Ups:
- Re: Memory Management
- From: Michael Carman
- Re: Memory Management
- From: Ala Qumsieh
- Re: Memory Management
- References:
- Memory Management
- From: Shiraz
- Re: Memory Management
- From: Michael Carman
- Memory Management
- Prev by Date: Re: Memory Management
- Next by Date: finding invalid method names
- Previous by thread: Re: Memory Management
- Next by thread: Re: Memory Management
- Index(es):
Relevant Pages
|