[all-commits] [llvm/llvm-project] 1874de: [macho][NFC] Extract all CPU_(SUB_)TYPE logic to B...

Visoiu Mistrih Francis via All-commits all-commits at lists.llvm.org
Fri Feb 21 12:46:37 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 1874dee5662603c9251228c71b66de72cec0c979
      https://github.com/llvm/llvm-project/commit/1874dee5662603c9251228c71b66de72cec0c979
  Author: Francis Visoiu Mistrih <francisvm at yahoo.com>
  Date:   2020-02-21 (Fri, 21 Feb 2020)

  Changed paths:
    M llvm/include/llvm/BinaryFormat/MachO.h
    M llvm/lib/BinaryFormat/CMakeLists.txt
    A llvm/lib/BinaryFormat/MachO.cpp
    M llvm/lib/Target/AArch64/MCTargetDesc/AArch64AsmBackend.cpp
    M llvm/lib/Target/AArch64/MCTargetDesc/AArch64MachObjectWriter.cpp
    M llvm/lib/Target/ARM/MCTargetDesc/ARMAsmBackend.cpp
    M llvm/lib/Target/ARM/MCTargetDesc/ARMAsmBackendDarwin.h
    M llvm/lib/Target/PowerPC/MCTargetDesc/PPCAsmBackend.cpp
    M llvm/lib/Target/X86/MCTargetDesc/X86AsmBackend.cpp

  Log Message:
  -----------
  [macho][NFC] Extract all CPU_(SUB_)TYPE logic to BinaryFormat

This moves all the logic of converting LLVM Triples to
MachO::CPU_(SUB_)TYPE from the specific target (Target)AsmBackend to
more convenient functions in lib/BinaryFormat.

This also gets rid of the separate two X86AsmBackend classes.

The previous attempt was to add it to libObject, but that adds an
unnecessary dependency to libObject from all the targets.

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




More information about the All-commits mailing list