[all-commits] [llvm/llvm-project] c7c7ef: [XCOFF] set fragment for XMC_PR csects.

Esme via All-commits all-commits at lists.llvm.org
Tue Nov 22 04:18:17 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: c7c7ef8bda1fb7a81f8f769c6b1cc8583629a309
      https://github.com/llvm/llvm-project/commit/c7c7ef8bda1fb7a81f8f769c6b1cc8583629a309
  Author: esmeyi <esme.yi at ibm.com>
  Date:   2022-11-22 (Tue, 22 Nov 2022)

  Changed paths:
    M llvm/lib/MC/MCContext.cpp
    M llvm/test/CodeGen/PowerPC/aix-xcoff-funcsect.ll

  Log Message:
  -----------
  [XCOFF] set fragment for XMC_PR csects.

Summary: -xcoff-traceback-table is a default option on AIX regardless of optimization and debug levels. An error of relocation for paired relocatable term is not yet supported in XCOFFObjectWriter::recordRelocation occurred when both of the -xcoff-traceback-table and -function-sections are enabled.
The root cause is that we missed to calculate the symbols difference as absolute value before adding fixups when symbol_A without the fragment set is the csect itself and symbol_B is in it.
This patch only sets the fragment for XMC_PR csects because we don't have other cases that hit this problem yet.

Reviewed By: DiggerLin, hubert.reinterpretcast

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




More information about the All-commits mailing list