Skip to content
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

Optimize find_unix_sk_by_ino() #339

Closed
xemul opened this issue Jun 29, 2017 · 0 comments · Fixed by #1020
Closed

Optimize find_unix_sk_by_ino() #339

xemul opened this issue Jun 29, 2017 · 0 comments · Fixed by #1020

Comments

@xemul
Copy link
Member

xemul commented Jun 29, 2017

The routine in question does linear list search, but we may have many unix sockets in the dump. Turn it into a hash or tree.

ZeyadYasser added a commit to ZeyadYasser/criu that referenced this issue Apr 11, 2020
Optimize find_unix_sk_by_ino().
Replaced the loop with a hashtable lookup.

Signed-off-by: ZeyadYasser <zeyady98@gmail.com>
ZeyadYasser added a commit to ZeyadYasser/criu that referenced this issue Apr 11, 2020
Optimize find_unix_sk_by_ino().
Replaced the loop with a hashtable lookup.

Signed-off-by: ZeyadYasser <zeyady98@gmail.com>
ZeyadYasser added a commit to ZeyadYasser/criu that referenced this issue Apr 11, 2020
Optimize find_unix_sk_by_ino().
Replaced the loop with a hashtable lookup.

Signed-off-by: ZeyadYasser <zeyady98@gmail.com>
ZeyadYasser added a commit to ZeyadYasser/criu that referenced this issue Apr 11, 2020
Fixes: checkpoint-restore#339
Optimize find_unix_sk_by_ino().
Replaced the loop with a hashtable lookup.

Signed-off-by: ZeyadYasser <zeyady98@gmail.com>
ZeyadYasser added a commit to ZeyadYasser/criu that referenced this issue Apr 12, 2020
Fixes: checkpoint-restore#339
Now (struct socket_table_entry) is the first memeber in (struct unix_sk_info).
So now it could be added to the sockets hashtable.
Replaced find_unix_sk_by_ino() with lookup_socket_ino().
This replaces the linear search with a hashtable lookup.

Signed-off-by: ZeyadYasser <zeyady98@gmail.com>
ZeyadYasser added a commit to ZeyadYasser/criu that referenced this issue Apr 13, 2020
Fixes: checkpoint-restore#339
Now (struct socket_table_entry) is the first memeber in (struct unix_sk_info).
So now it could be added to the sockets hashtable.
Replaced find_unix_sk_by_ino() with lookup_socket_ino().
This replaces the linear search with a hashtable lookup.

Signed-off-by: Zeyad Yasser <zeyady98@gmail.com>
ZeyadYasser added a commit to ZeyadYasser/criu that referenced this issue Apr 15, 2020
Fixes: checkpoint-restore#339
Replaced the linear search with a hashtable lookup.

Signed-off-by: Zeyad Yasser <zeyady98@gmail.com>
ZeyadYasser added a commit to ZeyadYasser/criu that referenced this issue Apr 16, 2020
Fixes: checkpoint-restore#339
Replaced the linear search with a hashtable lookup.

Signed-off-by: Zeyad Yasser <zeyady98@gmail.com>
ZeyadYasser added a commit to ZeyadYasser/criu that referenced this issue May 7, 2020
Fixes: checkpoint-restore#339
Replaced the linear search with a hashtable lookup.

Signed-off-by: Zeyad Yasser <zeyady98@gmail.com>
avagin pushed a commit that referenced this issue May 31, 2020
Fixes: #339
Replaced the linear search with a hashtable lookup.

Signed-off-by: Zeyad Yasser <zeyady98@gmail.com>
avagin pushed a commit to avagin/criu that referenced this issue Jun 9, 2020
Fixes: checkpoint-restore#339
Replaced the linear search with a hashtable lookup.

Signed-off-by: Zeyad Yasser <zeyady98@gmail.com>
angieenee pushed a commit to angieenee/criu that referenced this issue Jun 12, 2020
Fixes: checkpoint-restore#339
Replaced the linear search with a hashtable lookup.

Signed-off-by: Zeyad Yasser <zeyady98@gmail.com>
avagin pushed a commit to avagin/criu that referenced this issue Jul 15, 2020
Fixes: checkpoint-restore#339
Replaced the linear search with a hashtable lookup.

Signed-off-by: Zeyad Yasser <zeyady98@gmail.com>
avagin pushed a commit to avagin/criu that referenced this issue Jul 16, 2020
Fixes: checkpoint-restore#339
Replaced the linear search with a hashtable lookup.

Signed-off-by: Zeyad Yasser <zeyady98@gmail.com>
avagin pushed a commit to avagin/criu that referenced this issue Oct 1, 2020
Fixes: checkpoint-restore#339
Replaced the linear search with a hashtable lookup.

Signed-off-by: Zeyad Yasser <zeyady98@gmail.com>
avagin pushed a commit that referenced this issue Oct 20, 2020
Fixes: #339
Replaced the linear search with a hashtable lookup.

Signed-off-by: Zeyad Yasser <zeyady98@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant