[all-commits] [llvm/llvm-project] c12df5: [IR][NFC] Drop vtable from PassConcept/PassModel (...

Alexis Engelke via All-commits all-commits at lists.llvm.org
Wed Jul 8 10:46:25 PDT 2026


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: c12df55e9a5ee84178c5d30c753a4799b63fec80
      https://github.com/llvm/llvm-project/commit/c12df55e9a5ee84178c5d30c753a4799b63fec80
  Author: Alexis Engelke <engelke at in.tum.de>
  Date:   2026-07-08 (Wed, 08 Jul 2026)

  Changed paths:
    M llvm/include/llvm/IR/PassManagerInternal.h

  Log Message:
  -----------
  [IR][NFC] Drop vtable from PassConcept/PassModel (#208168)

The PassConcept/PassModel vtable has a size of 64 bytes (offset to top,
RTTI pointer, complete object destructor, deleting destructor, run,
printPipeline, name, isRequired), which add up to 53kiB (all
targets)/44 kiB (single-target). As more back-end passes get ported to
the new pass manager, this size will increase.

Remove the vtables by replacing the virtual dispatch with explicit
function pointers, initialized when adding the pass to the pass manager.
While this *very* slightly increases the cost of adding a pass, there's
also a very slight win from avoiding the vtable indirection when
running/destructing the pass.



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