Introduction
Allocating memory can be slow if it is done a lot in a multi-threaded
environment using the RTL memory allocator. This allocator replaces the
built in one speeding up memory allocations, at the cost of a small amount
of extra memory consumed.
All the proceeds from the sale of this product go to charity. If you would
like a free copy please send us an email requesting one and we'll be happy
to give one to you.
Features
- Replaces the Clarion RTL Memory Allocator (Malloc) with an alternative
Memory allocator.
- The Fastmem allocator requires no thread locks, so performs faster when
used in a multi-threading environment.
- Affects NEW, Queues, Memory File Driver and classes which NEW things
internally.
- Particularly good for Web Services programs built using NetTalk and
jFiles.
Limitations
As more people use Fastmem in a variety of environments, we are getting lots of helpful feedback on cases
which are not currently supported. We will investigate these and update this list as we encounter these.
JumpStart
- Add Global Extension
- Set the properties as you wish. See the Template Reference for a list of properties and what they do.
Multi DLL
If you have a multi-dll system (ie multiple apps) then you only need to add this template to the DataDLL app. ie the app which contains the
data dictionary.
HandCode
If you have a hand-coded project, and you wish to include Fastmem, then you need to duplicate the functionality of the template
in the application by hand. Fortunately this is very easy to do;
As early as possible in the code, add the following declaration;
include('fastmem.inc'),once
fmpp fmPatchProcess
This should be done inside the first module that is loaded (probably the Exe
in cases where you are dynamically loading the DLL's, or in the first DLL -
sometimes called the Data-DLL - in systems which load multiple DLL's at load
time.)
You can turn the new allocator on and off (at compile time) by adjusting the
equates at the top of fastmem.inc
MallocIsRTL EQUATE(0)
MallocIsDIY EQUATE(1)
You may also choose to comment out the two equates altogether and instead
declare these equates as Conditional Compile options in your project
settings.
Template
Global Template
File Manager Tab
DoNotAssertOnCloseMisuse
The default value for this is ON. If this is on then the buggy ASSERT when CLOSE is called is suppressed.
Create SQL Tables
The default value for this is OFF. If this is ON then a CREATE will be called for SQL tables which
have an error on OPEN. Note that if you are using File Manager 3 then this setting should still be set to
OFF,
FM3 will correctly create the tables when required - and only when required.
Support
Your questions, comments
and suggestions are welcome. See our web page (
www.capesoft.com)
for new versions. You can also contact us in one of the following ways:
CapeSoft Support |
Email |
|
Telephone |
+27 87 828 0123 |
Fax |
+27 21 715 2535 |
Post |
PO Box 511, Plumstead, 7801, Cape Town, South Africa
|
Installation
Distribution
There are no files to distribute.
License & Copyright
This template is copyright © 2015 by CapeSoft Software.
None of the included files may be distributed. Your programs
which use Fastmem can be distributed without any Fastmem royalties.
This product includes code copyright Dave Nichols and released under the MIT
license.
This product is provided as-is. Use it entirely at your own risk. Use of this
product implies your acceptance of this, along with the recognition of the
copyright stated above. In no way will CapeSoft Software, their
employees or affiliates be liable in any way for any damages or business losses you may
incur as a direct or indirect result of using this product
Version History
Version 1.04 (18 September 2018)- Add: Clarion 11 to install.
Version 1.03 (23 December 2015)- Fix: Bug causing
possible GPF when exceeding 4 gigs of Ram.
- Internal: Do a bit of rationalization in prep for doing some parts
in assembler
- Internal: zdMemTrimSlabs
Version 1.02 (17 December 2015)- Add: Support for
local mode compiles.
- Changed name of class from fmPatchProcess to FastMemClass
- Changed the name of the object from fmpp to Fastmem
- Added new methods to class, will be used to call Command functions
- new function: zdMemClearStats
- changed text for panic messages.
- Allow for a length which is not a multiple of the alignment size
("Program was given a bad alignment" error)
- Deprecated MallocIsRTL project define / equate
Version 1.01 (14 December 2015)- Fastmem.clw and
Fastmem.inc in the build were out of date.
Version 1.0 (11 December 2015)
Download latest version
here