⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 testsharemem.dpr

📁 delphi开发语言下的源代码分析
💻 DPR
字号:
program TestShareMem;

{$APPTYPE CONSOLE}

uses
  QMemory,      // <-- Must be the first unit in the uses clause. Use in calling program only and NOT IN DLL!
                // <-- QMemory is 20% faster than Delphi's MemMgr
  ShareMemRep;

function AllocSpeedTest : LongWord;
  external 'TestDll.dll';
function SequentialAllocTest : LongWord;
  external 'TestDll.dll';
function ThreadAllocTest : LongWord;
  external 'TestDll.dll';

begin
  Writeln('Allocate 1000 random blocks of (4097 .. 10000) bytes 1000 times');
  Writeln('Time: ', AllocSpeedTest, ' ms, ok.');

  Writeln;
  Writeln('10 Threads Allocated');
  Writeln('Time: ', ThreadAllocTest, ' ms, ok.');
end.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -