some primitive profiling tools