This is done by receiving the entire message all at once instead of reading 1024 byte chunks and stitching them together as you go.
Proposed change(s)
Describe the changes made in this PR.
Useful links (GitHub issues, JIRA tickets, forum threads, etc.)
Provide any relevant links here.
Types of change(s)
[X] Performance Enhancement
Testing and Verification
Test machine: i7 9700k, 32Gb ddr4 2133MHz ram.
So before the change, it took between 3.5ms and 4.9ms to read a message of length 2764858 byes (24-bit 720p uncompressed image message)
After the change, it took between 0.5ms and 1.1ms.
Nice.
Test Configuration:
Unity Version: [e.g. Unity 2021.1.14f1]
Unity machine OS + version: [e.g. Ubuntu 18.04]
ROS machine OS + version: [e.g. Ubuntu 18.04, ROS Melodic]
Checklist
[ ] Ensured this PR is up-to-date with the dev branch
Improving the performance read_message, see https://github.com/Unity-Technologies/ROS-TCP-Endpoint/issues/89
This is done by receiving the entire message all at once instead of reading 1024 byte chunks and stitching them together as you go.
Proposed change(s)
Describe the changes made in this PR.
Useful links (GitHub issues, JIRA tickets, forum threads, etc.)
Provide any relevant links here.
Types of change(s)
Testing and Verification
Test machine: i7 9700k, 32Gb ddr4 2133MHz ram. So before the change, it took between 3.5ms and 4.9ms to read a message of length 2764858 byes (24-bit 720p uncompressed image message) After the change, it took between 0.5ms and 1.1ms. Nice.
Test Configuration:
Checklist
dev
branchdev
branchOther comments