[all-commits] [llvm/llvm-project] d372e9: Manually create unique_ptr in various pass adaptors

aeubanks via All-commits all-commits at lists.llvm.org
Thu Sep 30 09:55:41 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: d372e92baf96cb0913aa361ecbc53a38a5f29ae1
      https://github.com/llvm/llvm-project/commit/d372e92baf96cb0913aa361ecbc53a38a5f29ae1
  Author: Arthur Eubanks <aeubanks at google.com>
  Date:   2021-09-30 (Thu, 30 Sep 2021)

  Changed paths:
    M llvm/include/llvm/Analysis/CGSCCPassManager.h
    M llvm/include/llvm/IR/PassManager.h
    M llvm/include/llvm/Transforms/Scalar/LoopPassManager.h

  Log Message:
  -----------
  Manually create unique_ptr in various pass adaptors

This avoids creating tons of make_unique template instantiations. And we
only create a unique_ptr of the actual pass concept type, rather than
creating a unique_ptr of the pass model subclass then casting it to the
pass concept type.

This reduces the work spent compiling PassBuilder.cpp from 83M -> 73M
instructions according to perf stat.

Reviewed By: rnk

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




More information about the All-commits mailing list