- 13 Dec, 2016 1 commit
-
-
Jeffrey Lee authored
Detail: With this set of changes, each AMB node is now the owner of a fake DANode which is linked to a PMP. From a user's perspective the behaviour of AMBControl is the same as before, but rewriting it to use PMPs internally offers the following (potential) benefits: * Reduction in the amount of code which messes with the CAM & page tables, simplifying future work/maintenance. Some of the AMB ops (grow, shrink) now just call through to OS_ChangeDynamicArea. However all of the old AMB routines were well-optimised, so to avoid a big performance hit for common operations not all of them have been removed (e.g. mapslot / mapsome). Maybe one day these optimal routines will be made available for use by regular PMP DAs. * Removal of the slow Service_MemoryMoved / Service_PagesSafe handlers that had to do page list fixup after the core kernel had reclaimed/moved pages. Since everything is a PMP, the kernel will now deal with this on behalf of AMB. * Removal of a couple of other slow code paths (e.g. Do_AMB_MakeUnsparse calls from OS_ChangeDynamicArea) * Potential for more flexible mapping of application space in future, e.g. sparse allocation of memory to the wimp slot * Simpler transition to an ASID-based task swapping scheme on ARMv6+? Other changes of note: * AMB_LazyMapIn switch has been fixed up to work correctly (i.e. turning it off now disables lazy task swapping and all associated code instead of producing a build error) * The DANode for the current app should be accessed via the GetAppSpaceDANode macro. This will either return the current AMB DANode, or AppSpaceDANode (if e.g. pre-Wimp). However be aware that AppSpaceDANode retains the legacy behaviour of having a base + size relative to &0, while the AMB DANodes (identifiable via the PMP flag) are sane and have their base + size relative to &8000. * Mostly-useless DebugAborts switch removed * AMBPhysBin (page number -> phys addr lookup table) removed. Didn't seem to give any tangible performance benefit, and was imposing hidden restrictions on memory usage (all phys RAM fragments in PhysRamTable must be multiple of 512k). And if it really was a good optimisation, surely it should have been applied to all areas of the kernel, not just AMB! Other potential future improvements: * Turn the fake DANodes into real dynamic areas, reducing the amount of special code needed in some places, but allow the DAs to be hidden from OS_DynamicArea 3 so that apps/users won't get too confused * Add a generic abort trapping system to PMPs/DAs (lazy task swapping abort handler is still a special case) File changes: - s/ARM600, s/VMSAv6, s/ExtraSWIs - Remove DebugAborts - s/ArthurSWIs - Remove AMB service call handler dispatch - s/ChangeDyn - AMB_LazyMapIn switch fixes. Add alternate internal entry points for some PMP ops to allow the DANode to be specified (used by AMB) - s/Exceptions - Remove DebugAborts, AMB_LazyMapIn switch fixes - s/Kernel - Define GetAppSpaceDANode macro, AMB_LazyMapIn switch fix - s/MemInfo - AMB_LazyMapIn switch fixes - s/AMBControl/AMB - Update GETs - s/AMBControl/Memory - Remove block size quantisation, AMB_BlockResize (page list blocks are now allocated by PMP code) - s/AMBControl/Options - Remove PhysBin definitions, AMBMIRegWords (moved to Workspace file), AMB_LimpidFreePool switch. Add AMB_Debug switch. - s/AMBControl/Workspace - Update AMBNode to contain an embedded DANode. Move AMBMIRegWords here from Options file. - s/AMBControl/allocate - Fake DA node initialisation - s/AMBControl/deallocate - Add debug output - s/AMBControl/growp, growshrink, mapslot, mapsome, shrinkp - Rewrite to use PMP ops where possible, add debug output - s/AMBControl/main - Remove PhysBin initialisation. Update the enumerate/mjs_info call. - s/AMBControl/memmap - Low-level memory mapping routines updated or rewritten as appropriate. - s/AMBControl/readinfo - Update to cope with DANode - s/AMBControl/service - Remove old service call handlers - s/AMBControl/handler - DA handler for responding to PMP calls from OS_ChangeDynamicArea; just calls through to growpages/shrinkpages as appropriate. Admin: Tested on pretty much everything currently supported Version 5.66. Tagged as 'Kernel-5_66'
-
- 15 Apr, 2012 1 commit
-
-
Jeffrey Lee authored
Detail: s/ChangeDyn: - Apply various optimisations to OS_ChangeDynamicArea to reduce the execution time when performing large grows/shrinks. - Optimisations can be toggled on/off with FastCDA_* flags for debugging. - On a 1GHz 512MB BB-xM, the initial *FreePool call now takes 0.15s instead of 13.46s. On a 512MB Iyonix the time has dropped from 1.18s to 0.23s. - Growing screen memory (on BB-xM) has also seen significant gains - between 2x and 4x speedup, depending on what state the source pages are in. - Added/updated documentation for a few functions and made more use of ROUTs for safety s/ARM600, s/VMSAv6: - Update BangCamUpdate, etc. to add support for the PageFlags_Unsafe flag that OS_ChangeDynamicArea uses to bypass cache/TLB maintenance in some situations - Avoid BangCamUpdate calling BangL2PT to map out the page if the page isn't mapped in (avoids unnecessary cache/TLB flush) s/ArthurSWIs: - Add extra ASSERT for safety s/AMBcontrol/memory - Fix incorrect assumption that the usable size of a heap block is always 8 less than the value stored in the header. Even with the old 8 byte aligned allocations the usable size will always be 4 bytes less than the value in the header. This code would have resulted in some slight memory wasteage, as AMBcontrol will have always tried growing the block four bytes bigger than needed. Admin: Tested on Iyonix & BB-xM Version 5.35, 4.79.2.146. Tagged as 'Kernel-5_35-4_79_2_146'
-
- 10 Nov, 2000 1 commit
-
-
Mike Stephens authored
Version 5.35, 4.79.2.12. Tagged as 'Kernel-5_35-4_79_2_12'
-
- 15 Sep, 2000 1 commit
-
-
Kevin Bracey authored
* Added ARM_IMB and ARM_IMBRange SWIs as recommended by ARMv5. * Some early prototype HAL bits popped in - a lot of source restructuring still to come. * New debug target creates an AIF image with debug information, and translates this into an ASCII object file for the 16702B logic analyser. Version 5.35, 4.79.2.1. Tagged as 'Kernel-5_35-4_79_2_1'
-
- 04 Apr, 2000 1 commit
-
-
Kevin Bracey authored
Details: The Kernel will now compile to produce a pure 32-bit system if No26bitCode is set to TRUE. If No26bitCode is FALSE, then the Kernel will be a standard 26-bit Kernel, although some internal changes have taken place to minimise compile switches between the two cases. See Docs.32bit for more technical info. The hardest part was the flood-fill... Other changes: Pointer shape changes now take place on the next VSync, rather than actually WAITING for the VSync. Turning the Hourglass on shouldn't slow your machine down by 5% now :) Lots of really crusty pre-IOMD code removed. Admin: Tested in 32 and 26-bit forms in a limited desktop build. Basically, this will need to see a lot of use to iron out difficulties. I'd like anyone who has a non-frozen project to at least attempt using this Kernel. Version 5.23. Tagged as 'Kernel-5_23'
-
- 06 Nov, 1996 1 commit
-
-
Neil Turton authored
-