History log of /bionic/linker/linked_list.h
Revision Date Author Comments
ae74e8750b9dae51b24a22fdb4b0e0a2d84f37b9 24-Mar-2016 Dimitry Ivanov <dimitry@google.com> linker: hide the pointer to soinfo

Handle no longer is a pointer to soinfo of
a corresponding library. This is done to
prevent access to linker internal fields.

Bug: http://b/25593965
Change-Id: I62bff0d0e5b2dc842e6bf0babb30fcc4c000be24
(cherry picked from commit d88e1f350111b3dfd71c6492321f0503cb5540db)
42d5fcb9f494eb45de3b6bf759f4a18076e84728 30-Oct-2015 Dmitriy Ivanov <dimitry@google.com> Introducing linker namespaces

Bug: http://b/22548808
Change-Id: Ia3af3c0a167f1d16447a3d83bb045d143319b1e1
7a9311f7f1f8ac2aa54807039e3af7789dc48c89 06-Nov-2015 Dmitriy Ivanov <dimitry@google.com> Fix linked_list::remove_if()

When remove_if removes last element from the list
following push_back stops working.

Change-Id: Ia3e92763b83a2e172eaa10de7aecfb7a4be452d7
2a815361448d01b0f4e575f507ce31913214c536 09-Apr-2015 Dmitriy Ivanov <dimitry@google.com> Support symbol versioning

Bug: http://b/20139821
Change-Id: I64122a0fb0960c20b2ce614161b7ab048456b681
ab972b9adf8789a9e1b03129cd7f0c22e6bba117 29-Nov-2014 Dmitriy Ivanov <dimitry@google.com> Count references for groups instead of instances

Count references on the group level to avoid
partially unloading function that might be
referenced by other libraries in the local_group

Bonus: with this change we can correctly unload recursively
linked libraries. is_recursive check is removed.

Also dynamic executables (not .so) with 0 DT_NEEDED libraries
are now correctly linked.

Change-Id: Idfa83baef402840599b93a875f2881d9f020dbcd
0416d88f9c90dcb1b97947a27a7c05f3627484c4 04-Nov-2014 Dmitriy Ivanov <dimitry@google.com> Revert "Revert "Fix symbol lookup order during relocation""

This reverts commit f947be2889639defc6424b1813ccc779528b7598.
c343cac62bfd2933e36357b206fdd81da7610164 04-Nov-2014 Dmitriy Ivanov <dimitry@google.com> Revert "Revert "Fix relocation to look for symbols in local group""

This reverts commit 00dce525530c5d26c20750863f3e9890b468787a.
00dce525530c5d26c20750863f3e9890b468787a 04-Nov-2014 Dmitriy Ivanov <dimitry@google.com> Revert "Fix relocation to look for symbols in local group"

This reverts commit fd2747bb585fc51b5ad56db09c0e9b66c7091a92.

Bug: 18222321
Bug: 18211780
Change-Id: I2d4ebab1e73b7277161af76b99f8249825b22d65
f947be2889639defc6424b1813ccc779528b7598 04-Nov-2014 Dmitriy Ivanov <dimitry@google.com> Revert "Fix symbol lookup order during relocation"

This reverts commit 976402cca13a1f4f3aa988fd301575e134ef5f2c.

Bug: 18222321
Bug: 18211780
Change-Id: Iafdd3d843db7b1cf288be9a0232022816622c944
976402cca13a1f4f3aa988fd301575e134ef5f2c 28-Aug-2014 Dmitriy Ivanov <dimitry@google.com> Fix symbol lookup order during relocation

Relocate symbol against DF_1_GLOBAL shared libraries
loaded before this shared library. This includes
main executable, ld_preloads and other libraries
that have DF_1_GLOBAL flag set.

Bug: 2643900
Bug: 15432753
Bug: 18186310

(cherry picked from commit d225a5e65223b375a63548c4b780f04d8f3d7b60)

Change-Id: I4e889cdf2dfbf8230b0790053d311ee6b0d0ee2d
fd2747bb585fc51b5ad56db09c0e9b66c7091a92 21-Oct-2014 Dmitriy Ivanov <dimitry@google.com> Fix relocation to look for symbols in local group

The local group is a sequence of libraries in default (breadth-first)
order. It allows RTLD_LOCALLY loaded library to correctly relocate
symbols within its group (see test-cases).

Local group lookup is performed after main executable and ld_preloads.

Bug: 2643900
Bug: 15432753
Bug: 18186310

(cherry picked from commit cfa97f172dc1b10d650fefbb6ccffd88ce72a5fb)

Change-Id: I5fa8c673f929e4652c738912c7ae078d7ec286d2
d225a5e65223b375a63548c4b780f04d8f3d7b60 28-Aug-2014 Dmitriy Ivanov <dimitry@google.com> Fix symbol lookup order during relocation

Relocate symbol against DF_1_GLOBAL shared libraries
loaded before this shared library. This includes
main executable, ld_preloads and other libraries
that have DF_1_GLOBAL flag set.

Bug: 2643900
Bug: 15432753
Change-Id: Ia788748be59b739d1c7e62b978e7e255f9e65c7b
cfa97f172dc1b10d650fefbb6ccffd88ce72a5fb 21-Oct-2014 Dmitriy Ivanov <dimitry@google.com> Fix relocation to look for symbols in local group

The local group is a sequence of libraries in default (breadth-first)
order. It allows RTLD_LOCALLY loaded library to correctly relocate
symbols within its group (see test-cases).

Local group lookup is performed after main executable and ld_preloads.

Bug: 2643900
Bug: 15432753
Change-Id: I9bb013b46d17dbb5cbdfb8fef26f552748385541
ae69a9584baf8dd6a28065538ca09d1924ebd9e4 06-Sep-2014 Dmitriy Ivanov <dimitry@google.com> Load libraries in breadth-first order

This patch fixes the problem with symbol search order
for dlsym(RTLD_DEFAULT/RTLD_NEXT, .) by loading libraries
and ld_preloads in correct order.

Bug: https://code.google.com/p/android/issues/detail?id=74255
Attempt: 2

(cherry picked from commit 14669a939d113214a4a20b9318fca0992d5453f0)

Change-Id: Id87540c96a2242220967b6fa5d84ddcd829e2b97
4466bd72fb9daeb0ef8f250e8314b555aab30817 02-Sep-2014 Dmitriy Ivanov <dimitry@google.com> Implement LinkedList::visit()

(cherry picked from commit a4926058496c1c24c00ac07e42d45048dac7c487)

Change-Id: I59554be45c910bfe33494016595a5ade9daad230
4d01d08c2935980fbd9de2d7699230db11074453 29-Aug-2014 Dmitriy Ivanov <dimitry@google.com> Erase elements in LinkedList::remove_if

(cherry picked from commit 4bea498544bb1377f610520d7f58856382a6e5fc)

Change-Id: I1ffe248bc2b7572f38fbd987e9c6db5ecbd4559d
93c3f4203c92ece8b97d770af9b675f5ffb90c67 26-Aug-2014 Dmitriy Ivanov <dimitry@google.com> Enable __cxa_atexit && __cxa_finalize for linker

This allows adding destructors to classes used
for global variables.

(cherry picked from commit 14241402de0faa4b244b1bd6b1f0799ce169b880)

Change-Id: I1d8776130d1e01a8c53d23a2949f5010f4c96b16
14669a939d113214a4a20b9318fca0992d5453f0 06-Sep-2014 Dmitriy Ivanov <dimitry@google.com> Load libraries in breadth-first order

This patch fixes the problem with symbol search order
for dlsym(RTLD_DEFAULT/RTLD_NEXT, .) by loading libraries
and ld_preloads in correct order.

Bug: https://code.google.com/p/android/issues/detail?id=74255
Change-Id: If1ba5c807322409faa914e27ecb675e2c4541f0d
Attempt: 2
a4926058496c1c24c00ac07e42d45048dac7c487 02-Sep-2014 Dmitriy Ivanov <dimitry@google.com> Implement LinkedList::visit()

Change-Id: Ibd9d133dddf1f2e6e65660e3cd2dacafcc0c84d9
4bea498544bb1377f610520d7f58856382a6e5fc 29-Aug-2014 Dmitriy Ivanov <dimitry@google.com> Erase elements in LinkedList::remove_if

Change-Id: I5119a78c73ffe780a81c53ab5ff0266d5c82d319
14241402de0faa4b244b1bd6b1f0799ce169b880 26-Aug-2014 Dmitriy Ivanov <dimitry@google.com> Enable __cxa_atexit && __cxa_finalize for linker

This allows adding destructors to classes used
for global variables.

Change-Id: I5e1cd63fe3bf8f66de88cc4f7437cafb350f49b5
8a84d383fb74135e928d341baa180c55854f2f42 13-Aug-2014 Dmitriy Ivanov <dimitry@google.com> Optimize symbol lookup

Do not run symbol lookup on already visited soinfos
Not taking into account already visited libraries
dramatically slows down dlsym in cases when there
are multiple occurrences of a large library in
dependency tree.

Bug: 16977077

(cherry picked from commit 042426ba6375f5c145379e598486ec6d675533c9)

Change-Id: I69d59e395e8112f119343e8a4d72fe31cd449f31
042426ba6375f5c145379e598486ec6d675533c9 13-Aug-2014 Dmitriy Ivanov <dimitry@google.com> Optimize symbol lookup

Do not run symbol lookup on already visited soinfos
Not taking into account already visited libraries
dramatically slows down dlsym in cases when there
are multiple occurrences of a large library in
dependency tree.

Bug: 16977077
Change-Id: I1379f30ed8b06758dd1cc76b80833ac8589afa50
db7a17d4ff56a05af01ee2fee1f3c55245bfc630 05-Aug-2014 Dmitriy Ivanov <dimitry@google.com> Revert "Revert "Fix dlsym(3) to do breadth first search.""

This reverts commit 1b1966d9448e979d1503a3d8843708bfa8880dc6.

Change-Id: I05d6d3481aaf8f3e260d2e5e950248519a1d347f
1b1966d9448e979d1503a3d8843708bfa8880dc6 04-Aug-2014 Dmitriy Ivanov <dimitry@google.com> Revert "Fix dlsym(3) to do breadth first search."

This reverts commit 422106a24d620af4be58e8d92a2e9b7b6167b72d.

Change-Id: I9e26a6933d10eb30438b521450f2010997ca5aee
422106a24d620af4be58e8d92a2e9b7b6167b72d 29-Jul-2014 Dmitriy Ivanov <dimitry@google.com> Fix dlsym(3) to do breadth first search.

dlsym(3) with handle != RTLD_DEFAULT|RTLD_NEXT performs
breadth first search through the dependency tree.

Bug: 16653281

(cherry picked from commit aa0f2bdbc22d4b7aec5d3f8f5f01eaeaa13414c2)

Change-Id: I0ba8c2034ab341f8a279cdb4e2e7e47f1aef7897
aa0f2bdbc22d4b7aec5d3f8f5f01eaeaa13414c2 29-Jul-2014 Dmitriy Ivanov <dimitry@google.com> Fix dlsym(3) to do breadth first search.

dlsym(3) with handle != RTLD_DEFAULT|RTLD_NEXT performs
breadth first search through the dependency tree.

Bug: 16653281
Change-Id: I017a6975d1a62abb0218a7eb59ae4deba458e324
d286796fce1e6fff407b719a53eb2afbeb96c327 04-Jun-2014 Elliott Hughes <enh@google.com> Turn on -Wunused and fix the mistakes it uncovers.

Change-Id: I023d2d8b547fbc21d4124bb7510d42b06a0dc501
d59e50063ad708509f3ad83350be33f5612c4f54 09-May-2014 Dmitriy Ivanov <dimitry@google.com> Improve detection of already loaded libraries

Linker is now able to resolve symlinked libraries correctly.

soinfo is extended to save the graph of dependencies during
load/unload. Dependencies are used only in CallConstructor.

Bug: 9741592
Change-Id: Id9c48a74c46aa89bcdf3d54ec2f8ba3d398130b1