[all-commits] [llvm/llvm-project] 72de33: MC: Add MCAsmInfo::evaluateAsRelocatableImpl and r...

Fangrui Song via All-commits all-commits at lists.llvm.org
Sun Jun 15 11:53:05 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 72de33a406383cb8555234c40e7b31db593e164f
      https://github.com/llvm/llvm-project/commit/72de33a406383cb8555234c40e7b31db593e164f
  Author: Fangrui Song <i at maskray.me>
  Date:   2025-06-15 (Sun, 15 Jun 2025)

  Changed paths:
    M llvm/include/llvm/MC/MCAsmInfo.h
    M llvm/lib/MC/MCAsmInfo.cpp
    M llvm/lib/MC/MCExpr.cpp
    M llvm/lib/Target/VE/AsmParser/VEAsmParser.cpp
    M llvm/lib/Target/VE/MCTargetDesc/VEELFObjectWriter.cpp
    M llvm/lib/Target/VE/MCTargetDesc/VEMCAsmInfo.cpp
    M llvm/lib/Target/VE/MCTargetDesc/VEMCAsmInfo.h
    M llvm/lib/Target/VE/MCTargetDesc/VEMCCodeEmitter.cpp
    M llvm/lib/Target/VE/MCTargetDesc/VEMCExpr.cpp
    M llvm/lib/Target/VE/MCTargetDesc/VEMCExpr.h
    M llvm/lib/Target/VE/VEAsmPrinter.cpp
    M llvm/lib/Target/VE/VEMCInstLower.cpp

  Log Message:
  -----------
  MC: Add MCAsmInfo::evaluateAsRelocatableImpl and replace VEMCExpr with MCSpecifierExpr

Expressions with specifier can only be folded during relocation
generatin. At parse time the `MCAssembler *` argument might be null, and
targets should not rely on the evaluateAsRelocatable result.

Therefore, we can move evaluateAsRelocatableImpl from MCSpecifierExpr to
MCAsmInfo, so that targets do not need to inherit from MCSpecifierExpr.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list