337{
338 int i=0, error_test = 1;
339 unsigned long spec,
j;
340 int n = 1;
342 int decr = 2;
343 int last_kept_freed = 0;
347
349
354
355 if (argc > 1) sscanf(argv[1], "%d", &error_test);
356 if (argc > 2) sscanf(argv[2],
"%d", &
seed);
358
359 if (argc > 3) sscanf(argv[3], "%d", &n);
360 if (argc > 4) sscanf(argv[4], "%d", &decr);
361
362 if (decr < 2) decr = 2;
363 printf(
"seed == %d\n",
seed);
364 fflush(stdout);
365 while (1)
366 {
368 {
370 printf("\nCells: %d KeptAddr:%d AlwaysKeptAddr:%d\n", n_cells,
373#else
374 0, 0
375#endif
376 );
377
378 printf("Checking Memory and all cells ");
379 fflush(stdout);
381 printf("\n");
385 fflush(stdout);
386#if CHECK_LEVEL > 0 && TRACK_LEVEL > 0
387 if (error_test &&
errors == 0)
388 {
391 {
393 }
394 }
395#endif
398 {
401 }
406 if (
om_Info.CurrentRegionsAlloc > 0)
407 {
410 }
413 n--;
414 if (n <= 0 || n_cells <= 100)
415 {
417 }
418 else
419 {
420 n_cells = n_cells / decr;
421 }
422 }
427 {
429 {
436 }
437 }
439 {
441 {
447 }
448 }
450 {
452 {
458 }
459 }
460 else
461 {
467 {
468 printf(
"%d:",
i / 1000);
469 fflush(stdout);
470 }
471 }
474
475 if ((
i % 10000) == 0 &&
i != n_cells &&
i!=last_kept_freed)
476 {
477 printf("F:");
480 }
481#if 0
483 {
485 {
487 }
488 }
489#endif
490 }
491 return 0;
492}
void * om_AlwaysKeptAddrs
#define omInitGetBackTrace()
#define omListLength(ptr)
void TestAlloc(omMemCell cell, unsigned long spec)
omMemCell_t cells[MAX_CELLS]
void TestFree(omMemCell cell)
void omtMergeStickyBins(omMemCell cell, int n)
void TestRealloc(omMemCell cell, unsigned long spec)
void omtTestDebug(omMemCell cell)
void omCheckCells(int n, int level, omMemCell_t *cells)
void TestDup(omMemCell cell, unsigned long spec)
#define myprintf(format, args...)
#define omPrintUsedAddrs(F, max)
#define omPrintBinStats(F)
#define omInitRet_2_Info(argv0)