public inbox for glibc-bugs@sourceware.org help / color / mirror / Atom feed
* [Bug dynamic-link/30869] New: Fine-tune ELF destructor ordering @ 2023-09-19 6:38 fweimer at redhat dot com 2023-09-19 6:38 ` [Bug dynamic-link/30869] " fweimer at redhat dot com ` (4 more replies) 0 siblings, 5 replies; 6+ messages in thread From: fweimer at redhat dot com @ 2023-09-19 6:38 UTC (permalink / raw) To: glibc-bugs https://sourceware.org/bugzilla/show_bug.cgi?id=30869 Bug ID: 30869 Summary: Fine-tune ELF destructor ordering Product: glibc Version: unspecified Status: NEW Severity: normal Priority: P2 Component: dynamic-link Assignee: unassigned at sourceware dot org Reporter: fweimer at redhat dot com Target Milestone: --- The change in bug 30785 to use reverse constructor orders for destructors does not match expectations of existing applications when objects are destructed by _dl_fini. In particular, the destructors for the main program need to run first. This may trigger additional destructor invocations if dlclose is called. After the main program, the initially loaded objects should be destroyed, potentially triggering more dlclose calls. Only after that, the remaining dlopen'ed objects should be destroyed. This way, applications have some control over destructor ordering through there dlclose calls, which seems useful. A similar issue occurs if dlopen is called from ELF constructors: The current code schedules an object for later destruction *before* it invokes ELF constructors. This means that dlopen'ed objects from ELF constructors may be destructed first, even if the original object calling dlopen might want to close these objects by calling dlclose from its destructor. These changes mostly apply to _dl_fini because when dlclose calls ELF destructors, explicitly dlopen'ed objects (from ELF constructors etc.) still have incremented direct-open counters, and they only become eligible for destruction if invoked ELF destructors invoke dlclose. -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug dynamic-link/30869] Fine-tune ELF destructor ordering 2023-09-19 6:38 [Bug dynamic-link/30869] New: Fine-tune ELF destructor ordering fweimer at redhat dot com @ 2023-09-19 6:38 ` fweimer at redhat dot com 2023-09-19 7:36 ` fweimer at redhat dot com ` (3 subsequent siblings) 4 siblings, 0 replies; 6+ messages in thread From: fweimer at redhat dot com @ 2023-09-19 6:38 UTC (permalink / raw) To: glibc-bugs https://sourceware.org/bugzilla/show_bug.cgi?id=30869 Florian Weimer <fweimer at redhat dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Assignee|unassigned at sourceware dot org |fweimer at redhat dot com CC| |fweimer at redhat dot com Flags| |security- -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug dynamic-link/30869] Fine-tune ELF destructor ordering 2023-09-19 6:38 [Bug dynamic-link/30869] New: Fine-tune ELF destructor ordering fweimer at redhat dot com 2023-09-19 6:38 ` [Bug dynamic-link/30869] " fweimer at redhat dot com @ 2023-09-19 7:36 ` fweimer at redhat dot com 2023-09-19 7:36 ` fweimer at redhat dot com ` (2 subsequent siblings) 4 siblings, 0 replies; 6+ messages in thread From: fweimer at redhat dot com @ 2023-09-19 7:36 UTC (permalink / raw) To: glibc-bugs https://sourceware.org/bugzilla/show_bug.cgi?id=30869 Florian Weimer <fweimer at redhat dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugzilla.redhat.com | |/show_bug.cgi?id=2239304 -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug dynamic-link/30869] Fine-tune ELF destructor ordering 2023-09-19 6:38 [Bug dynamic-link/30869] New: Fine-tune ELF destructor ordering fweimer at redhat dot com 2023-09-19 6:38 ` [Bug dynamic-link/30869] " fweimer at redhat dot com 2023-09-19 7:36 ` fweimer at redhat dot com @ 2023-09-19 7:36 ` fweimer at redhat dot com 2023-09-19 11:53 ` fweimer at redhat dot com 2023-10-18 14:30 ` fweimer at redhat dot com 4 siblings, 0 replies; 6+ messages in thread From: fweimer at redhat dot com @ 2023-09-19 7:36 UTC (permalink / raw) To: glibc-bugs https://sourceware.org/bugzilla/show_bug.cgi?id=30869 Florian Weimer <fweimer at redhat dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://sourceware.org/bugz | |illa/show_bug.cgi?id=30785 -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug dynamic-link/30869] Fine-tune ELF destructor ordering 2023-09-19 6:38 [Bug dynamic-link/30869] New: Fine-tune ELF destructor ordering fweimer at redhat dot com ` (2 preceding siblings ...) 2023-09-19 7:36 ` fweimer at redhat dot com @ 2023-09-19 11:53 ` fweimer at redhat dot com 2023-10-18 14:30 ` fweimer at redhat dot com 4 siblings, 0 replies; 6+ messages in thread From: fweimer at redhat dot com @ 2023-09-19 11:53 UTC (permalink / raw) To: glibc-bugs https://sourceware.org/bugzilla/show_bug.cgi?id=30869 --- Comment #1 from Florian Weimer <fweimer at redhat dot com> --- Patches posted: [PATCH 0/3] Fine-tune ELF destructor ordering (bug 30869) <https://inbox.sourceware.org/libc-alpha/cover.1695113064.git.fweimer@redhat.com/> -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug dynamic-link/30869] Fine-tune ELF destructor ordering 2023-09-19 6:38 [Bug dynamic-link/30869] New: Fine-tune ELF destructor ordering fweimer at redhat dot com ` (3 preceding siblings ...) 2023-09-19 11:53 ` fweimer at redhat dot com @ 2023-10-18 14:30 ` fweimer at redhat dot com 4 siblings, 0 replies; 6+ messages in thread From: fweimer at redhat dot com @ 2023-10-18 14:30 UTC (permalink / raw) To: glibc-bugs https://sourceware.org/bugzilla/show_bug.cgi?id=30869 Florian Weimer <fweimer at redhat dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |WONTFIX Status|ASSIGNED |RESOLVED --- Comment #2 from Florian Weimer <fweimer at redhat dot com> --- This change has been abandoned after the changes from bug 30785 have been reverted. -- You are receiving this mail because: You are on the CC list for the bug. ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2023-10-18 14:30 UTC | newest] Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2023-09-19 6:38 [Bug dynamic-link/30869] New: Fine-tune ELF destructor ordering fweimer at redhat dot com 2023-09-19 6:38 ` [Bug dynamic-link/30869] " fweimer at redhat dot com 2023-09-19 7:36 ` fweimer at redhat dot com 2023-09-19 7:36 ` fweimer at redhat dot com 2023-09-19 11:53 ` fweimer at redhat dot com 2023-10-18 14:30 ` fweimer at redhat dot com
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).