473,405 Members | 2,171 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

Remove functions

I'm writing an application that is becoming quite large. I would like to
keep memory usage to a minimum so I'm looking for a way to include a file
of functions that are only used once, then discard the functions freeing
up the memory they take. Any ideas?

--
Stan McCann, "Uncle Pirate" http://stanmccann.us/
Implementing negative score for googlegroup postings, see
http://blinkynet.net/comp/uip5.html
A zest for living must include a willingness to die. - R.A. Heinlein
Jul 9 '06 #1
2 1318
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Stan McCann wrote:
I'm writing an application that is becoming quite large. I would like to
keep memory usage to a minimum so I'm looking for a way to include a file
of functions that are only used once, then discard the functions freeing
up the memory they take. Any ideas?
First of all, use __autoload(). See the manual.

And remember: this is a web app, and it will free memory after every page
has been completely shown.

- --
- ----------------------------------
Iván Sánchez Ortega -i-punto-sanchez--arroba-mirame-punto-net

Darth Vader duerme con un osito Wookie.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.3 (GNU/Linux)

iD8DBQFEsYqK3jcQ2mg3Pc8RAoSIAJ9Yx8ZRWfSuC0T07m14q0 9K3A+DhACfVoZP
qCa7ck+uWv3pdExmJz1gjZ0=
=iAxa
-----END PGP SIGNATURE-----
Jul 9 '06 #2
=?ISO-8859-15?Q?Iv=E1n_S=E1nchez_Ortega?=
<i.***************@rroba--mirame.punto.netwrote in
news:kd************@blackspark.escomposlinux.org:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Stan McCann wrote:
>I'm writing an application that is becoming quite large. I would
like to keep memory usage to a minimum so I'm looking for a way to
include a file of functions that are only used once, then discard
the functions freeing up the memory they take. Any ideas?

First of all, use __autoload(). See the manual.
Thanks, I'll look at that.
And remember: this is a web app, and it will free memory after every
page has been completely shown.
Duh! Thinking 'old style' programming. Of course the functions in
question will be removed from memory right away, they are to read data
from the database to build a form, then you click the form button and
they're gone. I still sometimes get confused with different languages,
and different types of programs. At least I don't get assembly or
Modula II code in my apps anymore. ;)

Thanks for straightening me out.

--
Stan McCann, "Uncle Pirate" http://stanmccann.us/
Implementing negative score for googlegroup postings, see
http://blinkynet.net/comp/uip5.html
A zest for living must include a willingness to die. - R.A. Heinlein
Jul 10 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
by: Ken | last post by:
I am trying to create one image using JavaScript; then later in the script remove the image - not just remove the src. The following creates the image, but I have been unable to remove it. How...
6
by: Arne Claus | last post by:
Hi If've just read, that remove() on a list does not actually remove the elements, but places them at the end of the list (according to TC++STL by Josuttis). It also says, that remove returns a...
7
by: Kieran Simkin | last post by:
Hi all, I'm having some trouble with a linked list function and was wondering if anyone could shed any light on it. Basically I have a singly-linked list which stores pid numbers of a process's...
4
by: moondaddy | last post by:
I have a datagrid where a user can edit a number in one of the columns for a quantity value. On the postback I loop through all of the datagrid items and if the quantity has changed, then I update...
3
by: Danny Yeadon | last post by:
Hi I need to remove unwanted characters from phone numbers from my phone bill to analyse the data. Some examples are 02 48222222 i need to remove the space +61266667656 ...
5
by: joe | last post by:
hello i have a databse program that uses char arrays to output data to reports. I would like to remove all invalid characters from the array and replace them with a blank space. I have problems...
4
by: =?Utf-8?B?emhhbmdscg==?= | last post by:
Hi, Following code does not work. (it will crash.)-- I think the reason is that I cannot modify list (call remove) in foreach. But I don't know what I can do. ...
1
by: Liucy | last post by:
Dear all, I encounter a problem about DeleteFile() with ANSI stdio functions. It always fails to delete file and sets ERROR_SHARING_VIOLATION. I know I can use remove() instead of DeleteFile(),...
4
by: FullBandwidth | last post by:
I have been perusing various blogs and MSDN pages discussing the use of event properties and the EventHandlerList class. I don't believe there's anything special about the EventHandlerList class in...
61
by: arnuld | last post by:
I have created a program which creates and renames files. I have described everything in comments. All I have is the cod-duplication. function like fopen, sprint and fwrite are being called again...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.