Refactor profiling module
Description
Make the use of local profile_t
objects unnecessary by storing all of them in a hashmap in the profiling module. Change the routines profiling_in
and profiling_out
to use a string as argument and retrieve the corresponding profile_t
object from the hashmap. This simplifies the code and also makes it easier to see which profiling region is closed.
Also, add new macros PUSH_SUB_WITH_PROFILE
and POP_SUB_WITH_PROFILE
: they combine the PUSH/POP_SUB macros with profiling_in/profiling_out calls using the same name. This makes it possible to save some lines.
News snippet
Refactor profiling module
Checklist
-
I have checked that my code follows the Octopus coding standards -
I have added tests for all the new features added in this request.
Edited by Sebastian Ohlmann