On Sat, Apr 15, 2017 at 10:41 PM, Daryl Tester <
[email protected]> wrote:
> On 16/04/17 13:59, John R. Hogerhuis wrote:
>
> I never realized garbage collection in the BASIC interpreter could create
>> such a noticeable slow down.
>>
>
> I was reminiscing about this only a few days ago. I did work experience
> for a company back in the early 80's that wrote a point of sale system on
> a cash register. It turned out to be a CBM style machine underneath, and
> every now and then it would pause while garbage collecting. I think the
> work around was to use the FRE() function repeatedly before GC was
> incurred (at which point it was time expensive to run), and during a point
> where there would be pausing anyway (e.g. during receipt printing).
> Good times (I think).
>
> I wonder if the M100's basic sports a similar function?
It does have a FRE command. You can call FRE(0) or FRE(" ") depending on
whether you want the unused amount of "numeric" memory or the unused amount
of string space.
It probably does force the garbage collector to run.
As you say though that wouldn't make garbage collection take any less time,
you just get to trigger it at a more convenient time.
On my CoCo, I never noticed the garbage collector run. Maybe I was spoiled
by a nice CPU.
-- John.