added method for profiling