[all-commits] [llvm/llvm-project] 3e610f: [pseudo] Turn glrReduce into a class, reuse storag...

Sam McCall via All-commits all-commits at lists.llvm.org
Thu Jun 23 10:28:09 PDT 2022

  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 3e610f2cdc1e156c82f5b59c287165e769b24f40
  Author: Sam McCall <sam.mccall at gmail.com>
  Date:   2022-06-23 (Thu, 23 Jun 2022)

  Changed paths:
    M clang-tools-extra/pseudo/lib/GLR.cpp

  Log Message:
  [pseudo] Turn glrReduce into a class, reuse storage across calls.

This is a ~5% speedup, we no longer have to allocate the priority queues and
other collections for each reduction step where we use them.

It's also IMO easier to understand the structure of a class with methods vs a
function with nested lambdas.

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

More information about the All-commits mailing list