Changeset 13d33a75 for tests/heap.cfa


Ignore:
Timestamp:
Aug 18, 2020, 4:31:19 PM (4 years ago)
Author:
Thierry Delisle <tdelisle@…>
Branches:
ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast, new-ast-unique-expr, pthread-emulation, qualifiedEnum
Children:
8e9d567
Parents:
ef9988b (diff), f2384c9a (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge branch 'master' into new-ast

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tests/heap.cfa

    ref9988b r13d33a75  
    1010// Created On       : Tue Nov  6 17:54:56 2018
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Tue Aug  4 06:36:17 2020
    13 // Update Count     : 56
     12// Last Modified On : Sun Aug  9 08:05:16 2020
     13// Update Count     : 57
    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" );
    235234                if ( area[0] != '\0' || area[s - 1] != '\0' ||
    236235                         area[malloc_size( area ) - 1] != '\0' ||
    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 ) );
     236                         ! malloc_zero_fill( area ) ) abort( "calloc/realloc/free corrupt storage3" );
    239237
    240238                // Do not start this loop index at 0 because realloc of 0 bytes frees the storage.
    241239                for ( r; i ~ 256 * 1024 ~ 26 ) {                                // start at initial memory request
    242240                        area = (char *)realloc( area, r );                      // attempt to reuse storage
    243 //                      if ( area == 0p ) abort( "calloc/realloc/free out of memory" );
    244241                        if ( area[0] != '\0' || area[r - 1] != '\0' ||
    245242                                 area[malloc_size( area ) - 1] != '\0' ||
     
    255252                // initial N byte allocation
    256253                char * area = (char *)memalign( a, amount );    // aligned N-byte allocation
    257 //              if ( area == 0p ) abort( "memalign/realloc/free out of memory" ); // no storage ?
    258254                //sout | alignments[a] | area;
    259255                if ( (size_t)area % a != 0 || malloc_alignment( area ) != a ) { // check for initial alignment
Note: See TracChangeset for help on using the changeset viewer.