Performance enhancement in computing difftime
running the perf profiler on slurmctld on our production cluster (with select/cons_res) showed that with our configuration & workload highest up in the profile are calls to difftime() and _cr_job_list_sort(), in total accounting for ~37% of the total runtime. By sacrificing some theoretical portability by replacing the calls to difftime() with a simple inline subtraction that 37% should be substantially reduced. As I saw identical code also in the linear and serial plugins, I fixed those in the same manner, although I don't know if this performance issue turns up when using those plugins.
Please register or sign in to comment