Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • tests/heap.cfa

    r505450a r2ff42f4  
    1010// Created On       : Tue Nov  6 17:54:56 2018
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Sun Aug  9 08:05:16 2020
    13 // Update Count     : 57
     12// Last Modified On : Tue Aug  4 06:36:17 2020
     13// Update Count     : 56
    1414//
    1515
     
    232232                size_t s = i + default_mmap_start();                    // cross over point
    233233                char * area = (char *)calloc( 1, s );
     234//              if ( area == 0p ) abort( "calloc/realloc/free out of memory" );
    234235                if ( area[0] != '\0' || area[s - 1] != '\0' ||
    235236                         area[malloc_size( area ) - 1] != '\0' ||
    236                          ! malloc_zero_fill( area ) ) abort( "calloc/realloc/free corrupt storage3" );
     237                         ! malloc_zero_fill( area ) ) //abort( "calloc/realloc/free corrupt storage3" );
     238                        printf( "C %zd %d %d %d %d\n", s, area[0] != '\0', area[s - 1] != '\0', area[malloc_size( area ) - 1] != '\0', ! malloc_zero_fill( area ) );
    237239
    238240                // Do not start this loop index at 0 because realloc of 0 bytes frees the storage.
    239241                for ( r; i ~ 256 * 1024 ~ 26 ) {                                // start at initial memory request
    240242                        area = (char *)realloc( area, r );                      // attempt to reuse storage
     243//                      if ( area == 0p ) abort( "calloc/realloc/free out of memory" );
    241244                        if ( area[0] != '\0' || area[r - 1] != '\0' ||
    242245                                 area[malloc_size( area ) - 1] != '\0' ||
     
    252255                // initial N byte allocation
    253256                char * area = (char *)memalign( a, amount );    // aligned N-byte allocation
     257//              if ( area == 0p ) abort( "memalign/realloc/free out of memory" ); // no storage ?
    254258                //sout | alignments[a] | area;
    255259                if ( (size_t)area % a != 0 || malloc_alignment( area ) != a ) { // check for initial alignment
Note: See TracChangeset for help on using the changeset viewer.