Changeset 397 for soft/giet_vm


Ignore:
Timestamp:
Aug 12, 2014, 10:44:34 AM (10 years ago)
Author:
alain
Message:

Bug fix in malloc.c.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • soft/giet_vm/giet_libs/malloc.c

    r394 r397  
    237237                      unsigned int y )
    238238{
     239
     240#if GIET_DEBUG_MALLOC
     241giet_shr_printf("\n[MALLOC DEBUG] Malloc request for Heap[%d][%d] / size = %x\n",
     242                 x, y, size );
     243#endif
     244
    239245    // checking arguments
    240246    if (size == 0)
     
    283289 
    284290#if GIET_DEBUG_MALLOC
    285 giet_shr_printf("\n[MALLOC DEBUG] Malloc for Heap[%d][%d] / size = %x / base = %x\n",
    286                  x, y, size, base );
     291giet_shr_printf("\n[MALLOC DEBUG] Malloc vaddr from Heap[%d][%d] = %x\n",
     292                x, y, base );
    287293display_free_array(x,y);
    288294#endif
     
    376382    giet_get_xy( ptr, &x, &y );
    377383
     384#if GIET_DEBUG_MALLOC
     385giet_shr_printf("\n[MALLOC DEBUG] Free for vaddr = %x / x = %d / y = %d\n",
     386                 (unsigned int)ptr, x, y );
     387#endif
     388
    378389    // get the lock protecting heap[x][y]
    379390    lock_acquire( &heap[x][y].lock );
     
    407418
    408419#if GIET_DEBUG_MALLOC
    409 giet_shr_printf("\n[MALLOC DEBUG] Free for Heap[%d][%d] / base = %x / size = %x\n",
    410                  x, y, base, 1<<size_index );
    411420display_free_array(x,y);
    412421#endif
Note: See TracChangeset for help on using the changeset viewer.