[all-commits] [llvm/llvm-project] 2538c6: [CodeGen] Prune headers and move code out of line ...

Reid Kleckner via All-commits all-commits at lists.llvm.org
Mon Apr 14 22:23:40 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 2538c607e903a1fe0cfcacd5732235cc8ff3adf7
      https://github.com/llvm/llvm-project/commit/2538c607e903a1fe0cfcacd5732235cc8ff3adf7
  Author: Reid Kleckner <rnk at google.com>
  Date:   2025-04-14 (Mon, 14 Apr 2025)

  Changed paths:
    M llvm/include/llvm/CodeGen/MachineInstr.h
    M llvm/include/llvm/CodeGen/TargetLowering.h
    M llvm/include/llvm/Target/TargetMachine.h
    M llvm/lib/CodeGen/MachineInstr.cpp
    M llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp
    M llvm/lib/CodeGen/TargetLoweringBase.cpp
    M llvm/lib/Target/TargetMachine.cpp
    M llvm/lib/Target/X86/X86Subtarget.cpp
    M llvm/lib/Target/X86/X86Subtarget.h
    M llvm/lib/Target/X86/X86TargetTransformInfo.cpp

  Log Message:
  -----------
  [CodeGen] Prune headers and move code out of line for build efficiency, NFC (#135622)

I noticed these destructors taking time with -ftime-trace and moved some
of them for minor build efficiency improvements.

The main impact of moving destructors out of line is that it avoids
requiring container fields containing other types from being complete,
i.e. one can have uptr<T> or vector<T> as a field with an incomplete
type T, and that means we can reduce transitive includes, as with
LegalizerInfo.h.

Move expensive getDebugOperandsForReg template out-of-line. The
std::function instantiation shows up in time trace even if you don't use
the function.



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