[all-commits] [llvm/llvm-project] f21719: [CodeGen] Use SmallMapVector for SpillPlacement::N...

Mingjie Xu via All-commits all-commits at lists.llvm.org
Tue Apr 28 20:51:05 PDT 2026


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: f217197c8d658390be97d962627a52f2cd97bd4a
      https://github.com/llvm/llvm-project/commit/f217197c8d658390be97d962627a52f2cd97bd4a
  Author: Mingjie Xu <xumingjie.enna1 at bytedance.com>
  Date:   2026-04-29 (Wed, 29 Apr 2026)

  Changed paths:
    M llvm/lib/CodeGen/SpillPlacement.cpp

  Log Message:
  -----------
  [CodeGen] Use SmallMapVector for SpillPlacement::Node::Links (#194653)

Previously, `SpillPlacement::Node::Links` was implemented as a
`SmallVector` of `(Weight, BundleNo)` pairs.

This patch replaces the `SmallVector` with a `SmallMapVector<unsigned,
BlockFrequency, 4>`, which stores `(BundleNo, Weight)` pairs. This
allows for more efficient lookups and weight accumulations when multiple
links to the same bundle are added.



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