[all-commits] [llvm/llvm-project] 21d177: [NFC] Refactor looping over recomputeLiveIns into ...

Kai Nacke via All-commits all-commits at lists.llvm.org
Mon Apr 15 14:12:47 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 21d177096f84c38cf434c21bd3ff0dbd2ca163d0
      https://github.com/llvm/llvm-project/commit/21d177096f84c38cf434c21bd3ff0dbd2ca163d0
  Author: Kai Nacke <kai.peter.nacke at ibm.com>
  Date:   2024-04-15 (Mon, 15 Apr 2024)

  Changed paths:
    M llvm/include/llvm/CodeGen/LivePhysRegs.h
    M llvm/lib/CodeGen/BranchFolding.cpp
    M llvm/lib/Target/AArch64/AArch64FrameLowering.cpp
    M llvm/lib/Target/AArch64/AArch64InstrInfo.cpp
    M llvm/lib/Target/ARM/ARMLowOverheadLoops.cpp
    M llvm/lib/Target/PowerPC/PPCExpandAtomicPseudoInsts.cpp
    M llvm/lib/Target/PowerPC/PPCFrameLowering.cpp
    M llvm/lib/Target/SystemZ/SystemZFrameLowering.cpp
    M llvm/lib/Target/X86/X86FrameLowering.cpp

  Log Message:
  -----------
  [NFC] Refactor looping over recomputeLiveIns into function (#88040)

https://github.com/llvm/llvm-project/pull/79940 put calls to
recomputeLiveIns into
a loop, to repeatedly call the function until the computation converges.
However,
this repeats a lot of code. This changes moves the loop into a function
to simplify
the handling.

Note that this changes the order in which recomputeLiveIns is called.
For example,

```
  bool anyChange = false;
  do {
    anyChange = recomputeLiveIns(*ExitMBB) || recomputeLiveIns(*LoopMBB);
  } while (anyChange);
```

only begins to recompute the live-ins for LoopMBB after the computation
for ExitMBB
has converged. With this change, all basic blocks have a recomputation
of the live-ins
for each loop iteration. This can result in less or more calls,
depending on the
situation.



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