[Bug 207898] kernel linker behaves differently on amd64 vs. i386

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Sun Mar 13 22:50:56 UTC 2016


Jilles Tjoelker <jilles at FreeBSD.org> changed:

           What    |Removed                     |Added
                 CC|                            |jilles at FreeBSD.org

--- Comment #2 from Jilles Tjoelker <jilles at FreeBSD.org> ---
There is another MD aspect of the kernel linker: whether kernel modules are
object files (file says "ELF xx-bit yyy relocatable") or DSOs (file says "ELF
xx-bit yyy shared object"). Of the architectures you are looking at, i386 uses
DSOs and amd64 uses object files.

Using object files may reduce overhead slightly but bypasses functionality that
may be useful. For example, DSOs have a symbol table for dynamic linking
separate from the one for debugging, while object files only have a single
symbol table. Although there is a flag for static (local) symbols, the kernel
linker ignores it and some code may have started abusing this ignoring.

Note that, although i386 kernel modules are DSOs, they are not PIC and do not
use a GOT and PLT. Therefore, there is no overhead from the DSO format while
running the code.

You are receiving this mail because:
You are the assignee for the bug.

More information about the freebsd-bugs mailing list