FASTMM v4.27 下载 使用方法: 解开FastMM427.zip,找到里面的FastMm427\Replacement BorlndMM DLL\Precompiled\for Delphi IDE\Performance目录下的borlndMM.dll文件,把它复制到Delphi安装目录的bin中,把原文件覆盖即可。
在应用程序中的使用,作者是这样说的: Using FastMM is very simple. All you have to do is add FastMM.pas as the very first unit in your project's .dpr file. Note that if you application uses .DLL files and you will be sharing memory (i.e. passing long strings or dynamic arrays between the DLL and main application), that you have to use FastMM in the DLL as well. If FastMM is not the first file in the "uses" section of the .dpr file, you will get an "invalid pointer operation" during program startup (meaning the default MM has already been used to allocate some memory).
意思是您只需要把FastMM4.pas加入到你的项目中,但要保证dpr文件uses后面第一个文件就是FastMM4.pas即可,经过本人实验,实际使用中还要加FastMM4Messages.pas或者设置一个搜索路径(设路径比较麻烦,还是加进来吧)。然后编译你的程序就可以了。 如果你的dll用了共享内存,那么就用FastMM427\Replacement BorlndMM DLL\Precompiled\for Applications\Performance中的BorlndMM.dll和你的DLL文件一起分发即可。
在d7下安装FastMM4 FastMM 在外国 Delphi 社区非常有名,其主要目的就是重新实现一个高效、安全、稳定的内存管理器(Borland 的内存管理器问题多多,如 Dll 和 Exe 间无法共享,多线程下效率底--一些情况下甚至于低一个数量级!) 总而言之就是使用之后速度提升很大.
网上找到的安装方法,不过还会碰见些问题 先网上自行搜索下载 FastMm 解压
找到里面的\Replacement BorlndMM DLL\Precompiled\for Delphi IDE\Performance目录下的borlndMM.dll文件,把它复制到Delphi安装目录的bin中(建议把原来的备份下),把原文件覆盖即可。您只需要把FastMM4.pas加入到你的项目中,但要保证dpr文件uses后面第一个文件就是FastMM4.pas即可,经过本人实验,实际使用中还要加FastMM4Messages.pas或者设置一个搜索路径(设路径比较麻烦,还是加进来吧)。
这里引用 FastMM4.pas 要这样操作,安住 ctrl+F12 双击 类型为 Project的 文件 有这么一句 uses Forms, 新建 pas文件 命名为 FastMM4.pas 直接把代码复制过来 然后在 uses 后面可能会出现 FastMM4 in 'Source\FastMM4.pas'; 这时把 该这样 uses FastMM4, Forms, 同样的 FastMM4Messages.pas 文件也如此
另外 因为我设置了 项目的lib路径 所以还得把FastMM4.dcu和FastMM4Messages.dcu放到我的项目根目录下,如果提示找不到的话,可以放到delphi的lib目录里面去,
最后 在调试程序的时候,关闭了可能会弹出个提示框,提示内存什么之类的,我也没搞懂,别管它就行了,其实这个可以消除的,但要重新编译 FastMM4 ,不嫌麻烦就自己网上找答案嘛.
在delphi7中使用fastMM 4.62编译时提示"file not found fastMM4Option.inc" 怎么处理? 来自: magicgod, 时间: 2006/04/11 16:01:19, ID: 3411383 把fastMM4Option.inc的路径加到search unit去,或者把fastMM4Option.inc拷贝到lib下去。
|