-
Notifications
You must be signed in to change notification settings - Fork 100
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
timestamping sended messages using msg_control #226
Comments
Hi @GreenFatGuy, Thanks for raising this issue!
Unfortunately, I don't have any performance metrics to hand for this specific case, comparing timestamped sends to non-timestamped sends. However, I expect the answer to this question would depend greatly on the design of your application. Particularly, I would think that the main overhead of timestamping is likely to come from polling the error queue of the socket you're sending over, rather than during the actual sending of the packet itself. It might be worth having a go at testing this with your application, both timestamped and not, to see what the difference is for your use case. To better understand any overhead, it might be interesting to measure:
I've had a look through the code and, indeed, it appears that onload does not support requesting timestamping via control messages (see ci_ip_cmsg_send for the currently understood control messages on transmit, linked version is master). I have raised this internally under ON-15846 as an enhancement, and expect that it's a good candidate to be included. Hope this helps! |
Hi @jfeather-amd ! Thank you for your answers, that brings some light! Awesome that this feature might appear in future releases! Considering measurements on my side: I understand that the main part of the overhead is caused due to error queue polling. I was speaking mainly about overhead inside the onload stack, which I am not in control of. I would expect that there is some because with timestamping on there is some additional work happening: writing timestamps, queuing messages with info back to the error queue, etc. I will try to measure this aspect as far as I can. If I get some robust results that I will be sure about - I will try to bring them back as I think this might be useful for some people to know. |
Hello!
I have a server with Solarflare Communications XtremeScale SFC9250 NIC. I am also using Onload 8.1.2.26.
My application is based on your example
src/tests/onload/hwtimestamping/tx_timestamping.c
. It opens a socket, sends packets, and tries to receive timestamps of each packet sent via readingMSG_ERRQUEUE
.I run this application like this:
sudo EF_TX_TIMESTAMPING=1 onload --profile=latency ./sendmsg_app <app_options>
I've noticed that I manage to retrieve timestamps when flags are set via
setsockopt
:However, I don't get any timestamps when I set the flag
SOF_TIMESTAMPING_TX_HARDWARE
per message viacontrol_msg
:If I try
recvmsg(sockfd, &some_msg, MSG_ERRQUEUE)
afterward, I constantly getEAGAIN
.This setup works without onload: I've tested it on my local machine. It is not capable of reporting hardware timestamps, but I get software ones just fine. Also, the possibility of timestamping per msg is written in Linux documentation (section 1.3.4)
I must say that I did not find anywhere that onload can do so. However, I didn't see anything saying the opposite. I am sorry if I missed this information somewhere.
The reason why I am interested in setting up a timestamping option per message rather than per socket is that I don't want to experience any overhead for every message. As far as I know, if we talking about a standard Linux network stack, there will be some overhead if we timestamp packets. By sampling messages that are being timestamped, I am trying to lower it.
So here are two main questions from me:
The text was updated successfully, but these errors were encountered: