Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.sys.acorn.programmer > #6717

Re: Wimp_SlotSize questions

From Martin <News04@avisoft.f9.co.uk>
Newsgroups comp.sys.acorn.programmer
Subject Re: Wimp_SlotSize questions
Date 2026-10-28 13:21 +0000
Organization None
Message-ID <5d2edde289News04@avisoft.f9.co.uk> (permalink)
References <5d2eda27cdbob@sick-of-spam.invalid>

Show all headers | View raw


In article <5d2eda27cdbob@sick-of-spam.invalid>,
   Bob Latham <bob@sick-of-spam.invalid> wrote:

> In my RISCOS 3 PRMs page 3-206 it says you can change the slot size
> of the current slot by setting a value in register 0.

> At the bottom of that same page it also says - No tasks should set
> their current slot size,: normally, a new task will call *wimpslot
> which then calls Wimp_SlotSize.

> To my simple brain that is a major contradiction and I don't
> understand it at all.

I think the clue is in 'normally', as it is normal for a task to be
started just after a WimpSlot command in a !Run file, and that can be
easily changed if more or less is required for the task to run.

It is more unusual for tasks to want to change their slotsize, but
many do use SYS Wimp_Slotsize where variable storage is required.

> Say I need to obtain some temporary extra memory for a sort buffer,
> can extend the slot using this call, do the sort work and reduce the
> slot size again?

That would certainly work ... but it may depend on what language you
are using if that is the best way.

If you are using BASIC, then beware that it will not adjust HIMEM, so
the space is not simply usable from BASIC - but can certainly be used.
It may be better using END=, which changes the SlotSize and adjusts
HIMEM, but there are some restrictions when it can be used.

If you are using BASIC and sorting arrays, then you should look at my
ArmSort module from http://www.avisoft.f9.co.uk/ which makes sorting
very easy.

-- 
Martin Avison 
Note that unfortunately this email address will become invalid
without notice if (when) any spam is received. 

Back to comp.sys.acorn.programmer | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Wimp_SlotSize questions Bob Latham <bob@sick-of-spam.invalid> - 2026-10-28 12:41 +0000
  Re: Wimp_SlotSize questions Martin <News04@avisoft.f9.co.uk> - 2026-10-28 13:21 +0000
  Re: Wimp_SlotSize questions Theo <theom+news@chiark.greenend.org.uk> - 2026-10-28 13:28 +0000
    Re: Wimp_SlotSize questions Bob Latham <bob@sick-of-spam.invalid> - 2026-10-28 14:52 +0000
      Re: Wimp_SlotSize questions Jean-Michel <jmc.bruck@orange.fr> - 2026-10-28 17:41 +0100

csiph-web