HomePhabricator

Remove MachineLoopInfo dependency from AsmPrinter.
Audit RequiredrL329542

Description

Remove MachineLoopInfo dependency from AsmPrinter.

Summary:
Currently MachineLoopInfo is used in only two places:

  1. for computing IsBasicBlockInsideInnermostLoop field of MCCodePaddingContext, and it is never used.
  2. in emitBasicBlockLoopComments, which is called only if isVerbose() is true.

Despite that, we currently have a dependency on MachineLoopInfo, which makes
pass manager to compute it and MachineDominator Tree. This patch removes the
use (1) and makes the use (2) lazy, thus avoiding some redundant
recomputations.

Reviewers: opaparo, gadi.haber, rafael, craig.topper, zvi

Subscribers: rengolin, javed.absar, hiraditya, llvm-commits

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

Details

Auditors
grosbach
Committed
mzolotukhinApr 8 2018, 5:54 PM
Differential Revision
D44812: Remove MachineLoopInfo dependency from AsmPrinter.
Parents
rL329541: [test] Fix Container::insert(value_type const&) tests
Branches
Unknown
Tags
Unknown