2->4 and small fixes
2->4
move memory allocations iterator helpers
move heap structures