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

[onert] Use dlmopen for codegen lib #13198

Merged
merged 1 commit into from
Jun 17, 2024
Merged

Conversation

hseok-oh
Copy link
Contributor

This commit changes dlopen() to dlmopen() for codegen library.
It's hard to control dependent library version with runtime's core.
It can help to find internally linked static library version first in dynamic library.
This feature is not supported on android.

ONE-DCO-1.0-Signed-off-by: Hyeongseok Oh [email protected]

@hseok-oh hseok-oh added the PR/ready for review It is ready to review. Please review it. label Jun 14, 2024
@hseok-oh hseok-oh requested a review from a team June 14, 2024 09:52
This commit changes dlopen() to dlmopen() for codegen library.
It's hard to control dependent library version with runtime's core.
It can help to find internally linked static library version first in dynamic library.
This feature is not supported on android.

ONE-DCO-1.0-Signed-off-by: Hyeongseok Oh <[email protected]>
@hseok-oh
Copy link
Contributor Author

https://manpages.debian.org/testing/manpages-dev/dlmopen.3.en.html#dlmopen()

The dlmopen() function differs from dlopen() primarily in that it accepts an additional argument, lmid, that specifies the link-map list (also referred to as a namespace) in which the shared object should be loaded. (By comparison, dlopen() adds the dynamically loaded shared object to the same namespace as the shared object from which the dlopen() call is made.) The Lmid_t type is an opaque handle that refers to a namespace.

LM_ID_NEWLM
Create a new namespace and load the shared object in that namespace. The object must have been correctly linked to reference all of the other shared objects that it requires, since the new namespace is initially empty.

Copy link
Contributor

@ragmani ragmani left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@jyoungyun jyoungyun left a comment

Choose a reason for hiding this comment

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

LGTM

@hseok-oh hseok-oh merged commit f4e1654 into Samsung:master Jun 17, 2024
9 checks passed
@hseok-oh hseok-oh deleted the dlmopen_codegen branch June 17, 2024 06:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR/ready for review It is ready to review. Please review it.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants