updating profiling module to bring it up to date with rest of foundation lib