[all-commits] [llvm/llvm-project] c62053: [AArch64] Fix the upper limit for folded address o...

Martin Storsjö via All-commits all-commits at lists.llvm.org
Mon Apr 11 16:45:22 PDT 2022


  Branch: refs/heads/release/14.x
  Home:   https://github.com/llvm/llvm-project
  Commit: c62053979489ccb002efe411c3af059addcb5d7d
      https://github.com/llvm/llvm-project/commit/c62053979489ccb002efe411c3af059addcb5d7d
  Author: Martin Storsjö <martin at martin.st>
  Date:   2022-04-11 (Mon, 11 Apr 2022)

  Changed paths:
    M llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
    M llvm/lib/Target/AArch64/GISel/AArch64PreLegalizerCombiner.cpp
    M llvm/test/CodeGen/AArch64/fold-global-offsets.ll

  Log Message:
  -----------
  [AArch64] Fix the upper limit for folded address offsets for COFF

In COFF, the immediates in IMAGE_REL_ARM64_PAGEBASE_REL21 relocations
are limited to 21 bit signed, i.e. the offset has to be less than
(1 << 20). The previous limit did intend to cover for this case, but
had missed that the 21 bit field was signed.

This fixes issue https://github.com/llvm/llvm-project/issues/54753.

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

(cherry picked from commit 8d7a17b7c8b7151b8453903db96fc7f45d9b1bae)




More information about the All-commits mailing list