ITADN

Measuring time and memory usage with --cg option

#170Closedkylekim2123 创建于 2024-08-01
K
kylekim2123commented
I’m building an algorithm scoring system using Isolate and have some questions. I am running users’ code in Isolate as a separate process and measuring the time and memory usage. For Java code, which runs in multiple threads, I use the –cg option for scoring. I have two questions: 1. I use the cg-mem value as the memory measurement result, but it is often significantly less than max-rss. Since max-rss is the maximum memory usage of a single process and cg-mem is the sum of the memory usage of multiple processes, why is cg-mem less? Is it okay to grade based on cg-mem? ``` time:0.016 time-wall:0.021 max-rss:9856 csw-voluntary:5 csw-forced:2 cg-mem:3136 exitcode:0 ``` 2. I understand that the time value when using the –cg option is the sum of the execution times of multiple processes. Is it better to use wall-time rather than time for grading? I apologize for any awkwardness in my sentences due to the translator. Thanks. 🙇
关闭于 2024-08-02 2 条评论