Skip to content
Open
Show file tree
Hide file tree
Changes from 10 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
92 changes: 81 additions & 11 deletions irobot_benchmark/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -24,20 +24,90 @@ install(TARGETS
DESTINATION lib/${PROJECT_NAME}
)

set(TOPOLOGY_FILES
topology/sierra_nevada.json
topology/cedar.json
topology/mont_blanc.json
topology/white_mountain.json
topology/debug_sierra_nevada_reliable.json
topology/debug_sierra_nevada_best_effort.json
topology/debug_mont_blanc_reliable.json
topology/debug_mont_blanc_best_effort.json
set(FT topology/full_topologies)

set(TEST_TOPOLOGY_FILES
${FT}/cedar.json
${FT}/debug_mont_blanc_best_effort.json
${FT}/debug_mont_blanc_reliable.json
${FT}/debug_sierra_nevada_best_effort.json
${FT}/debug_sierra_nevada_reliable.json
${FT}/debug_white_mountain_best_effort.json
${FT}/mont_blanc.json
${FT}/sierra_nevada.json
${FT}/sierra_nevada_fixed_size.json
${FT}/debug_sierra_nevada_fixed_size_best_effort.json
${FT}/sierra_nevada_fixed_size_loaned.json
${FT}/sierra_nevada_loaned.json
${FT}/white_mountain.json
${FT}/white_mountain_fixed_size.json
${FT}/debug_white_mountain_fixed_size_best_effort.json
${FT}/white_mountain_fixed_size_loaned.json
${FT}/white_mountain_loaned.json
)

install(FILES
${TEST_TOPOLOGY_FILES}
DESTINATION lib/${PROJECT_NAME}/${FT})

set(SP topology/single_process)

set(TOPOLOGY_FILES_SINGLE_PROCESS
${SP}/pub_sub_loaned_10b.json
${SP}/pub_sub_loaned_100kb.json
${SP}/pub_sub_loaned_1mb.json
${SP}/pub_sub_loaned_4mb.json

${SP}/pub_sub_10b_ipc_on.json
${SP}/pub_sub_100kb_ipc_on.json
${SP}/pub_sub_1mb_ipc_on.json
${SP}/pub_sub_4mb_ipc_on.json

${SP}/pub_sub_10b_ipc_off.json
${SP}/pub_sub_100kb_ipc_off.json
${SP}/pub_sub_1mb_ipc_off.json
${SP}/pub_sub_4mb_ipc_off.json
)

install(FILES
${TOPOLOGY_FILES}
DESTINATION lib/${PROJECT_NAME}/topology)
${TOPOLOGY_FILES_SINGLE_PROCESS}
DESTINATION lib/${PROJECT_NAME}/${SP})

set(MP topology/multi_process)

set(TOPOLOGY_FILES_MULTI_PROCESS
${MP}/pub_ipc_off_10b.json
${MP}/pub_ipc_off_100kb.json
${MP}/pub_ipc_off_1mb.json
${MP}/pub_ipc_off_4mb.json

${MP}/sub_ipc_off_10b.json
${MP}/sub_ipc_off_100kb.json
${MP}/sub_ipc_off_1mb.json
${MP}/sub_ipc_off_4mb.json

${MP}/pub_loaned_10b.json
${MP}/pub_loaned_100kb.json
${MP}/pub_loaned_1mb.json
${MP}/pub_loaned_4mb.json

${MP}/sub_loaned_10b.json
${MP}/sub_loaned_100kb.json
${MP}/sub_loaned_1mb.json
${MP}/sub_loaned_4mb.json
)

install(FILES
${TOPOLOGY_FILES_MULTI_PROCESS}
DESTINATION lib/${PROJECT_NAME}/${MP})

set(PROFILES
profiles/ignore_local_endpoints.xml
profiles/shared_memory_fastdds_config.xml)

install(FILES
${PROFILES}
DESTINATION lib/${PROJECT_NAME}/profiles)

if(BUILD_TESTING)
find_package(ament_lint_auto REQUIRED)
Expand Down
44 changes: 44 additions & 0 deletions irobot_benchmark/profiles/ignore_local_endpoints.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
<?xml version="1.0" encoding="UTF-8" ?>
<dds xmlns="http://www.eprosima.com/XMLSchemas/fastRTPS_Profiles" >
<library_settings>
<intraprocess_delivery>OFF</intraprocess_delivery>
</library_settings>
<profiles>
<transport_descriptors>
<transport_descriptor>
<transport_id>UDP</transport_id>
<type>UDPv4</type>
</transport_descriptor>
</transport_descriptors>
<participant profile_name="participant_profile" is_default_profile="true">
<rtps>
<userTransports>
<transport_id>UDP</transport_id>
</userTransports>
<useBuiltinTransports>false</useBuiltinTransports>
</rtps>
</participant>
<data_writer profile_name="/number">
<propertiesPolicy>
<properties>
<property>
<name>fastdds.match_local_endpoints</name>
<value>false</value>
<propagate>false</propagate>
</property>
</properties>
</propertiesPolicy>
</data_writer>
<data_reader profile_name="/number">
<propertiesPolicy>
<properties>
<property>
<name>fastdds.match_local_endpoints</name>
<value>false</value>
<propagate>false</propagate>
</property>
</properties>
</propertiesPolicy>
</data_reader>
</profiles>
</dds>
26 changes: 26 additions & 0 deletions irobot_benchmark/profiles/shared_memory_fastdds_config.xml
Copy link
Collaborator

@alsora alsora Apr 8, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

profiles are in a different directory, and I think we already have one almost identical to this: scripts/rmw/rmw_fastrtps_cpp/zero-copy-shm.xml

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From what I was able to see, these are indeed identical. The potential path I see here to avoid this duplication would be to make the rmw_fastrtps_cpp/setup.sh to point to the (now) installed version of the xml file (under share/profiles/*) although OTOH, these also seem to be experimental scripts, so not sure if the change is justified.

Please let me know if you consider the change worthy so I can apply the change and give these scripts a try to confirm there are no regressions.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mauropasse / @alsora Is there any strong preference for having these profile files installed instead of what we currently have under scripts/rmw ?

I don't think I have enough experience with this to have an informed decision myself.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gentle ping

Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
<?xml version="1.0" encoding="UTF-8" ?>
<profiles xmlns="http://www.eprosima.com/XMLSchemas/fastRTPS_Profiles">

<!-- Default publisher profile -->
<data_writer profile_name="default publisher profile" is_default_profile="true">
<qos>
<publishMode>
<kind>ASYNCHRONOUS</kind>
</publishMode>
<data_sharing>
<kind>AUTOMATIC</kind>
</data_sharing>
</qos>
<historyMemoryPolicy>PREALLOCATED_WITH_REALLOC</historyMemoryPolicy>
</data_writer>

<data_reader profile_name="default subscription profile" is_default_profile="true">
<qos>
<data_sharing>
<kind>AUTOMATIC</kind>
</data_sharing>
</qos>
<historyMemoryPolicy>PREALLOCATED_WITH_REALLOC</historyMemoryPolicy>
</data_reader>

</profiles>
3 changes: 2 additions & 1 deletion irobot_benchmark/src/irobot_benchmark.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,8 @@ create_ros2_system(
static_cast<performance_test::ExecutorType>(options.executor),
performance_test::SpinType::SPIN,
events_output_path_opt,
options.csv_out);
options.csv_out,
options.timers_separate_thread);

return system;
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"nodes": [
{
"node_name": "debug_node",
"subscribers":[
{"topic_name":"amazon", "msg_type":"stamped9_float32", "qos_reliability":"best_effort"},
{"topic_name":"arkansas", "msg_type":"stamped4_int32", "qos_reliability":"best_effort"},
{"topic_name":"congo", "msg_type":"stamped4_int32", "qos_reliability":"best_effort"},
{"topic_name":"danube", "msg_type":"stamped_int64", "qos_reliability":"best_effort"},
{"topic_name":"ganges", "msg_type":"stamped4_int32", "qos_reliability":"best_effort"},
{"topic_name":"lena", "msg_type":"stamped50b", "qos_reliability":"best_effort"},
{"topic_name":"mekong", "msg_type":"stamped100b", "qos_reliability":"best_effort"},
{"topic_name":"missouri", "msg_type":"stamped10kb", "qos_reliability":"best_effort"},
{"topic_name":"nile", "msg_type":"stamped4_int32", "qos_reliability":"best_effort"},
{"topic_name":"parana", "msg_type":"stamped3_float32", "qos_reliability":"best_effort"},
{"topic_name":"salween", "msg_type":"stamped12_float32", "qos_reliability":"best_effort"},
{"topic_name":"tigris", "msg_type":"stamped4_float32", "qos_reliability":"best_effort"},
{"topic_name":"volga", "msg_type":"stamped_int64", "qos_reliability":"best_effort"}
]
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
{
"nodes": [
{
"node_name": "debug_node",
"subscribers":[
{"topic_name":"amazon", "msg_type":"stamped9_float32", "qos_reliability":"best_effort"},
{"topic_name":"arkansas", "msg_type":"stamped4_int32", "qos_reliability":"best_effort"},
{"topic_name":"brazos", "msg_type":"stamped_vector", "qos_reliability":"best_effort"},
{"topic_name":"chenab", "msg_type":"stamped1kb", "qos_reliability":"best_effort"},
{"topic_name":"colorado", "msg_type":"stamped4_int32", "qos_reliability":"best_effort"},
{"topic_name":"columbia", "msg_type":"stamped600kb", "qos_reliability":"best_effort"},
{"topic_name":"congo", "msg_type":"stamped4_int32", "qos_reliability":"best_effort"},
{"topic_name":"danube", "msg_type":"stamped_int64", "qos_reliability":"best_effort"},
{"topic_name":"ganges", "msg_type":"stamped4_int32", "qos_reliability":"best_effort"},
{"topic_name":"godavari", "msg_type":"stamped_vector", "qos_reliability":"best_effort"},
{"topic_name":"lena", "msg_type":"stamped_vector", "qos_reliability":"best_effort"},
{"topic_name":"loire", "msg_type":"stamped_vector", "qos_reliability":"best_effort"},
{"topic_name":"mekong", "msg_type":"stamped_vector", "qos_reliability":"best_effort"},
{"topic_name":"missouri", "msg_type":"stamped_vector", "qos_reliability":"best_effort"},
{"topic_name":"murray", "msg_type":"stamped_vector", "qos_reliability":"best_effort"},
{"topic_name":"nile", "msg_type":"stamped4_int32", "qos_reliability":"best_effort"},
{"topic_name":"ohio", "msg_type":"stamped100b", "qos_reliability":"best_effort"},
{"topic_name":"parana", "msg_type":"stamped3_float32", "qos_reliability":"best_effort"},
{"topic_name":"salween", "msg_type":"stamped12_float32", "qos_reliability":"best_effort"},
{"topic_name":"tagus", "msg_type":"stamped_vector", "qos_reliability":"best_effort"},
{"topic_name":"tigris", "msg_type":"stamped4_float32", "qos_reliability":"best_effort"},
{"topic_name":"volga", "msg_type":"stamped_int64", "qos_reliability":"best_effort"},
{"topic_name":"yamuna", "msg_type":"stamped4_int32", "qos_reliability":"best_effort"},
{"topic_name":"yamuna", "msg_type":"stamped4_int32", "qos_reliability":"best_effort"}
]
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"nodes": [
{
"node_name": "debug_node",
"subscribers":[
{"topic_name":"amazon", "msg_type":"stamped9_float32", "qos_reliability":"best_effort"},
{"topic_name":"arkansas", "msg_type":"stamped4_int32", "qos_reliability":"best_effort"},
{"topic_name":"brazos", "msg_type":"stamped25kb", "qos_reliability":"best_effort"},
{"topic_name":"chenab", "msg_type":"stamped1kb", "qos_reliability":"best_effort"},
{"topic_name":"colorado", "msg_type":"stamped4_int32", "qos_reliability":"best_effort"},
{"topic_name":"columbia", "msg_type":"stamped600kb", "qos_reliability":"best_effort"},
{"topic_name":"congo", "msg_type":"stamped4_int32", "qos_reliability":"best_effort"},
{"topic_name":"danube", "msg_type":"stamped_int64", "qos_reliability":"best_effort"},
{"topic_name":"ganges", "msg_type":"stamped4_int32", "qos_reliability":"best_effort"},
{"topic_name":"godavari", "msg_type":"stamped5kb", "qos_reliability":"best_effort"},
{"topic_name":"lena", "msg_type":"stamped50b", "qos_reliability":"best_effort"},
{"topic_name":"loire", "msg_type":"stamped1kb", "qos_reliability":"best_effort"},
{"topic_name":"mekong", "msg_type":"stamped100b", "qos_reliability":"best_effort"},
{"topic_name":"missouri", "msg_type":"stamped10kb", "qos_reliability":"best_effort"},
{"topic_name":"murray", "msg_type":"stamped100b", "qos_reliability":"best_effort"},
{"topic_name":"nile", "msg_type":"stamped4_int32", "qos_reliability":"best_effort"},
{"topic_name":"ohio", "msg_type":"stamped100b", "qos_reliability":"best_effort"},
{"topic_name":"parana", "msg_type":"stamped3_float32", "qos_reliability":"best_effort"},
{"topic_name":"salween", "msg_type":"stamped12_float32", "qos_reliability":"best_effort"},
{"topic_name":"tagus", "msg_type":"stamped50kb", "qos_reliability":"best_effort"},
{"topic_name":"tigris", "msg_type":"stamped4_float32", "qos_reliability":"best_effort"},
{"topic_name":"volga", "msg_type":"stamped_int64", "qos_reliability":"best_effort"},
{"topic_name":"yamuna", "msg_type":"stamped4_int32", "qos_reliability":"best_effort"}
]
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
{
"nodes": [
{
"node_name": "montreal",
"publishers": [
{"topic_name": "amazon", "msg_type": "stamped9_float32", "period_ms": 10, "msg_pass_by":"shared_ptr"},
{"topic_name": "nile", "msg_type": "stamped4_int32", "period_ms": 10, "msg_pass_by":"shared_ptr"},
{"topic_name": "ganges", "msg_type": "stamped4_int32", "period_ms": 10, "msg_pass_by":"shared_ptr"},
{"topic_name": "danube", "msg_type": "stamped_int64", "period_ms": 10, "msg_pass_by":"shared_ptr"}
]
},

{
"node_name": "lyon",
"subscribers":[
{"topic_name":"amazon", "msg_type":"stamped9_float32"}
],
"publishers": [
{"topic_name": "tigris", "msg_type": "stamped4_float32", "period_ms": 10, "msg_pass_by":"shared_ptr"}
]
},

{
"node_name": "hamburg",
"subscribers":[
{"topic_name":"nile", "msg_type":"stamped4_int32"},
{"topic_name":"tigris", "msg_type":"stamped4_float32"},
{"topic_name":"ganges", "msg_type":"stamped4_int32"},
{"topic_name":"danube", "msg_type":"stamped_int64"}
],
"publishers": [
{"topic_name": "parana", "msg_type": "stamped3_float32", "period_ms": 10, "msg_pass_by":"shared_ptr"}
]
},

{
"node_name": "osaka",
"subscribers":[
{"topic_name":"parana", "msg_type":"stamped3_float32"}
],
"publishers": [
{"topic_name": "salween", "msg_type": "stamped12_float32", "period_ms": 100, "msg_pass_by":"shared_ptr"}
]
},

{
"node_name": "mandalay",
"subscribers":[
{"topic_name":"salween", "msg_type":"stamped12_float32"},
{"topic_name":"danube", "msg_type":"stamped_int64"}
],
"publishers": [
{"topic_name": "missouri", "msg_type": "stamped10kb", "period_ms": 100, "msg_pass_by":"shared_ptr"}
]
},

{
"node_name": "ponce",
"subscribers":[
{"topic_name":"missouri", "msg_type":"stamped10kb"},
{"topic_name":"danube", "msg_type":"stamped_int64"},
{"topic_name":"volga", "msg_type":"stamped_int64"}
],
"publishers": [
{"topic_name": "mekong", "msg_type": "stamped100b", "period_ms": 500, "msg_pass_by":"shared_ptr"},
{"topic_name": "congo", "msg_type": "stamped4_int32", "period_ms": 100, "msg_pass_by":"shared_ptr"}
]
},

{
"node_name": "barcelona",
"subscribers":[
{"topic_name":"mekong", "msg_type":"stamped100b"}
],
"publishers": [
{"topic_name": "lena", "msg_type": "stamped50b", "period_ms": 100, "msg_pass_by":"shared_ptr"}
]
},

{
"node_name": "georgetown",
"subscribers":[
{"topic_name":"lena", "msg_type":"stamped50b"}
],
"publishers": [
{"topic_name": "volga", "msg_type": "stamped_int64", "period_ms": 500, "msg_pass_by":"shared_ptr"}
]
},

{
"node_name": "geneva",
"subscribers":[
{"topic_name":"congo", "msg_type":"stamped4_int32"},
{"topic_name":"danube", "msg_type":"stamped_int64"},
{"topic_name":"parana", "msg_type":"stamped3_float32"}
],
"publishers": [
{"topic_name": "arkansas", "msg_type": "stamped4_int32", "period_ms": 100, "msg_pass_by":"shared_ptr"}
]
},

{
"node_name": "arequipa",
"subscribers":[
{"topic_name":"arkansas", "msg_type":"stamped4_int32"}
]
}
]
}
Loading