[all-commits] [llvm/llvm-project] 1e7f59: [MC][COFF][AArch64] Avoid incorrect IMAGE_REL_ARM6...

Hiroshi Yamauchi via All-commits all-commits at lists.llvm.org
Thu Aug 17 14:40:19 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 1e7f592a890aad860605cf5220530b3744e107ba
      https://github.com/llvm/llvm-project/commit/1e7f592a890aad860605cf5220530b3744e107ba
  Author: Hiroshi Yamauchi <hjyamauchi at gmail.com>
  Date:   2023-08-17 (Thu, 17 Aug 2023)

  Changed paths:
    M llvm/lib/MC/WinCOFFObjectWriter.cpp
    M llvm/lib/Target/AArch64/MCTargetDesc/AArch64AsmBackend.cpp
    A llvm/test/MC/AArch64/coff-relocations-branch26.s

  Log Message:
  -----------
  [MC][COFF][AArch64] Avoid incorrect IMAGE_REL_ARM64_BRANCH26 relocations.

For a b/bl instruction that branches a temporary symbol (private
assembly label), an IMAGE_REL_ARM64_BRANCH26 relocation to another
symbol + a non-zero offset could be emitted but the linkers don't
support this type of relocation and cause incorrect relocations and
crashes. Avoid emitting this type of relocations.

Differential Revision: https://reviews.llvm.org/D155732




More information about the All-commits mailing list