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

Reduction of opened files #797

Closed
jpalus opened this issue Oct 20, 2022 · 2 comments
Closed

Reduction of opened files #797

jpalus opened this issue Oct 20, 2022 · 2 comments

Comments

@jpalus
Copy link
Contributor

jpalus commented Oct 20, 2022

Today mold failed to link qtwebengine from Qt6 due to too many opened files. Linking consists of more than 8400 object files, while my limit at the time was set to 8192. So it appears mold keeps descriptors to all object files at some point. Is it possible to reduce that like close descriptor after processing?

@rui314
Copy link
Owner

rui314 commented Oct 20, 2022

We close a file as soon as we mmap(2) it. IIUC, mmaped files are not counted as opened files. My ulimit shows that the maximum number of open files for me is 1024, but mold seems to be working fine for large programs. So I guess it's not a simple ulimit error. Can you run the linker with strace to watch what system call is failing?

@jpalus
Copy link
Contributor Author

jpalus commented Oct 20, 2022

@rui314 you're absolutely right, mold seems to do everything correctly. Looks like it's issue with my particular setup. Raised containers/fuse-overlayfs#378 for this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants