Source-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: src/sys/arch/amd64/amd64



Module Name:    src
Committed By:   maxv
Date:           Tue Nov 15 15:26:59 UTC 2016

Modified Files:
        src/sys/arch/amd64/amd64: machdep.c

Log Message:
I actually came across the solution to this issue in the Intel SDM for a
totally unrelated reason a few weeks ago. The reason we need a particular
module_map on amd64 is because gcc makes us use RIP-relative addressing.

The offset field of the associated opcodes is a 32bit signed displacement,
which means we can access only up to 2GB around the current instruction.
And given that kernel_map is too far away from the kernel .text, it is not
RIP-addressable. Hence the module_map embedded into the bootstrap memory,
which is right above the kernel image.


To generate a diff of this commit:
cvs rdiff -u -r1.231 -r1.232 src/sys/arch/amd64/amd64/machdep.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.




Home | Main Index | Thread Index | Old Index