HP48 garbage collection


My 48GX and also the SX, but I haven't used the SX for quite sometime so I don't remember, tends to freeze for a couple of seconds after I key in a few entries. I think this is due to garbage collection but how to I reduce the frequency of this action as it really slow me down. It's a shame as these calculators are significantly faster than the 41's that I have.



I think the answer is in the FAQ at www.hpcalc.org ;-)



Hi, Please show me where, because my calculator does the same thing. It is quite irritating sometimes.



be assured this is normal for RPL machines.

The delay effect has many parameters, like stack depth,

free RAM, etc...

Usually it helps much to have not too many objects on the data stack.

Please take a look there:


and maybe there




I do not agree that this is normal in a well engineered RPN machine.

I have had nearly all HP RPN calculators from the beginning: I do not remember HP25C, 29C, 67C, 41, etc. to have the pausing problem.

In my HP48G the problem was still passed unnoticed.

When I bought an HP49G I returned it (HP accepted the return) because the garbage collector problem was so bad that it made the machine unusable for any serious continous work.

Later on, the ROM version 1.19-6 appeared (not supported by HP), where the pausing appears only from time to time. I have a new HP49G (one of the latest to be manufactured) with this software version and although the problem is not absolutely fixed, is bearable.

So pausing owing to garbage collector depends NOT on being a RPN machine but on how the software is made. HP is giving examples of how thinks can be worsened: i.e. in some aspects new HP49G+ were worse than HP49: even worse keyboard, battery problems, etc., and HP49G had some features worse than HP48 (of course there have been improvements in speed and other features).

Edited: 5 Oct 2004, 4:53 p.m. after one or more responses were posted


Actually the lower end 32K RAM 48G didn't really suffer from this problem to a noticiable extent, because of its small amount of RAM. Kinda makes the plain 48G somewhat better for general number crunching. I too, did not really mind when I had only a low end 48G, but quickly found out about the long delay when I acquired a 48GX and added RAM cards.

And my 49G did act worse until I upgraded the ROM. Of course the newest 49G+ is so fast that even if there is garbage collection, I haven't noticed.


May be that is what it is. My 48SX has only 32K of RAM the GX has 256K (with the added 128K RAM card) and it is quite bad in this respect.


Raymond mentioned RPL, not RPN. RPL does
use Reverse Polish Notation, but it's not the same programming
language used on earlier HP RPN models, and "Garbage Collection"
is very much part of RPL. Actually, it may better be considered
"Memory Packing"; it's a matter of moving still referenced objects
in temporary memory to occupy contiguous memory, overwriting
unreferenced objects. Garbage collection is done whenever the
amount of free memory gets too low.

In general, having more free memory means that garbage collection
won't need to be done so often, but when it is done, it takes
longer. This explains why it's less noticeable on a 48S/G (or
48SX/GX without any merged memory).

Of course, fewer objects (actually, pointers to objects) on the
stack will generally result in a faster garbage collection too.
Avoid filling up the stack with objects that you no longer need.

John H Meyers wrote some posts on reducing free memory so that the
garbage collections were fast enough to be less of an annoyance to
some. Personally, I prefer less frequent garbage collections, even
though they do take longer. See
for some of John's posts on this matter. He might
have something about it on http://www.hpcalc.org/ too.

Garbage collection can be drastically slowed when the stack
contains many pointers into composite objects. Typically, the
composite will be a list type object. See
for some demonstration programs on this effect. Note
that if you know that a program could suffer from this, then you
might be able to avoid it by forcing a garbage
collection ahead of time.




My demonstration programs use the TEVAL command, which is available only in the 49 series. See http://www.hpcalc.org/details.php?id=6112 for a UserRPL timer program which will also work on the other RPL models. I expect that it's more accurate than TEVAL too, plus it works regardless of the wordsize.

Also, one of the programs uses UNPICK, which is another 49 series only command. For that one, I suppose that using ROLL in place of PICK and ROLLD in place of UNPICK ought to work, athough they'll be slower.

Also note that the results from the BYTES command are for the 49g+; expect them to be different on the 48 series.


Edited: 6 Oct 2004, 5:52 a.m.


Note that the RPL calculators have some "type-ahead" capability. Up to 15 keystrokes can be stored in a First-In First-Out buffer while the "busy" annunciator is on, and this buffer is checked for unprocessed keystrokes when the calculator finishes with whatever it's doing.

For example, I can execute 30 WAIT, and then type in "HELLO WORLD" [ENTER] (14 keystrokes, with flag -60 set) during the wait time, to have the string appear on the stack after the 30 seconds are up. On the 48 and 49 series, after 15 keystrokes are in the buffer, pressing a key results in a "warble" type sound; the 28 series silently ignores additional keystrokes.

But it can be a bit disconcerting to press a key and not see (or hear) anything immediately happen because the calculator is busy doing something else, such as a garbage collection.


Edited: 6 Oct 2004, 4:04 a.m.

Possibly Related Threads...
Thread Author Replies Views Last Post
  And the collection grows... Les Koller 1 626 02-05-2014, 05:55 PM
Last Post: Xavier A. (Brazil)
  Calculator collection Miguel Toro 5 563 12-05-2013, 04:06 PM
Last Post: Chris Pem10
  HP8925A - Continuous BEEP and garbage display mark stephens 3 293 08-03-2013, 08:54 AM
Last Post: Rik Bos
  Another non-HP RPN vintage calculator joins the collection Michael de Estrada 2 431 07-23-2013, 04:10 PM
Last Post: Walter B
  The 'Complete' Collection Keith Midson 8 915 05-12-2013, 09:52 PM
Last Post: Namir
  OT: My Slide Rule Collection Eddie W. Shore 18 1,593 04-25-2013, 11:47 PM
Last Post: Garth Wilson
  My Mostek collection is complete Michael de Estrada 15 1,346 04-10-2013, 10:01 PM
Last Post: Michael de Estrada
  Just added an HP 50G to the collection! Jedidiah Smith 12 1,128 03-16-2013, 12:43 PM
Last Post: Chris Smith
  A cheaper way to add to your collection Keith Midson 3 582 03-08-2013, 05:50 AM
Last Post: Keith Midson
  The biggest collection update yet Keith Midson 2 422 10-31-2012, 12:16 PM
Last Post: Matt Agajanian

Forum Jump: