341{
342 int i=0, error_test = 1;
343 unsigned long spec,
j;
344 int n = 1;
346 int decr = 2;
347 int last_kept_freed = 0;
350
352
357
358 if (argc > 1) sscanf(argv[1], "%d", &error_test);
359 if (argc > 2) sscanf(argv[2],
"%d", &
seed);
361
362 if (argc > 3) sscanf(argv[3], "%d", &n);
363 if (argc > 4) sscanf(argv[4], "%d", &decr);
364
365 if (decr < 2) decr = 2;
366 printf(
"seed == %d\n",
seed);
367 fflush(stdout);
368 while (1)
369 {
371 {
373 printf("\nCells: %d KeptAddr:%d AlwaysKeptAddr:%d\n", n_cells,
376#else
377 0, 0
378#endif
379 );
380
381 printf("Checking Memory and all cells ");
382 fflush(stdout);
384 printf("\n");
388 fflush(stdout);
389#if CHECK_LEVEL > 0 && TRACK_LEVEL > 0
390 if (error_test &&
errors == 0)
391 {
394 {
396 }
397 }
398#endif
401 {
404 }
409 if (
om_Info.CurrentRegionsAlloc > 0)
410 {
413 }
416 n--;
417 if (n <= 0 || n_cells <= 100)
418 {
420 }
421 else
422 {
423 n_cells = n_cells / decr;
424 }
425 }
430 {
432 {
439 }
440 }
442 {
444 {
450 }
451 }
453 {
455 {
461 }
462 }
463 else
464 {
470 {
471 printf(
"%d:",
i / 1000);
472 fflush(stdout);
473 }
474 }
477
478 if ((
i % 10000) == 0 &&
i != n_cells &&
i!=last_kept_freed)
479 {
480 printf("F:");
483 }
484#if 0
486 {
488 {
490 }
491 }
492#endif
493 }
494 return 0;
495}
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)