-
Notifications
You must be signed in to change notification settings - Fork 202
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
Performance degradation seen with secure eventfd #1858
Comments
@jkr0103 Is this something you could look in? I mean, run the perf analysis. |
@jinengandhi-intel A quick check:
|
@dimakuv |
@jinengandhi-intel @vasanth-intel Indeed, there is no This doesn't make sense -- the commit 51e99f9 didn't change anything else other than eventfd. Are you absolutely sure that:
|
I cannot reproduce the Memcached results on my Icelake server. What was your exact test? Below is what I did. Memcached with eventfd degradationEventfd commit
Commit right before eventfd commit
As can be seen, there is basically no overhead. |
@vasanth-intel can you share the commands/our setup with Dmitrii so that he can repro the numbers? |
We run memcached workload on a client-server based setup in 2 different machines, where server and client are connected with 100GB LAN cable. We have shared the steps/commands and workspace to repro the numbers separately within Microsoft Teams. Following are the numbers we got from these workspaces. 1 commit before Secure Eventfd commit:
Secure Eventfd commit:
|
For completeness, a significant difference from the default Memcached example is that the Memcached-under-test here is run with |
Update: I am able to reproduce the ~20% slowdown. This happens on Quick results below.
|
Oops, in my previous comment the Gramine master (with secure eventfd) actually works better than Gramine without secure eventfd. So please ignore my "I am able to reproduce". I still can't reproduce the bug. |
@jinengandhi-intel @vasanth-intel How to reproduce the OpenVINO perf degradation? |
@dimakuv In Latency lower the number is better, so if I see your numbers avg latency with Gramine master is |
OpenVINO runs on the same machine as memcached, so you can look at memcached first and then we can setup the workspace for OpenVINO. |
Description of the problem
Performance benchmarking for workloads like MongoDB and Memcached are reporting degradation with secure eventfd commit when compared with the numbers with insecure eventfd.
MongoDB:
15% degradation is seen for MongoDB benchmark with 64 threads but almost no degradation is seen for 32 threads, when comparing with and without secure eventfd.
Please find the attached sheet where we have done some runs with Gramine master (which includes secure eventfd commit) and one commit before secure eventfd and you will notice the degradation.
mongodb_perf_degradation_secure_eventfd.xlsx
Memcached
With the higher batch size and 1:9 read write ratio, we see 20% degradation between these commits for latency and 8% for throughput when we compare the secure eventfd commit and 1 commit before that.
For lower data sizes like 1024, 8192, 16384 no degradation was seen and only for data size starting from 32768 bytes we see degradation. Please find the attached sheet for more details.
Memcached_secure_eventfd_analysis.xlsx
OpenVINO
This workload was not known to use eventfd and didn't even have the insecure eventfd flag configured but post secure eventfd commit, we are seeing 6-8% degradation for OpenVino BERT model tests.
openvino_secure_eventfd_analysis.xlsx
Steps to reproduce
git clone https://github.com/mongodb/mongo-perf.git
cd mongo-perf
wget https://repo.mongodb.org/apt/ubuntu/dists/focal/mongodb-org/5.0/multiverse/binary-amd64/mongodb-org-shell_5.0.21_amd64.deb
sudo dpkg -i mongodb-org-shell_5.0.21_amd64.deb
echo "deb http://security.ubuntu.com/ubuntu focal-security main" | sudo tee /etc/apt/sources.list.d/focal-security.list
sudo apt-get update
sudo apt-get install libssl1.1
Native run: mongod --nounixsocket --dbpath /var/run/db
gramine-direct: gramine-direct mongod --nounixsocket --dbpath /var/run/db
gramine-sgx: gramine-sgx mongod --nounixsocket --dbpath /var/run/db
~/jk/examples/mongodb/mongo-perf$ python3 benchrun.py -f testcases/complex_update.js -t 64
Expected results
No response
Actual results
No response
Gramine commit hash
51e99f9
The text was updated successfully, but these errors were encountered: