Understanding and Optimization of OS 4.1 for Classics
Posted: Thu May 17, 2012 10:39 am
Hi guys!
This is a new thread based on questions and answers from my prior thread, "AmigaOS Classic 4.1 Update 2 Fails to Install." Those issues had been resolved and the thread had changed content. It ended with my question, "Is there any experience or documentation about using the different memory masks when setting up a hard drive partition: the choice of 'Any Memory,' '32-bit Aligned,' or '24-bit DMA?' "
Calgor had responded: "Regarding the Mask, I do not know specifically if OS4 behaves differently to OS3.9, as I have not needed to change the Mask value for any hard disk partitions.
But if you set the Mask to 0x7FFFFFFF - then all of the first 2GB of memory can be used. The last character being F means the driver/controller is not fussy about memory alignment. The last letter could also be set to E or C for different alignments. For those drivers (e.g. in OS3.9) that may only operate in 24-bit memory space (i.e. first 16 MB) you can set the mask to 0xFFFFFF - I needed to do this once for a CD driver in OS3.9 that would have random errors otherwise.
There is an *excellent* explanation in the old SFS 1.58 guide (from original SFS author archive or SFS_OLD.guide in latest 68k full sfs1.277 archive) under the section "the Mask field":
http://www.amiga-stuff.com/text/filesys ... S158.guide
I do not know which one is ultimately preferred out of 0XFFFFFFFF (4GB) or 0x7FFFFFFF (2GB), both for current systems, and for future compatibility."
He was, of course, correct. In the SFS guide says of MaxTransfer Values: "In any case, if you have a SCSI drive, then a MaxTransfer value of 0x7FFFFFFF should be just fine. For IDE drives, you probably need to
set it to 0x1FFFE or to 0xFFFE. Those values represent 128 kB minus 2 bytes and 64 kB minus 2 bytes respectively."
And of Transfer Masks: "The Mask field can be used to tell a filesystem that the device which comes with your (harddisk) controller cannot directly access its data
in all regions of memory available on your system.
When a device has been properly written it should be able to cope with data located anywhere in memory. For those devices the Mask should be set to 0xFFFFFFFF. Only badly written or very old devices need a different Mask -- in other words, the Mask value is a compatibility kludge to fix broken devices.
For example, some devices can't access data starting at an uneven address in memory. Some even can only access data when it starts at an address which can be divided by four. In the first case you would set the Mask field to end in 'FFFE', and in the second case to 'FFFC'.
If your controller can handle addresses without alignment restrictions then you can set it to 'FFFF' (which is of course the preferred
value).
There are also devices which can only access memory in the 24-bit memory area (everything below the 16 MB boundary). Usually these are Zorro-II controllers which cannot directly access memory located on, for example, an accelerator card. For these devices you set the mask to 0x00FFFFFF, indicating that the device can only access data in the 24-bit address space.
Devices which can access data located anywhere in memory (a SCSI controller which is embedded on an accelerator card, or a Zorro-III IDE or SCSI controller) should have a mask of 0xFFFFFFFF.
Here is an overview to clarify the Mask setting:
xxxxxxxF - Use a Mask ending with a 'F' if you're device is written correctly and can handle transfers to and from memory with any alignment.
xxxxxxxE - Use this if you're device can only handle 16-bit or WORD aligned transfers.
xxxxxxxC - Use this if you're device can only handle 32-bit or LONG aligned transfers.
FFFFFFFx - Use this Mask if you're device is written correctly and can work with any memory in the system. The first 'F' may also be '7' since there are no Amiga's which can have more than 2 GB of memory.
00FFFFFx - This Mask restricts transfers to the 24-bit address space, meaning it can only access ChipRAM and FastRAM in the 24-bit area (The 24-bit area is 0x00000000 to 0x00FFFFFF).
001FFFFx - This Mask restricts transfers to ChipRAM only (the old trackdisk.device needed this for example).
Always use the least restrictive Mask possible. The ideal Mask is 0xFFFFFFFF."
So there is the answer!
==========================================================================================================
In another area Amiga Classic threads, I noticed that the A4000T I have (with the CSPPC filled with 128MB memory, the Mother Board full of 16MB RAM) will boot to a maximum free ram of 77MB (with only WorkBench started). As I use up this memory with programs such as, Jack, the OWB or NetSurf browser, the Poseidon USB stack etc., I end up with paged ram using, initially, my ZorRam (128MB) card and then to a 768MB HDD swap partition. Some programs "choke" and fail to load when using virtual memory, or just crash the system. My question what do you folks use to save precious CSPPC RAM? [See question of using "Timberwolf" on Classic Amigas]
This is what I've tried so far: Turn 3D Acceleration OFF in GUI Prefs, Poseidon OFF until needed, not load AmiDock (instead I use the OS 3.9 68K version of IconLauncher), try not to use DOpus4 (using ClickDosII instead), disable as much of WB start-up commodities as possible, do not automatically mount all my volumes (only when needed), Lessen the Disk Drive buffers to around 100 (not the 600 Media Toolbox brings up), and use the IBrowse browser (a very low overhead program).
The 68K versions seem to conserve RAM better than their OS 4.1 counter-parts. But what do other Classic owners use?
Dan
This is a new thread based on questions and answers from my prior thread, "AmigaOS Classic 4.1 Update 2 Fails to Install." Those issues had been resolved and the thread had changed content. It ended with my question, "Is there any experience or documentation about using the different memory masks when setting up a hard drive partition: the choice of 'Any Memory,' '32-bit Aligned,' or '24-bit DMA?' "
Calgor had responded: "Regarding the Mask, I do not know specifically if OS4 behaves differently to OS3.9, as I have not needed to change the Mask value for any hard disk partitions.
But if you set the Mask to 0x7FFFFFFF - then all of the first 2GB of memory can be used. The last character being F means the driver/controller is not fussy about memory alignment. The last letter could also be set to E or C for different alignments. For those drivers (e.g. in OS3.9) that may only operate in 24-bit memory space (i.e. first 16 MB) you can set the mask to 0xFFFFFF - I needed to do this once for a CD driver in OS3.9 that would have random errors otherwise.
There is an *excellent* explanation in the old SFS 1.58 guide (from original SFS author archive or SFS_OLD.guide in latest 68k full sfs1.277 archive) under the section "the Mask field":
http://www.amiga-stuff.com/text/filesys ... S158.guide
I do not know which one is ultimately preferred out of 0XFFFFFFFF (4GB) or 0x7FFFFFFF (2GB), both for current systems, and for future compatibility."
He was, of course, correct. In the SFS guide says of MaxTransfer Values: "In any case, if you have a SCSI drive, then a MaxTransfer value of 0x7FFFFFFF should be just fine. For IDE drives, you probably need to
set it to 0x1FFFE or to 0xFFFE. Those values represent 128 kB minus 2 bytes and 64 kB minus 2 bytes respectively."
And of Transfer Masks: "The Mask field can be used to tell a filesystem that the device which comes with your (harddisk) controller cannot directly access its data
in all regions of memory available on your system.
When a device has been properly written it should be able to cope with data located anywhere in memory. For those devices the Mask should be set to 0xFFFFFFFF. Only badly written or very old devices need a different Mask -- in other words, the Mask value is a compatibility kludge to fix broken devices.
For example, some devices can't access data starting at an uneven address in memory. Some even can only access data when it starts at an address which can be divided by four. In the first case you would set the Mask field to end in 'FFFE', and in the second case to 'FFFC'.
If your controller can handle addresses without alignment restrictions then you can set it to 'FFFF' (which is of course the preferred
value).
There are also devices which can only access memory in the 24-bit memory area (everything below the 16 MB boundary). Usually these are Zorro-II controllers which cannot directly access memory located on, for example, an accelerator card. For these devices you set the mask to 0x00FFFFFF, indicating that the device can only access data in the 24-bit address space.
Devices which can access data located anywhere in memory (a SCSI controller which is embedded on an accelerator card, or a Zorro-III IDE or SCSI controller) should have a mask of 0xFFFFFFFF.
Here is an overview to clarify the Mask setting:
xxxxxxxF - Use a Mask ending with a 'F' if you're device is written correctly and can handle transfers to and from memory with any alignment.
xxxxxxxE - Use this if you're device can only handle 16-bit or WORD aligned transfers.
xxxxxxxC - Use this if you're device can only handle 32-bit or LONG aligned transfers.
FFFFFFFx - Use this Mask if you're device is written correctly and can work with any memory in the system. The first 'F' may also be '7' since there are no Amiga's which can have more than 2 GB of memory.
00FFFFFx - This Mask restricts transfers to the 24-bit address space, meaning it can only access ChipRAM and FastRAM in the 24-bit area (The 24-bit area is 0x00000000 to 0x00FFFFFF).
001FFFFx - This Mask restricts transfers to ChipRAM only (the old trackdisk.device needed this for example).
Always use the least restrictive Mask possible. The ideal Mask is 0xFFFFFFFF."
So there is the answer!
==========================================================================================================
In another area Amiga Classic threads, I noticed that the A4000T I have (with the CSPPC filled with 128MB memory, the Mother Board full of 16MB RAM) will boot to a maximum free ram of 77MB (with only WorkBench started). As I use up this memory with programs such as, Jack, the OWB or NetSurf browser, the Poseidon USB stack etc., I end up with paged ram using, initially, my ZorRam (128MB) card and then to a 768MB HDD swap partition. Some programs "choke" and fail to load when using virtual memory, or just crash the system. My question what do you folks use to save precious CSPPC RAM? [See question of using "Timberwolf" on Classic Amigas]
This is what I've tried so far: Turn 3D Acceleration OFF in GUI Prefs, Poseidon OFF until needed, not load AmiDock (instead I use the OS 3.9 68K version of IconLauncher), try not to use DOpus4 (using ClickDosII instead), disable as much of WB start-up commodities as possible, do not automatically mount all my volumes (only when needed), Lessen the Disk Drive buffers to around 100 (not the 600 Media Toolbox brings up), and use the IBrowse browser (a very low overhead program).
The 68K versions seem to conserve RAM better than their OS 4.1 counter-parts. But what do other Classic owners use?
Dan