[PATCH] D59594: [ELF] Change GOT*_FROM_END (relative to end(.got)) to GOTPLT* (start(.got.plt))

Rui Ueyama via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 20 16:43:16 PDT 2019


ruiu added inline comments.


================
Comment at: ELF/Arch/X86.cpp:196-197
     const uint8_t V[] = {
         0xff, 0xb3, 0x04, 0x00, 0x00, 0x00, // pushl GOTPLT+4(%ebx)
         0xff, 0xa3, 0x08, 0x00, 0x00, 0x00, // jmp *GOTPLT+8(%ebx)
         0x90, 0x90, 0x90, 0x90              // nop
----------------
MaskRay wrote:
> ruiu wrote:
> > Is this comment still correct? You are no longer modifying these instructions' operands, so I'm guessing they now have different operands.
> `Ebx  = GotPlt` now so the 4 lines below can be deleted.
Then I guess you need to update that comment to

  pushl 4(%ebx)
  jmp *8(%ebx)

no?


Repository:
  rLLD LLVM Linker

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D59594/new/

https://reviews.llvm.org/D59594





More information about the llvm-commits mailing list