Skip to content

Implment RTDL_LOCAL and RTDL_NOW/RTDL_LAZY dlopen flags #15339

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

sbc100
Copy link
Collaborator

@sbc100 sbc100 commented Oct 20, 2021

There are two changed here in the implementation of dlopen:

  1. Avoid calling updateGOT when RTDL_LOCAL is set.
  2. Check for undefined stub functions during postInstantiate.

The reason we can't just avoid the stub functions completely here
is the a module could both import and export a given symbol.

@sbc100 sbc100 requested review from kripken and dschuff October 20, 2021 22:19
@sbc100 sbc100 force-pushed the rtld_local branch 2 times, most recently from 097348e to dc85fb4 Compare October 20, 2021 23:07
@dschuff
Copy link
Member

dschuff commented Oct 21, 2021

remind me what updateGOT does?

throw Error('undefined symbol: ' + symbol);
}
}
}
reportUndefinedSymbols();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe add a comment here? I had to read this a few times before I realized the new code checks for undefined symbols in stubs, while the call to reportUndefinedSymbols does the rest.

Actually, can that function do everything, and get the stubs as an optional param?

There are two changed here in the implementation of dlopen:

1. Avoid calling updateGOT when RTDL_LOCAL is set.
2. Check for undefined stub functions during postInstantiate.

The reason we can't just avoid the stub functions completely here
is the a module could both import and export a given symbol.
@stale
Copy link

stale bot commented Nov 2, 2022

This issue has been automatically marked as stale because there has been no activity in the past year. It will be closed automatically if no further activity occurs in the next 30 days. Feel free to re-open at any time if this issue is still relevant.

@stale stale bot added the wontfix label Nov 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants