NSObject: two profiling methods for void and non-void tasks.