reorganized compile()
minor optimizations
changed storage name