add memory consumption profiling program