[all-commits] [llvm/llvm-project] 67c1c1: [PowerPC][X86] Make cpu id builtins target indepen...

Nemanja Ivanovic via All-commits all-commits at lists.llvm.org
Fri Jan 26 08:25:03 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 67c1c1dbb6cd473ce302079d0b3791ff461b7bba
      https://github.com/llvm/llvm-project/commit/67c1c1dbb6cd473ce302079d0b3791ff461b7bba
  Author: Nemanja Ivanovic <nemanja.i.ibm at gmail.com>
  Date:   2024-01-26 (Fri, 26 Jan 2024)

  Changed paths:
    M clang/include/clang/Basic/Builtins.td
    M clang/include/clang/Basic/BuiltinsX86.def
    M clang/include/clang/Basic/TargetInfo.h
    M clang/lib/Basic/Targets/PPC.cpp
    M clang/lib/Basic/Targets/PPC.h
    M clang/lib/Basic/Targets/X86.h
    M clang/lib/CodeGen/CGBuiltin.cpp
    M clang/lib/Sema/SemaChecking.cpp
    M clang/test/CodeGen/builtin-cpu-supports.c
    M clang/test/Sema/builtin-cpu-supports.c
    M llvm/include/llvm/IR/IntrinsicsPowerPC.td
    A llvm/include/llvm/TargetParser/PPCTargetParser.def
    M llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
    M llvm/lib/Target/PowerPC/PPCInstrInfo.cpp
    M llvm/lib/Target/PowerPC/PPCInstrInfo.td
    M llvm/lib/Target/PowerPC/PPCTargetMachine.h
    A llvm/test/CodeGen/PowerPC/cpu-supports.ll

  Log Message:
  -----------
  [PowerPC][X86] Make cpu id builtins target independent and lower for PPC (#68919)

Make __builtin_cpu_{init|supports|is} target independent and provide an
opt-in query for targets that want to support it. Each target is still
responsible for their specific lowering/code-gen. Also provide code-gen
for PowerPC.

I originally proposed this in https://reviews.llvm.org/D152914 and this
addresses the comments I received there.

---------

Co-authored-by: Nemanja Ivanovic <nemanjaivanovic at nemanjas-air.kpn>
Co-authored-by: Nemanja Ivanovic <nemanja at synopsys.com>




More information about the All-commits mailing list