Activator refactoring and performance tuning

Migrated to .Net 4.5