ActiveAE: fixes, optimizations