release uses smartptrs and memory tracker