Changeset 430


Ignore:
Timestamp:
Jun 18, 2013 4:14:02 PM (7 years ago)
Author:
kulshres
Message:

Make it easier to debug location problems

Signed-off-by: Kshitij Kulshreshtha <kshitij@…>

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ADOL-C/src/tape_handling.cpp

    r427 r430  
    11851185{
    11861186    indexFree.clear();
    1187 #ifdef ADOLC_DEBUG
     1187#ifdef ADOLC_LOCDEBUG
    11881188    std::cerr << "StoreManagerIntegerBlock::StoreManagerIntegerBlock()\n";
    11891189#endif
     
    11921192StoreManagerLocintBlock::~StoreManagerLocintBlock()
    11931193{
    1194 #ifdef ADOLC_DEBUG
     1194#ifdef ADOLC_LOCDEBUG
    11951195    std::cerr << "StoreManagerIntegerBlock::~StoreManagerIntegerBlock()\n";
    11961196#endif
     
    12121212    maxsize(size), currentfill(numlives)
    12131213{
    1214 #ifdef ADOLC_DEBUG
     1214#ifdef ADOLC_LOCDEBUG
    12151215    std::cerr << "StoreManagerInteger::StoreManagerInteger()\n";
    12161216#endif
     
    12321232    ++currentfill;
    12331233
    1234 #ifdef ADOLC_DEBUG
     1234#ifdef ADOLC_LOCDEBUG
    12351235    std::cerr << "StoreManagerLocintBlock::next_loc: result: " << result << " fill: " << size() << "max: " << maxSize() << endl;
    12361236    list<struct FreeBlock>::iterator iter = indexFree.begin();
     
    12521252    bool found = false;
    12531253
    1254 #ifdef ADOLC_DEBUG
     1254#ifdef ADOLC_LOCDEBUG
    12551255    std::cerr << "StoreManagerLocintBlock::ensure_Block: required " << n << " ... ";
    12561256    std::cerr << "searching for big enough block " << endl;
     
    12691269    }
    12701270    if (!found) {
    1271 #ifdef ADOLC_DEBUG
     1271#ifdef ADOLC_LOCDEBUG
    12721272        std::cerr << "no big enough block...growing " << endl;
    12731273#endif
     
    12751275    }
    12761276
    1277 #ifdef ADOLC_DEBUG
     1277#ifdef ADOLC_LOCDEBUG
    12781278    std::cerr << "StoreManagerLocintBlock::ensure_Block: " << " fill: " << size() << "max: " << maxSize() <<  " ensure_Block (" << n << ")" << endl;
    12791279    iter = indexFree.begin();
     
    13071307    }
    13081308
    1309 #ifdef ADOLC_DEBUG
     1309#ifdef ADOLC_LOCDEBUG
    13101310    // index 0 is not used, means one slot less
    13111311    std::cerr << "StoreManagerIntegerBlock::grow(): increase size from " << oldMaxsize
     
    13151315    double *const oldStore = storePtr;
    13161316
    1317 #if defined(ADOLC_DEBUG)
     1317#if defined(ADOLC_LOCDEBUG)
    13181318    std::cerr << "StoreManagerInteger::grow(): allocate " << maxsize * sizeof(double) << " B doubles\n";
    13191319#endif
     
    13231323
    13241324    if (oldStore != NULL) { // not the first time
    1325 #if defined(ADOLC_DEBUG)
     1325#if defined(ADOLC_LOCDEBUG)
    13261326      std::cerr << "StoreManagerInteger::grow(): copy values\n";
    13271327#endif
     
    13291329      memcpy(storePtr, oldStore, oldMaxsize*sizeof(double));
    13301330
    1331 #if defined(ADOLC_DEBUG)
     1331#if defined(ADOLC_LOCDEBUG)
    13321332      std::cerr << "StoreManagerInteger::grow(): free " << oldMaxsize * sizeof(double) << "\n";
    13331333#endif
     
    13621362             iter++;
    13631363    }
    1364 #ifdef ADOLC_DEBUG
     1364#ifdef ADOLC_LOCDEBUG
    13651365    std::cerr << "Growing:" << endl;
    13661366    iter = indexFree.begin();
     
    13971397
    13981398    --currentfill;
    1399 #ifdef ADOLC_DEBUG
     1399#ifdef ADOLC_LOCDEBUG
    14001400    std::cerr << "free_loc: " << loc << " fill: " << size() << "max: " << maxSize() << endl;
    14011401
Note: See TracChangeset for help on using the changeset viewer.