cleanup swap, initial commit heapPointers