Modify and debug allocation routines.