Ignore:
Timestamp:
Jan 23, 2022, 5:29:07 PM (3 years ago)
Author:
Michael Brooks <mlbrooks@…>
Branches:
ADT, ast-experimental, enum, master, pthread-emulation, qualifiedEnum
Children:
f5a51db
Parents:
12c1eef
Message:

string performance impovement by removing redundant traversal of compacted heap, but likely just 1--2%

File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcfa/src/containers/string_res.cfa

    r12c1eef r97c215f  
    980980    int AmountUsed, AmountFree;
    981981
    982 //    assert( false );
    983 
    984982    AmountUsed = 0;
    985983    for ( HandleNode *i = Header.flink; i != &Header; i = i->flink ) { // calculate amount of byte area used
     
    996994                        //              reduce(( AmountFree / CurrSize - 3 ) * CurrSize ); // reduce the memory
    997995
    998     } // if
    999     compaction(this);                                   // compact the byte area, in the same or new heap area
     996        // `extend` implies a `compaction` during the copy
     997
     998    } else {
     999        compaction(this);                                       // in-place
     1000    }// if
    10001001#ifdef VbyteDebug
    10011002    {
Note: See TracChangeset for help on using the changeset viewer.