[Nasm-bugs] [Bug 3392533] Considerations for segment support in ELF
noreply-nasm at gorcunov.org
noreply-nasm at gorcunov.org
Sun Aug 4 08:39:04 PDT 2019
https://bugzilla.nasm.us/show_bug.cgi?id=3392533
--- Comment #88 from TK Chia <u1049321969 at caramail.com> ---
Hello hpa,
Some feedback on your ABI document
(https://git.zytor.com/users/hpa/segelf/abi.git/plain/segelf.txt):
1) Should the calculation for R_386_SEG16 be A + ((S + B) >> 4) rather than A +
(S >> 4)?
2) What should be the correct way to convert the values to segment selectors?
More precisely, suppose we define a notional function M(X) to map linear
addresses to segment selectors --- then should R_386_SEGRELATIVE be defined as
A + M(B) or M((A << 4) + B)? (I think the latter makes more sense. But if it
rather assumes that IA-16 segments are start at 16-byte boundaries --- and
protected mode code does not really need this restriction.)
3) Should there also be an R_386_SUB8 relocation, in parallel with R_386_8? I
suspect such a thing might be useful in certain weird cases, e.g. where one
knows that a variable will be in the first 256 bytes of an IA-16 segment.
Thank you!
--
You are receiving this mail because:
You are on the CC list for the bug.
You are watching all bug changes.
More information about the Nasm-bugs
mailing list