You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When targets with many dependencies call ament_target_dependencies, this calls ament_deduplicate_libraries and then ament_pack_build_configuration. For some reason ament_pack_build_configuration takes several seconds for a moderate number of libraries.
For two libraries, it takes 250ms (which is still kind of slow), but this ends up being the minority of the work done under ament_target_dependencies:
However, when you have 3632 dependencies (which seems like a lot but which is mostly separate type support libraries just from linking to Nav2) it takes 1.2 seconds. which then becomes the majority of the time of ament_target_dependencies
It looks like the bulk of that time comes from all the calls to
list(GET _argn ${_index} _lib)
for every single element, and that access takes 0.315ms, but that addes up over a lot of dependencies.
When building packages, this adds several seconds to the build time, just to add semicolons between library names.
This is on humble with ament_cmake 1.3.5.
The text was updated successfully, but these errors were encountered:
Another example: here is a build of nav2_behavior_tree. You can see that the majority of the time in CMake build time ends up being due to this call, repeated many times for multiple targets:
When targets with many dependencies call
ament_target_dependencies
, this callsament_deduplicate_libraries
and thenament_pack_build_configuration
. For some reasonament_pack_build_configuration
takes several seconds for a moderate number of libraries.For two libraries, it takes 250ms (which is still kind of slow), but this ends up being the minority of the work done under
ament_target_dependencies
:However, when you have 3632 dependencies (which seems like a lot but which is mostly separate type support libraries just from linking to Nav2) it takes 1.2 seconds. which then becomes the majority of the time of
ament_target_dependencies
It looks like the bulk of that time comes from all the calls to
for every single element, and that access takes 0.315ms, but that addes up over a lot of dependencies.
When building packages, this adds several seconds to the build time, just to add semicolons between library names.
This is on humble with ament_cmake 1.3.5.
The text was updated successfully, but these errors were encountered: